valueFormatString - Format Axis X Labels - 0 | JSFiddle Sample Code
valueFormatString - Format Axis X Labels - 0 | JSFiddle Sample Code
HTML
<script src="https://canvasjs.com/assets/script/canvasjs.min.js"></script>
<div id="chartContainer" style="height: 300px; width: 100%;">
</div>
<div style="margin-top:16px;color:dimgrey;font-size:9px;font-family: Verdana, Arial, Helvetica, sans-serif;text-decoration:none;">Source: <a href="https://canvasjs.com/docs/charts/chart-options/axisx/valueformatstring/" target="_blank" title="valueFormatString - Format Axis X Labels ">https://canvasjs.com/docs/charts/chart-options/axisx/valueformatstring/</a></div>
JavaScript
window.onload = function () {
var chart = new CanvasJS.Chart("chartContainer",
{
axisX:{
title: "Axis Labels with formatting",
valueFormatString: "#,##0.##" // move comma to change formatting
},
axis:{
title: "Axis Labels with formatting",
valueFormatString: "0.0##e+00" // move comma to change formatting
},
data: [
{
type: "column",
dataPoints: [
{ x: 10000, y: 7100000000000000000000000 },
{ x: 20000, y: 55},
{ x: 30000, y: 50 },
{ x: 40000, y: 65 },
{ x: 50000, y: 95 },
{ x: 60000, y: 68 },
{ x: 70000, y: 28 },
{ x: 80000, y: 34 },
{ x: 90000, y: 14}
]
}
]
});
chart.render();
}