scale intervals on x-axis of KendoUI Charts

5 posts, 0 answers
  1. Babar
    Babar avatar
    4 posts
    Member since:
    Oct 2012

    Posted 15 May 2013 Link to this post

    I have an array for categoryAxis data as follows:

     
    categoryAxis: {
                        categories: ["30", "31", "32", "33", "34", "35", "36", "37", "38", "39", "40", "41", "42", "43", "44", "45", "46", "47", "48", "49", "50", "51", "52", "53", "54", "55", "56", "57", "58", "59", "60", "61", "62", "63", "64", "65", "66", "67", "68", "69", "70", "71", "72", "73", "74", "75", "76", "77", "78", "79", "80", "81", "82", "83", "84", "85", "86", "87", "88"],
     
                        title: {
                            text: "Age"
                        }
                    },


    and I want the chart to display this data with an interval of 5; such as:

    30......35......40......45... and so on.

    how is this possible?
  2. Iliana Nikolova
    Admin
    Iliana Nikolova avatar
    2592 posts

    Posted 15 May 2013 Link to this post

    Hi Babar,

    You can achieve this as set labels.step 5 for the categoryAxis. I.e.: 
    $("#chart").kendoChart({
      //....
      categoryAxis: {
         //....
         labels: {
             step: 5
         }
      }
    });

    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!
  3. Kendo UI is VS 2017 Ready
  4. Babar
    Babar avatar
    4 posts
    Member since:
    Oct 2012

    Posted 15 May 2013 Link to this post

    Thanx. It helped :-)
  5. RamaKrishna P
    RamaKrishna P avatar
    7 posts
    Member since:
    Jun 2010

    Posted 22 Aug 2013 Link to this post

    Hi Iliana Nikolova, I have struck with scaling part(i.e not steps, scaling ticks on categoryAxis ) merged with each other bcz huge values. I am expecting  ticks along with steps only.
    categoryAxis: {
                                                            field: "timestamp",
                                                            //categories:[251, 501, 751, 1001, 1251, 1501],
                                                            labels: {
                                                                step: 250,
                                                                rotation: 0
                                                            },
                                                            //baseUnit: 250,
                                                            majorGridLines: {
                                                                visible: true
                                                            }
                                                        },
  6. Iliana Nikolova
    Admin
    Iliana Nikolova avatar
    2592 posts

    Posted 26 Aug 2013 Link to this post

    Hi RamaKrishna,

    I am afraid setting step on the majorTicks / minorTicks is not supported in Kendo UI Chart at this point, however we keep this idea in mind for future releases. Please excuse us for the inconvenience caused.
     

    Regards,
    Iliana Nikolova
    Telerik
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Back to Top
Kendo UI is VS 2017 Ready