This is a migrated thread and some comments may be shown as answers.

How to display 0 for series value when the data is missing?

2 Answers 250 Views
ChartView
This is a migrated thread and some comments may be shown as answers.
Chris Ward
Top achievements
Rank 1
Chris Ward asked on 14 Jan 2019, 08:02 PM

I would like to use the ChartView control to create charts of time line data. The SQL database that I am querying against has a data point for every minute for thousands of counters.  For space savings, the application that stores the data does not create a record if the value of the data points is ZERO for that minute.  For this data, that is a savings of more than 75%.

When creating a line chart, is it possible to have RadChartView treat the missing data points with the value of ZERO?  In my test application, ChartView seems to approximate the missing values and simply draws a straight line between the two point that do have a value.  This is not an accurate representation of the data. What I need is from the line chart to go to 0 for the minutes there there is no data.

I've used other charting applications that have this capability.

Chris

 

2 Answers, 1 is accepted

Sort by
0
Dess | Tech Support Engineer, Principal
Telerik team
answered on 16 Jan 2019, 02:41 PM
Hello, Chris,        

RadChartView supports empty values in the series. In general, empty values means missing Y value for a particular X value. The empty X value is skipped from drawing. NullValues is supported only for Cartesian series like Bar, Line, Spline, Area and SplineArea. Additional information is available in the following help article: https://docs.telerik.com/devtools/winforms/controls/chartview/null-values-support-

An alternative approach is to iterate the source collection and specify zero for the empty values in order to achieve your requirement. Feel free to use this approach which suits your requirements best.

I hope this information helps. If you need any further assistance please don't hesitate to contact me. 

Regards,
Dess | Tech Support Engineer, Sr.
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
0
Chris Ward
Top achievements
Rank 1
answered on 16 Jan 2019, 03:22 PM

Ok, thank you .  I suspected that was the case.  I will find a way to populate the data source with zero's.

 

CHris

 

 

Tags
ChartView
Asked by
Chris Ward
Top achievements
Rank 1
Answers by
Dess | Tech Support Engineer, Principal
Telerik team
Chris Ward
Top achievements
Rank 1
Share this question
or