Home forums Using CanvasJS Set XAxis Value to start at 0

This topic contains 5 replies, has 4 voices, and was last updated by  Indranil Deo 3 weeks, 6 days ago.

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #11292

    Extrabeefy
    Member

    Hey All,

    I was wondering if there is a way to set the XAxis and Y Axis to start at 0. Currently they both start at whatever there lowest value is in the dataPoints be that 0, 0.2, 0.5.

    Thanks for the help!
    -Extrabeefy

    #11295

    Vishwas R
    Keymaster

    Extrabeefy,

    You can set axisX minimum and axisY minimum to 0 to make both axis start from 0.

    #11315

    Extrabeefy
    Member

    Ah ok thank you from the example I figured it meant if I didn’t have a value of 0 then it would show 0.2. Thank you!

    • This reply was modified 1 year, 4 months ago by  Extrabeefy.
    #16097

    Hi,

    I have a problem. I need to show a line chart which will always start from the yaxis line edge. That means, i cannot set x: 0, because that will move the data point a little right from the y axis line. A sample is shown in the image. Is there any way i can do this?null

    #16098

    Line Chart Start From Y Axis Edge

    #16102

    Indranil Deo
    Member

    @vishnumohan89,

    You can do so by setting axisX minimum to 0.

    ___________
    Indranil Deo,
    Team CanvasJS

Viewing 6 posts - 1 through 6 (of 6 total)

You must be logged in to reply to this topic.