Flot Bar Graph Align Bars with X-Axis Labels

前端 未结 2 473
余生分开走
余生分开走 2021-01-25 05:50

Hello I am trying to plot a bar chart with 31 days data. However when I plot it, the label for each data is not directly in the center below its bar, when i set the bars to

2条回答
  •  悲哀的现实
    2021-01-25 06:51

    This is a known issue; you'll need to work around it by adjusting the axis min and max. For example, if you have ticks at 0, 1, 2, you will want to set the min to -0.5 and the max to 2.5 to account for the bar width and centering. This should be easy given that you already have sliders to specify those values.

提交回复
热议问题