Plotting Utilities¶
This page documents plotting utilities for visualizing distribution treatment effects, confidence intervals, and other results.
plot ¶
plot(
X: ndarray,
means: ndarray,
lower_bounds: ndarray,
upper_bounds: ndarray,
chart_type: str = "line",
color: str = "green",
ax: Optional[Axis] = None,
title: Optional[str] = None,
xlabel: Optional[str] = None,
ylabel: Optional[str] = None,
weighted: bool = False,
)
Visualize distributional parameters and their confidence intervals.
Args: X (np.Array): values to be used for x axis. means (np.Array): Expected distributional parameters. lower_bounds (np.Array): Lower bound for the distributional parameters. upper_bounds (np.Array): Upper bound for the distributional parameters. chart_type (str): Chart type of the plotting. Available values are line or bar. color (str): The color of lines or bars. ax (matplotlib.axes.Axes, optional): Target axes instance. If None, a new figure and axes will be created. title (str, optional): Axes title. xlabel (str, optional): X-axis title label. ylabel (str, optional): Y-axis title label. weighted (bool, optional): If True, multiply treatment effects by X values to show value-weighted effects. Defaults to False.
Returns: matplotlib.axes.Axes: The axes with the plot.