import hvplot.pandas # noqa
barh()
is similar to .bar()
but plots bars horizontally rather than vertically. These charts can be created from dataframes with regular Index
or MultiIndex
.
from bokeh.sampledata.autompg import autompg_clean as df
table = df.groupby(['origin', 'mfr'])['mpg'].mean().sort_values()
table.head()
table.hvplot.barh('mfr', 'mpg', by='origin', stacked=True, legend='bottom_right', height=600)