margin: Number

This property lets you set margin between chart’s boundary and Axis.

Default: 2
Example: 8, 10..
Notes
  • It is applied below or to the left side of Axis depending on whether it is horizontal or vertical
  1. var chart = new CanvasJS.Chart("container",
  2. {
  3. .
  4. .
  5. axisY:{
  6. title: "Title with Margin",
  7. margin: 10,
  8. },
  9. .
  10. .
  11. });
  12. chart.render();

Try Editing The Code


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

3 Comments

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