fair-acc / chart-fx

A scientific charting library focused on performance optimised real-time data visualisation at 25 Hz update rates for data sets with a few 10 thousand up to 5 million data points.
GNU Lesser General Public License v3.0
488 stars 90 forks source link

Broken handling of Y error values by multi-value LimitedIndexedTreeDataSet.set #652

Closed zanzica closed 5 months ago

zanzica commented 5 months ago

Describe the bug There is a coding error (probably copy-paste) in LimitedIndexedTreeDataSet .set that causes the y error values to be ignored, with the y values erroneously used in their place.

Permalink

Snippet:

public LimitedIndexedTreeDataSet set(final double[] xValues, final double[] yValues, final double[] xErrors,
            final double[] yErrors, final int count) {
...
                final double x = xValues[i];
                final double y = yValues[i];
                final double dx = xErrors[i];
                final double dy = yValues[i]; // this should be yErrors[i]
...
wirew0rm commented 5 months ago

Thanks for letting us know :+1: