I would like to round (0 decimals) the values on the x-axis of a flot graph. The x-axix show week numbers. Does anyone know how to do that?
开发者_StackOverflow中文版http://www.snowcams.eu/snowcondition/saas%20fee/998
Here is your solution (this can all be found in the plugin API Documentation)
$.plot(
$("#placeholder"),
[{data:d1, lines:{show: true}, points:{show: true}, label:"Mountain"}],
{xaxis: {tickSize:1, tickDecimals:0 }}
);
精彩评论