JavaScript
window.onload = function () {
var chart = new CanvasJS.Chart("chartContainer",{
title:{
text: "Multiple Y Axis"
},
axisX:{
valueFormatString: "####",
interval: 1
},
axisY:[{
title: "",
margin: -5,
gridThickness: 0,
tickLength: 0,
tickThickness: 0,
titleFontSize: 0,
labelFormatter: function(e) {
return "";
},
lineThickness: 0,
crosshair: {
enabled: false,
}
}, {
title: "",
margin: -5,
gridThickness: 0,
tickThickness: 0,
tickLength: 0,
titleFontSize: 0,
labelFormatter: function(e) {
return "";
},
lineThickness: 0,
crosshair: {
enabled: false,
}
}, {
title: "",
margin: -5,
gridThickness: 0,
tickThickness: 0,
tickLength: 0,
titleFontSize: 0,
labelFormatter: function(e) {
return "";
},
lineThickness: 0,
crosshair: {
enabled: false,
}
}, {
title: "",
margin: -5,
gridThickness: 0,
tickThickness: 0,
tickLength: 0,
titleFontSize: 0,
labelFormatter: function(e) {
return "";
},
lineThickness: 0,
crosshair: {
enabled: false,
}
}],
data: [
{
type: "line",
showInLegend: true,
name: "Axis Y-1",
xValueFormatString: "####",
dataPoints: [
{ x: 2006, y: 6 },
{ x: 2007, y: 2 },
{ x: 2008, y: 5 },
{ x: 2009, y: 7 },
{ x: 2010, y: 1 },
{ x: 2011, y: 5 },
{ x: 2012, y: 5 },
{ x: 2013, y: 2 },
{ x: 2014, y: 2 }
]
},
{
type: "line",
showInLegend: true,
name: "Axis Y-2",
xValueFormatString: "####",
dataPoints: [
{ x: 2006, y: 15 },
{ x: 2007, y: 3 },
{ x: 2008, y: 20...