-
Notifications
You must be signed in to change notification settings - Fork 981
Description
Issue:
The DataLoggerSource class lacks a method to reset Min/Max values, causing the autoscale feature to work incorrectly.
Using dataLogger!.Data.Coordinates.RemoveAt(0); to remove data points from a DataLogger updates render correctly, but does not update the DataLogger.Data.(Min/Max) values, resulting in AvaPlot.Plot.Axes.AutoScale(); not functioning properly.
ScottPlot Version:
ScottPlot 5 (Avalonia UI)
Sample:
In my implementation, I add points to a DataLogger every millisecond. Once the count reaches 3000, I start removing the first point and append a new one, maintaining a constant count of 3000 points (this can be changed by the user). In the image below, you can see 3000 coordinates. I stopped recording at 5079 ms, but instead of my XMin being at 2079 (the correct value), it remains at 0 (the value of the first point that no longer exists).
