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

RadChart refresh performance

5 Answers 106 Views
Chart
This is a migrated thread and some comments may be shown as answers.
Michele
Top achievements
Rank 1
Michele asked on 19 Oct 2012, 03:25 PM
Dear Telerik,

I use a RadChart that always displays three series. Each series contains several hundred points but I use the sampling functionality and limit the number of points to 200.

The chart can also have up to three additional lines series. These series are created by the user drawing a line on the chart (like in Excel); therefore these series always contains two and only two points. The lines can be modified and moved by the user. This is achieved by handling mouse up/down and item click events.

I noticed a significant drop in performances in updating the lines after a user interaction (move, or modify) when the first three series contains all the 200 points. I measured the time required to perform all the operations by my code and in the worse case it takes up to 0.5 seconds which is fine. However the chart requires up to two additional seconds to be updated.

I also tested the same code reducing the sampling to 20. The code is executed in 0.25 seconds and the chart is updated with no significant delay.

Do you expect this drop in performance in the radchart with 600 points?

Is there a way to refresh the chart so that only one series is updated?

5 Answers, 1 is accepted

Sort by
0
Petar Marchev
Telerik team
answered on 22 Oct 2012, 10:55 AM
Hi Michele,

May be if you send us a project that we can actually run and test we can give you a more constructive suggestion towards increasing the chart's performance. I would usually suggest to decrease the number of the total data points. Right now you have 3 series with 200 data points each (600 in total). Try decreasing the total number of data points to 200.

Additionally you can switch to the RadChartView, which is a newer control with a higher performance rate and is generally more flexible than the RadChart. Note that these are two different controls and they do not have an equivalent for each feature. 

Kind regards,
Petar Marchev
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

0
Michele
Top achievements
Rank 1
answered on 22 Oct 2012, 02:05 PM
Dear Petar,

Thanks for the reply.

I can reduce the number of points to 100 but the delay in response is still visible (more than a second).

I tried to use the radchartview but I could not find a way of selecting a line series like with the ItemClick functionality in the RadChart. This is essential to create the Excel-like behaviour I require for my lines. Can you point me to an example if the functionality exists?

Thanks,

Michele
0
Petar Marchev
Telerik team
answered on 23 Oct 2012, 10:40 AM
Hello Michele,

I think you may find the Selection behavior very useful for your scenario. Here is an online example. Here is an online help topic. And I have attached a simple project to demonstrate this. Let us know how it goes.

All the best,
Petar Marchev
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

0
Michele
Top achievements
Rank 1
answered on 23 Oct 2012, 11:05 AM
Dear Petar,

Thanks for the links and the sample project.

Unfortunately the Selection behaviour is different from the ItemClick in the RadChart. In particular I cannot select the whole series by clicking on the line connecting two points.

Actually in the online example, the line chart (top right) is the only one that cannot be clicked on to selected a series.

I could not find any documentation to achieve my goal, so if you know of a way to select the line I would be very interested to know it.

Thanks,

Michele
0
Petar Marchev
Telerik team
answered on 24 Oct 2012, 08:01 AM
Hello Michele,

Try to attach a handler to the MouseLeftButtonDown event of the series:
<telerik:LineSeries IsHitTestVisible="True" MouseLeftButtonDown="LineSeries_MouseLeftButtonDown" />

Let us know how it goes.

Greetings,
Petar Marchev
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Tags
Chart
Asked by
Michele
Top achievements
Rank 1
Answers by
Petar Marchev
Telerik team
Michele
Top achievements
Rank 1
Share this question
or