$ (' #container '). Highcharts ({Chart: {Zoomtype: ' XY '},Title: {Text: ' Average Monthly temperature and rainfall in Tokyo '},Subtitle: {Text: ' Source:WorldClimate.com '},Xaxis: [{Categories: [' Jan ', ' Feb ', ' Mar ', ' Apr ', ' may ', ' June ',' Jul ', ' the ' ", ' Sep ', ' Oct ', ' Nov ', ' Dec ']}],YAxis: [{//Primary YAxisLabels: {Format: ' {value}°c ',Style: {Color:Highcharts.getOptions (). Colors[1]}},Title: {Text: ' Temperature ',Style: {Color:Highcharts.getOptions (). Colors[1]}}}, {//secondary YAxisTitle: {Text: ' Rainfall ',Style: {Color:Highcharts.getOptions (). Colors[0]}},Labels: {Format: ' {value} mm ',Style: {Color:Highcharts.getOptions (). Colors[0]}}}],ToolTip: {Shared:true},Legend: {Layout: ' Vertical ',Align: ' left ',X:120,VerticalAlign: ' Top ',Y:100,Floating:true,BackgroundColor: (highcharts.theme && Highcharts.theme.legendBackgroundColor) | | ' #FFFFFF '},Series: [{Name: ' Rainfall ',Type: ' column ',Yaxis:1,Data: [49.9, 71.5, 106.4, 129.2, 144.0, 176.0, 135.6, 148.5, 216.4, 194.1, 95.6, 54.4],ToolTip: {Valuesuffix: ' mm '} }, {Name: ' Temperature ',Type: ' Spline ',Data: [7.0, 6.9, 9.5, 14.5, 18.2, 21.5, 25.2, 26.5, 23.3, 18.3, 13.9, 9.6],ToolTip: {Valuesuffix: ' °c '}}]});
Solution: Turn the numbers in data into digital.
var num= ' 12 ';
var data=new Array ();
data . push (parseint (num));
/span>
Problem solving
The Highcharts code is all right, but the picture is not displayed