Highcharts如何更改x轴选项 [英] Highcharts how to change x axis options
问题描述
在Highcharts中,我想将默认起点从0更改为1,我可以在哪里找到更改
的选项。我只有数据点,因此绘制在y轴上,x轴只包含默认值数字,即0,1,2等。我想改变从0到1的起点
In Highcharts I want to change the default starting point from 0 to 1 is where can i find the option to change I have only data points so that are plotted on y axis and the x axis simply contain the default numbers ie 0,1,2, etc.. i want to change the starting point from 0 to 1
感谢提前
b
$ b
您需要在X轴类别内使用min选项。阅读更多关于这里: http://api.highcharts.com/highcharts#xAxis
xAxis: {
min: 1,
categories: ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11']
},
这些选项包括'0'作为类别,但图表从'1'位置开始绘制。
These options include the '0' as a category but the chart is drawn starting at the '1' position.
我把一个简单的jsfiddle放在一起,显示你想在这里完成的任务: http:/ /jsfiddle.net/L35DP/
I put together a simple jsfiddle showing what you wanted to accomplish here: http://jsfiddle.net/L35DP/
这篇关于Highcharts如何更改x轴选项的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!