Change default x-axis view to last 30 days

I have multiple graphs that are updated daily with one data point per day. The graph displays all data points and thus the x axis (day dates) grows in length daily. By default I would like to only display the last 30 days of data, while maintaining the ability to view all the data via the view modebar. For example, my simple bar chart data starts on Dec 16, 2016 so is approaching 200 days of display. I would like the default display to be from June 24-July 24 2017 (as of this writing), but with the ability to see all the data in the chart. I’ve reviewed the reference for bar chart and nothing is jumping out as the obvious answer.

Hey @scorcoran

have you considered using rangeslider or adding a button

1 Like

Thanks that’s just the tip I needed. Implemented it. Worked perfectly.