-
Notifications
You must be signed in to change notification settings - Fork 19.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Using sampling with connectNulls connects regular datapoints with null ones when zoomed out #14689
Comments
Hi! We've received your issue and please be patient to get responded. 🎉 In the meanwhile, please make sure that you have posted enough image to demo your request. You may also check out the API and chart option to get the answer. If you don't get helped for a long time (over a week) or have an urgent question to ask, you may also send an email to [email protected]. Please attach the issue link if it's a technical question. If you are interested in the project, you may also subscribe our mailing list. Have a nice day! 🍵 |
@tmscer Please simplify your demo to help us debug. A minimum reproducible demo should contain as little data and components as possible but can still illustrate your problem. This is the best way for us to reproduce it and solve the problem faster. |
I've simplified the demo. I removed as much as possible, however, some data (~1600 datapoints) is left in the demo to actually see the bug. See https://codepen.io/tmscer/pen/yLgGXbo. There is a Let me know if the demo is simple enough. But I am afraid that further significant simplification isn't possible. |
@tmscer Thanks. I think we can get on it based on this. |
Hi ! I'm having a similar issue in my project As for Tmscer example, the problem seems only to appear when using LTTB sampling method, and when the algorithm is applied to the serie. When the zoom level allow to display all points on the chart, the problem disappear. Guess it as something to do with the algorithm handling null / undefined values in the serie. Sorry if the english is a bit messy ! |
I see that |
I reported the same issue in #13228 |
Hi there! Any updates on this? |
Seems it's because the null values are filtered during sampling |
An idea: a null value should then split the dataseries into separate chunks that can be then sampled separately. |
Version
5.1.0
Reproduction link
https://codepen.io/tmscer/pen/wvgxKNRhttps://codepen.io/tmscer/pen/yLgGXbo
Steps to reproduce
Use a series line with
connectNulls: false
andsampling: 'lttb'
(may be reproducible with other sampling methods) and have a null value in your data.What is expected?
I'd expect null values to never be connected with regular values.
What is actually happening?
When zoomed out, regular values are connected with null values. When zoomed in, the line between regular values and nulls disappears and behaves as expected.
I suspect this may be caused by the sampling algorithm since when no sampling is used, null values are never connected with regular ones.
I'm not sure what version of Echarts is used in the codepen, however, the bug is reproducible in 5.1.0. To see the bug, zoom in the flat line. At the end of it, there is a null.
The text was updated successfully, but these errors were encountered: