This thread looks to be a little on the old side and therefore may no longer be relevant. Please see if there is a newer thread on the subject and ensure you're using the most recent build of any software if your question regards a particular product.
This thread has been locked and is no longer accepting new posts, if you have a question regarding this topic please email us at support@mindscape.co.nz
|
Hi, In our application we have come across a case where two The issue is 100% reproducible on certain datasets by adjusting horizontal zoom - when viewing everything at once it happens and when you being to zoom in it will disappear. I have attached images showing both cases. As you can see in the images, it appears that previous series (yellow) does not have data at the given x values and returns 0.0 causing the current series (pink) to not stack correctly. Stepping through
Two questions:
The only way I can think the previous series doesn't have the data at point and why it disappears when adjusting the horizontal zoom is that somehow the To help reproduce this on your end, I have also attached the datasets for both series as CSV. |
|
|
With some further investigation, I found a correlation between the data cache misses values is when the As a test, I commented out 4 lines in the When |
|
|
What would be the proper solution to this issue? Forcing the |
|
|
Hello Dennis Thanks for pointing this out. The _dataCache is correctly populated whenever the series is analysed (finding the largest/smallest values etc). During this operation, the _dataCache contains all data points within the ItemsSource. However, whenever the series was rendered, it refreshes the _dataCache and repopulates it only with the data points that get rendered. When the IndexStep is greater than 1, not all data points get rendered, which means not all data points got added back to the _dataCache meaning that sometimes stacked series could not find the equivalent data value from the previous series. This bug has been fixed which can be updated from the next nightly build. Let us know how it goes. -Jason |
|
|
Thanks Jason. I will integrate your changes as soon as possible and let you know how it goes. |
|
|
Hi Jason, I finally got time to integrate the latest nightly build (01 March 2012) today however the missing cache issue still remains. After looking deeper at the caching issue and I decided that as all my datasets have same number of points (sampled at a regular interval) the So... to get the closest point to one requested I wrote the following function in
What do you think of this solution? |
|
|
Hello Dennis Thanks for the feedback, I will look into this first thing next week. -Jason |
|
|
As I was cycling home last night, it occurred to me a better solution would be to look at the previous cache and only render the points that we have. |
|
|
Hello Dennis I have not been able to reproduce this issue since the time I made the fix for it. There may be another factor involved in causing this problem such as setting certain properties. Nothing stands out when I look through the code though. If you can send a simple repro of this issue then it will help greatly. Also, you should check to make sure your project is using the correct updated dll - just in case. Note that this issue is currently only fixed in the StackedAreaSeries. If you have changed to use a different stacked series then you'll still see the issue. -Jason |
|
|
Would you be able to send through a diff/patch of the changes you made to fix this issue? It is difficult to simply integrate the nightly build. |
|
|
To fix this issue, I simply put a null check around the _dataCache initialization in StackedAreaSeries.BuildChartCore. Like this:
-Jason |
|