[英]HighChart doesn't output anything
I am using HighChart to draw a graph, but it doesn't print out anything I have check the 'data' array that is passed and there seems to be nothing wrong with it 我正在使用HighChart绘制图形,但是它没有打印出任何内容,我已经检查了传递的“数据”数组,似乎没有任何问题
my code looks like this: 我的代码如下所示:
var high = []; //data
$.each(data.getHighValue, function (key, value) {
high.push(value.High);
});
$(function () {
$('#container').highcharts({
chart: {
type: 'line',
marginRight: 130,
marginBottom: 25
},
title: {
text: 'Weekyly Data',
x: -20 //center
},
subtitle: {
text: 'From Arp 1st ro Apr 15th',
x: -20
},
xAxis: {
categories: ['Mon', 'Tues', 'Weds', 'Thurs', 'Fri', 'Sat', 'Sun']
},
yAxis: {
title: {
text: 'Blood Level (unit)'
},
plotLines: [{
value: 0,
width: 1,
color: '#808080'
}]
},
tooltip: {
valueSuffix: 'unit'
},
legend: {
layout: 'vertical',
align: 'right',
verticalAlign: 'top',
x: -10,
y: 100,
borderWidth: 0
},
series: [{
name: 'High Blood Level',
data: high
}]
});
});
My 'high' array has these values: 113, 114, 115, 116, 117, 115, 127 我的“高”数组具有以下值:113、114、115、116、117、115、127
You probably loaded jQuery after Highcharts. 您可能在Highcharts之后加载了jQuery。 It needs to be loaded before Highcharts.
需要在Highcharts之前加载它。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.