8
沒有數據集中的項目包含小數點,但在它的自動縮放程序有時會決定我告訴中介小數點flotchart,圖形上規模禁用小數點我flotgraphs
我不希望它做到這一點,反正有沒有這樣做?
的原因,這是重要的,因爲在這組數據從未十進制值,因此無需暗示會有或認爲它是一個有用的除了規模
http://jsfiddle.net/gamm/t3Vqh/2/
var dataset = [overdue, open, completed];
var options = {
series: {
stack: true,
bars: {
show: true
}
},
bars: {
align: "center",
horizontal: false,
barWidth: .8,
lineWidth: 0
},
grid: {
borderWidth: 0,
borderColor: null,
backgroundColor: null,
labelMargin: 10,
minBorderMargin: 10
},
yaxis: {
tickColor: "FFFFFF"
},
xaxis: {
tickColor: "FFFFFF",
ticks: [
[1, "Public Works"],
[2, "Sanitation"],
[3, "Mayor"],
[4, "L&I"],
[5, "Police"]
]
},
legend: {
position: 'ne',
show: true
}
};
$.plot($("#example-section15 #flotcontainer"), dataset, options);