我有X值从0到55的数据.我希望将这些值看作刻度标签中的自定义文本.理想情况下,我想指定一些回调,比如
function tickLabel(tickValue) {
return "This is " + tickValue;
}
Run Code Online (Sandbox Code Playgroud)
可能吗?
Hiv*_*cks 17
我找到了解决方案.
xaxis: {
tickRenderer: $.jqplot.AxisTickRenderer,
tickOptions: {
formatter: function(format, value) { return "This is " + value; }
}
}
Run Code Online (Sandbox Code Playgroud)