I have a XamDataChart with Scatter point dynamically generated and Assigned to it.
The problem is that when I zoom into a region or scale the vertical and horizontal axes the chart doesn't show the orginal state when the scale is reset.
Has anyone seen this problem before?
I'm not certain if this is what is happening in your case, but if the number of points is over the maximum number of markers then some of the less significant points (occluded, close to others, etc) are being hidden. The chart tries to show as many points in diverse areas as possible. You can raise the total number of points shown by increasing maximum markers. But if you raise this too high, you will start to have performance problems from too many markers in the visual tree.
As you zoom in and out, the chart will attempt to keep the same points in view as were visible last time it rendered. As you zoom in, points that were less significant before will become more significant as you zoom in, and so will begin to display.
When you zoom out, however, there will be a high importance on displaying points that were visible the last time the chart was rendered, so there will be a higher weighting on points that you were zoomed in on. This often results in a higher density of points being displayed in one area after you zoom out of it. This is a trade off such that as you are zooming in and out the points don't completely flicker at random as different candidates are selected at each zoom increment, but rather it attempts to select the same points that it did at the last zoom level, if they are still significant and in view.
Does that seem to explain what you are seeing?
Thanks for the reply.
Please look at the following images, which show the state of my chart before any scaling, during the scale and after the scale is reset. You can see the horizontal and vertical scale bars on the chart.
Unfortunately, it is not very easy for me to send you a sample project.
Any help is really appreciated.
I increased the Maximum number of markers to the number of markers on the Chart and now the Zoom behavior makes more sense.
I think this is a bug on the Chart control.
Thanks for you help.
Based on the screenshots you provided, I believe this is the expected behavior, when you zoom back out of the chart it favored keeping the points in the bottom left, where you were zoomed in to, in order to make the zooming interaction more seamless.
Perhaps we can tweak the behavior to more aggressively release some of the previously displayed points as the zoom level changes drastically. Did you zoom out in one step by hitting the home key or did you progressively zoom out one step at a time?
If you make a feature request to alter this behavior, we could perhaps add a toggle that disables the behavior where it tries to maintain the previously visible points. Or we can investigate different modes where less of the points are maintained.
I am currently experiencing the similar issue. Has your team resolved this behavior by any chance? I would prefer a toggle functionality for now if it can be done. Please advise.