diff --git a/pandas/plotting/_core.py b/pandas/plotting/_core.py index e466a215091ea..b3c4d3138e915 100644 --- a/pandas/plotting/_core.py +++ b/pandas/plotting/_core.py @@ -985,6 +985,13 @@ def line(self, x=None, y=None, **kwargs): ... 'lifespan': lifespan}, index=index) >>> ax = df.plot.bar(rot=0) + Plot stacked bar charts for the DataFrame + + .. plot:: + :context: close-figs + + >>> ax = df.plot.bar(stacked=True) + Instead of nesting, the figure can be split by column with ``subplots=True``. In this case, a :class:`numpy.ndarray` of :class:`matplotlib.axes.Axes` are returned. @@ -1066,6 +1073,13 @@ def bar(self, x=None, y=None, **kwargs): ... 'lifespan': lifespan}, index=index) >>> ax = df.plot.barh() + Plot stacked barh charts for the DataFrame + + .. plot:: + :context: close-figs + + >>> ax = df.plot.barh(stacked=True) + We can specify colors for each column .. plot::