Black Lives Matter. Please consider donating to Black Girls Code today.
Dash HoloViews is now available! Check out the docs.

How to have consistent gaps in a time series bar chart

We have a bar chart with months. In this chart February and March have a smaller gap than other months, because Feb has less days I suppose.

Problem shown here:

How can I have a consistent gap?

Thanks

Unfortunately, I can’t think of an easy way to fix this problem apart for type: 'date' axes.

Plotting your data using categories would solve this issue, but I doubt that’s what you had in mind.

That said, we’re currently working on adding explicit bar width settings see https://github.com/plotly/plotly.js/issues/80 for more details. This feature is set to be part of plotly.js 1.19.0.