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

size frequency

3 Answers 52 Views
ChartView
This is a migrated thread and some comments may be shown as answers.
nishan
Top achievements
Rank 1
nishan asked on 29 May 2016, 08:32 PM

Dear Telerik,

I am using pivotGrid and pivotFieldList

I am having some size frequency data where all the sizes fall into different size classes. I want a continuous set of size classes but as no lengths exists for some size classes, I am getting gaps in the size classes.

Please have a look at the attached files. You will see that the size classes are missing between 3 and 8 are more.

Your help in getting a consistant continuous x axis is appreciated.

Thanks,

3 Answers, 1 is accepted

Sort by
0
Hristo
Telerik team
answered on 30 May 2016, 03:26 PM
Hello Nishan,

Thank you for writing.

The displayed data in a chart associated with a RadPivotGrid directly relates the selected pivot data and this is the behavior by design. As a suggestion please consider modifying the underlying data so that you do not create missing values and have it running continuously. 

I understand that his might not be possible so let me suggest you a different approach. You can try modifying the data source of the different series just after they are being created. For the purpose, you would need to create a custom PivotGridChartDataProvider and override its UpdateChartData method. Then you can read the current data points and add new ones to fill the empty values. I am sending you attached a sample project which should get you started.

I hope this helps. Please let me know if you need further assistance.

Regards,
Hristo Merdjanov
Telerik
Check out the Windows Forms project converter, which aids the conversion process from standard Windows Forms applications written in C# or VB to Telerik UI for WinForms.For more information check out this blog post and share your thoughts.
0
nishan
Top achievements
Rank 1
answered on 02 Jun 2016, 07:56 PM

Dear Hristo

Thanks for you example and guidance. Your code and the guidance to override worked.

However, I realise that I will actually need to change the columns on the Pivotgrid to have these missing points. Can you please briefly guide me what I should do in order to add missing columns to the pivotgrid rather than the chart.

Thanks,

 

Nishan.

0
Hristo
Telerik team
answered on 07 Jun 2016, 01:14 PM
Hello Nishan,

Thank you for writing back.

In order to display a particular field in RadPivotGrid as a column, for example, you would need to have this field within your data source object. As a suggestion please consider modifying your model so that you can bind the control and display the data in the format you require.

I hope this helps. Please let me know if you need further assistance.

Regards,
Hristo Merdjanov
Telerik
Check out the Windows Forms project converter, which aids the conversion process from standard Windows Forms applications written in C# or VB to Telerik UI for WinForms. For more information check out this blog post and share your thoughts.
Tags
ChartView
Asked by
nishan
Top achievements
Rank 1
Answers by
Hristo
Telerik team
nishan
Top achievements
Rank 1
Share this question
or