Pre loader

Coloring of gaps in series

Welcome to the SciChart Forums!

  • Please read our Question Asking Guidelines for how to format a good question
  • Some reputation is required to post answers. Get up-voted to avoid the spam filter!
  • We welcome community answers and upvotes. Every Q&A improves SciChart for everyone

WPF Forums | JavaScript Forums | Android Forums | iOS Forums

0
0

Hi again,

related to the question how to color the full chart vertically i have an other one:

The customer wants gaps in series also to be colored / highlighted and not just not shown. I wonder what’s the proper approach for this. PaletteProvider seems to be no solution since the values to be shown somehow are Double.NaNs. So are again annotations the best solution? Or is there any other way i’m not aware of?

Best regards,
Robin

  • You must to post comments
0
0

Hi Robin,

Yes, this approach is the best one which I can think of for now. Also, there might be another way of achieving that using axis bands(refer to Digital Line Chart example), which we introduced in SciChart 2.0v, but there isn’t any way how to customize their drawing over inheritance/overrides.

I logged your request and we will consider providing a way to do this using axis bands in next version.

Best regards,
Yuriy

  • Andreas Mueller-Bluemlein
    Hello, finally, i implemented this with annotations. However, i'm a bit worried about performance, even some 100s of them slow down the chart interaction significally. To speed up, i add all of them (lot's of LineAnnotations, some BoxAnnotation) to a List of IAnnotation. In Step 2 i construct a new AnnotationCollection(MyList) to add them in bulk. This helps, but any other idea for further improvement is welcome. Regarding the logging of my request, i want to clarify that it is a bit more complicated than just turning Double.NaN drawing on / off. In my case, there are three states for each chart value: 1. Valid Value: an valid double, drawn as expected 2. NotAvailable: coded as Double.NaN, should not be drawn, Gap in Chart is perfect 3. Error: coded as Double.NaN, should be drawn thick and red, currently implemented via (lot's of) annotations So in my case, there are two possible outcomes for an Double.NaN. But of course other scenarios could distinguish three or even more. Best regards, Robin
  • You must to post comments
0
0

Hi Robin,

It sounds to me like a custom series is the only way to go for such a thing. It would require custom work. Is this something you or your clients are interested in?

Alternatively you could implement two series, one which contains just normal values and another which contains just error values.

Agreed that annotations are slower than main series, they are WPF UIElements, not drawn on bitmaps. This enables them to benefit from interactivity, templating, tooltips, mouse-hovers, datacontext binding but on the downside means we’re back to the slow WPF rendering engine!

Best regards,
Andrew

  • Andreas Mueller-Bluemlein
    Hi Andrew, i will clarify how to proceed and will contact you via email in case we go for the custom series. Best regards, Robin
  • You must to post comments
0
0

Try what I suggested – two series, one has data with gaps, one has the inverse.

  • You must to post comments
Showing 3 results
Your Answer

Please first to submit.

Try SciChart Today

Start a trial and discover why we are the choice
of demanding developers worldwide

Start TrialCase Studies