matplotlib.axes.Axes.stairs#
- Axes.stairs(values, edges=None, *, orientation='vertical', baseline=0, fill=False, data=None, **kwargs)[source]#
A stepwise constant function as a line with bounding edges or a filled plot.
- Parameters:
- valuesarray-like
The step heights.
- edgesarray-like
The edge positions, with
len(edges) == len(vals) + 1
, between which the curve takes on vals values.- orientation{'vertical', 'horizontal'}, default: 'vertical'
The direction of the steps. Vertical means that values are along the y-axis, and edges are along the x-axis.
- baselinefloat, array-like or None, default: 0
The bottom value of the bounding edges or when
fill=True
, position of lower edge. If fill is True or an array is passed to baseline, a closed path is drawn.- fillbool, default: False
Whether the area under the step curve should be filled.
- Returns:
- StepPatch
matplotlib.patches.StepPatch
- StepPatch
- Other Parameters:
- dataindexable object, optional
If given, all parameters also accept a string
s
, which is interpreted asdata[s]
(unless this raises an exception).- **kwargs
StepPatch
properties