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

StockChart Questions

1 Answer 68 Views
Charts
This is a migrated thread and some comments may be shown as answers.
Raphael
Top achievements
Rank 1
Raphael asked on 05 Feb 2013, 05:04 PM
Hi,

I have two questions regarding the kendo stock chart:

1. I need to retrieve a list of the currently displayed data points (not the whole data set of the series) in the events zoomEnd, dragEnd and selectEnd in order to perform some normalization. How can this be done?

2. For the same events, how do I get the min and max of the currently displayed range of the x axis?

Thanks.

1 Answer, 1 is accepted

Sort by
0
Iliana Dyankova
Telerik team
answered on 08 Feb 2013, 11:30 AM
Hello Raphael,

Straight to your questions: 
  1. I am afraid this is not supported out of the box in Kendo UI StockChart. As a possible workaround I can suggest to create a separate DataSource for the Navigator, filter it and in the events (zoomEnd, dragEnd or selectEnd) use the DataSource's view() method. For your convenience I prepared a simple HTML page which demonstrates this approach in action; 
  2. You can get the min and max of the current range via chart.options. For example: 
    var stockChart =  $("#stock-chart").data("kendoStockChart");
    stockChart.options.categoryAxis[0].min;
    stockChart.options.categoryAxis[0].max;

I hope this information helps.

Kind regards,
Iliana Nikolova
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Tags
Charts
Asked by
Raphael
Top achievements
Rank 1
Answers by
Iliana Dyankova
Telerik team
Share this question
or