How can I plot a bar chart from a Python Xarray dataset (eg. rain data axis)?
I am already using this code to resize the plot
fig, ax = plt.subplots(figsize=(9, 9))
dsfanadia.rain.plot(ax=ax)
Thank you
@hugo-pires -
xarray's plotting module does not have a bar chart method at this time (api ref). You can, of course, export your data array to a pandas series and use the pandas bar chart. Psudo code...
fig, ax = plt.subplots(figsize=(9, 9))
rain_series = dsfanadia.rain.to_series()
rain_series.plot.bar(ax=ax)
Thank you.
Most helpful comment
@hugo-pires -
xarray's plotting module does not have a bar chart method at this time (api ref). You can, of course, export your data array to a pandas series and use the pandas bar chart. Psudo code...