fill_betweenx_wrapper

fill_betweenx_wrapper(self, func, *args, **kwargs)[source]

Supports overlaying and stacking successive columns of data, and permits using different colors for “negative” and “positive” regions.

Note

This function wraps fill_betweenx and areax.

Parameters
  • *args ((x1,), (y, x1), or (y, x1, x2)) – The y and x coordinates. If y is not provided, it will be inferred from x1. If x1 and x2 are provided, this function will shade between respective columns of the arrays. The default value for x2 is 0.

  • stacked (bool, optional) – Whether to “stack” successive columns of the x1 array. If this is True and x2 was provided, it will be ignored.

  • negpos (bool, optional) – Whether to shade where x1 is greater than x2 with the color poscolor, and where x1 is less than x2 with the color negcolor. For example, to shade positive values red and negative values blue, use ax.fill_betweenx(y, x, negpos=True).

  • negcolor, poscolor (color-spec, optional) – Colors to use for the negative and positive shaded regions. Ignored if negpos is False. Defaults are rc.negcolor = 'blue7' and rc.poscolor = 'red7'.

  • where (ndarray, optional) – Boolean ndarray mask for points you want to shade. See this example.

  • lw, linewidth (float, optional) – The edge width for the area patches.

  • edgecolor (color-spec, optional) – The edge color for the area patches.

Other Parameters

**kwargs – Passed to fill_between.