minimum: Number/Date/Timestamp

Sets the minimum value of Axis. Values smaller than minimum are clipped. minimum also sets the lower limit while panning chart.

Default: Automatically Calculated based on the data
Example: 100, 350..
Notes
  • If minimum value is not set, it is automatically calculated based on given data.
  • While setting minimum, it should be taken care that maximum is greater than minimum.
  • minimum supports dateTime values in the form of Date object or a timeStamp.
var  chart =  new  CanvasJS.Chart("container",
{
 .
 .
 axisX:{
   minimum: 150,
 },
 .
 . 
});
chart.render();


Try Editing The Code

  Also See:    


If you have any questions, please feel free to ask in our forums.Ask Question

12 Comments

  1. Fabian Danner says:

    Is it possible to change the minimum and maximum dynamically? Tried it with variables as values but if variable change and chart is rendered the minimum and maximum aren’t renewed.

  2. Bartel Welch says:

    Is there a callback function to get the min and max values? For example, i pass in all the data and since the min and max is being calculated anyway, can I retrieve those values?

    • Anjali says:

      [update]

      We have just released v1.9.6 Beta with Methods & Properties, which allows you to programmatically export chart as image, print chart, access internally calculated values, etc. Please refer to the release blog for more information.

      Bartel,

      We still don’t have an API to access auto-calculated values.

    • Vishwas R says:

      Veeru,

      We have introduced Methods & Properties in v1.9.6 which lets you know the auto-calculated values like minimum, maximum, interval, etc. Please refer to blog-post for more information.

If you have any questions, please feel free to ask in our forums. Ask Question