Auto scale Y Axis

3 posts, 0 answers
  1. psyko
    psyko avatar
    2 posts
    Member since:
    Feb 2016

    Posted 13 Feb Link to this post


    I am using a RadCartesianChart plotting a CandlestickSerie to it with a DateTimeCategoricalAxis and a LinearAxis.

    I enabled the ChartPanAndZoomBehavior both on the horizontal mode.

    When I plot, let's say, 200 candles the LinearAxis maximum and minimum are somewhat consistent with the candles min/max (but still I'd like to have it more fit). But if I zoom in, the LinearAxis min/max is not updated to fit best what is now displayed.

    How can I get the current min / max of the DateTimeCategoricalAxis? I understand that there is no direct option to do so, but can I do it using the PanOffset or something else? Because with the min / max of the DateTimeCategoryAxis it would be very easy to programatically adjust the min / max of my LinearAxis.

    I put two screen without zoom and with zoom where you can see that the LinearAxis min / max is not updated and I highlighted around where I'd like to have it (basically it's a function of the displayed high/low of the serie) 


  2. psyko
    psyko avatar
    2 posts
    Member since:
    Feb 2016

    Posted 14 Feb in reply to psyko Link to this post

    Just found the HorizontalZoomRangeStart and HorizontalZoomRangeEnd parameters, I will manage with this :)
  3. DevCraft R3 2016 release webinar banner
  4. Peshito
    Peshito avatar
    493 posts

    Posted 17 Feb Link to this post


    I am glad you managed to solve this. As for the min and max of the DateTimeCategoricalAxis you should switch to DateTimeContinuous axis instead, in order to be able to use the Minimum and Maximum properties of the axis. You could also take advantage of the axis' ActualRange and ActualVisibleRange properties.

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Back to Top