JQuery-Flot: how to add text label for Y axis and date stamp for X axis?

So basically, I have a test chart in jQuery-Flot, but instead of a normal solid axis. I need to use a text label for the Y axis and a date stamp for the X axis. Does anyone know how to do this?

+5
source share
1 answer

flot api covers both of these cases (in the "Axis Settings" section). For the x axis, you want to use the "time" parameter . For Y-axis label shortcuts, you want to specify the tick option (which text should appear in each place):

ticks: [[0, "zero"], [1.2, "one mark"], [2.4, "two marks"]] 
+9
source

All Articles