Reputation: 1332
I'm working on a project and I need to use some charts. For this project I've chosen to use Flot: http://code.google.com/p/flot/
The problem is, how can I change the x-axis values? From a database I receive the data and parse it to the flot. No problem.
But sometimes I only receive 2 values from the database and the x-axis seems weird.
Instead of: 0, 0.5, 1, 1.5, 2, 2.5, ... I only want 0, 1, 2, 3, ...
Some goes for the y-axis
Thanks
Upvotes: 1
Views: 427
Reputation: 1
I think you could solve it also with this here:
xaxis: { tickDecimals: 0 }
See orginal post: Put only integers in x and y axis of bar and line graphs - Flot
Upvotes: 0