0
我製作了一張使用highcharts的蜘蛛圖表,但數據點已移至最左側。我正在關注這個。這裏是我的代碼:Highchart蜘蛛網圖表
<div id="container2" style=" position: relative;"></div>
<script>
$(function() {
$('#container2').highcharts({
chart: {
polar: true,
type: 'line',
margin: 0
},
exporting: {
enabled: false,
buttons: {
enabled: false
}
},
title: {
text: ' ',
x: -80,
useHTML: true
},
pane: {
size: '70%'
},
xAxis: {
categories: ['Math', 'Comp. Sci', 'Science', 'Social Sci.', 'English', 'Hindi'],
tickmarkPlacement: 'on',
lineWidth: 0,
labels: {
align: 'center',
distance: 43
}
},
yAxis: {
gridLineInterpolation: 'polygon',
lineWidth: 0,
min: 0,
endOnTick: true,
showLastLabel: true,
tickPositions: [0.2, 0.4, 0.6, 0.8, 1.0]
},
tooltip: {
shared: true,
headerFormat: '<span style="font-size: 12px">{point.key}:</span> <b>{point.y:,.2f}</b>',
pointFormat: '',
useHTML: true
},
legend: {
enabled: true,
align: 'right',
verticalAlign: 'top',
y: 30,
layout: 'vertical'
},
series: [{
name: 'Grade Distribution',
data: [.8, .95, .7, .35, .6, .3],
pointPlacement: 'on',
color: 'black',
fillOpacity: 0.2
}]
});
});
我在我的代碼中查找干擾css,但沒有找到任何東西。任何想法可能會造成這種情況?
重新創建的jsfiddle問題。你發佈的代碼是http://jsfiddle.net/uh1obkte/,所以很難猜測你身邊發生了什麼。 – morganfree