1
我想在過去的xaxis
選項有一定的空間,最後一棒。
例如:
xaxis. min:-max:6
- 只有一半的最後一棒的顯示,如果我嘗試使用
tickOption
,它不會出現,因爲它是畫布之外。
代碼: http://jsfiddle.net/chalien/zEQe7/
THANKS
我想在過去的xaxis
選項有一定的空間,最後一棒。
例如:
xaxis. min:-max:6
tickOption
,它不會出現,因爲它是畫布之外。代碼: http://jsfiddle.net/chalien/zEQe7/
THANKS
你的陣列並不適合條形圖設置。你不需要告訴情節呈現它是點數1,2,3等等,它是由他自己知道的。
數組定義就變成:
[[4, 6, 2, 5, 6]]
和你的圖表將被正確地呈現,有或沒有min
和max
定義。
下面是完整的代碼:
<script type="text/javascript">
$.jqplot('chart2', [[4, 6, 2, 5, 6]],
{ title:'Exponential Line',
seriesDefaults: {
renderer: $.jqplot.BarRenderer,
rendererOptions: {
varyBarColor: true
}
},
axes: {
xaxis: {
max:6,
min:0,
renderer: $.jqplot.LinearAxisRenderer
}
}
});
</script>
請,如果答案是有幫助的,接受它。謝謝。 – 2012-03-18 14:09:52