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

Line chart with category type. Smooth baseUnit swith while zoom out.

3 Answers 107 Views
Charts
This is a migrated thread and some comments may be shown as answers.
Jose Mejia
Top achievements
Rank 1
Jose Mejia asked on 09 Jun 2015, 08:27 PM

Hi.

Here is my code sample

Now I can show maximum 30 points with 15 min. interval. But I want to be able to switch to hours smoothly when user continues zooming out.

Basically, I have to scenarios:

1) user select some time interval based on datepickers and I decide appropriate baseUnit;

2) user uses zoom out to get to appropriate baseUnit.

Lets handle second scenario. My situation is very similiar to this demo -- http://demos.telerik.com/kendo-ui/line-charts/date-axis

But I'm using category type of categoryAxis. When I start to play with date type I can't understand how it works... For example on my local data when I select days(and I have more then two weeks of one 15 min data) it always show to category (two points) and scrolling and zooming logic works very very strange.My ideal soultion for provided sample is following -- when there is already thirty 15min intervals (or 30 points) and user continues zoom out he smoothly gets to hours with the same scrolling and zooming functionality (lets consider no gaps). When he reaches say 24 hour intervals (24 points) and continue zooming he gets  'days' baseUnit and so on.

Is it achievable?

 

Thanks in advance.

 

3 Answers, 1 is accepted

Sort by
0
T. Tsonev
Telerik team
answered on 11 Jun 2015, 04:03 PM
Hi,

I'd like to ask if you've considered using the stock chart for this scenario? It will work with line series as well.

It might be easier to setup than trying to implement the same functionality from scratch. What do you think?

Regards,
T. Tsonev
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
0
Jose Mejia
Top achievements
Rank 1
answered on 11 Jun 2015, 04:43 PM

Hi.

Thank you for response. You get the point. It is basically what stock charts are doing -- zooming out automatically switching to years, month, days , hours... But I have few question:

1) Is it possible to customize  T shape point to simple point like in line charts? I guess yes...

2) Does it support multiply axis on chart like this?

3) Can it be used with angular js?

4) Does it support custom aggregation? 

Thanks in advance.

 

 

 

 

 

 

 

 

0
Accepted
T. Tsonev
Telerik team
answered on 15 Jun 2015, 02:48 PM
Hello,

I can confirm on all points:

1) Line series are supported with the caveat that the slope might be incorrect if there's missing data at the ends. The stock chart will discards data points outside the visible range and will not a plot a continuous line in the direction of the points that are left outside the screen.

2) Indeed. The configuration is pretty much the same.

3) Yes, the same basic concepts apply. Check out the regular chart AngularJS demo.

4) Yes, it's configured per-series.

I hope this helps.

Regards,
T. Tsonev
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
Tags
Charts
Asked by
Jose Mejia
Top achievements
Rank 1
Answers by
T. Tsonev
Telerik team
Jose Mejia
Top achievements
Rank 1
Share this question
or