drippy ====== .. py:module:: drippy .. autoapi-nested-parse:: drippy — EDA plotting library following NIST/SEMATECH principles. Submodules ---------- .. toctree:: :maxdepth: 1 /autoapi/drippy/comparative/index /autoapi/drippy/data/index /autoapi/drippy/multifactor/index /autoapi/drippy/onefactor/index /autoapi/drippy/regression/index /autoapi/drippy/timeseries/index /autoapi/drippy/univariate/index /autoapi/drippy/utilities/index Classes ------- .. autoapisummary:: drippy.EDAData Functions --------- .. autoapisummary:: drippy.block_plot drippy.star_plot drippy.youden_plot drippy.contour_plot drippy.doe_mean_plot drippy.doe_scatter_plot drippy.doe_sd_plot drippy.bihistogram drippy.box_plot drippy.mean_plot drippy.qq_plot drippy.scatter_plot drippy.sd_plot drippy.linear_correlation_plot drippy.linear_intercept_plot drippy.linear_residual_sd_plot drippy.linear_slope_plot drippy.six_plot drippy.autocorrelation_plot drippy.complex_demodulation_amplitude_plot drippy.complex_demodulation_phase_plot drippy.spectral_plot drippy.bootstrap_plot drippy.box_cox_linearity_plot drippy.box_cox_normality_plot drippy.four_plot drippy.histogram drippy.lag_plot drippy.normal_probability_plot drippy.ppcc_plot drippy.probability_plot drippy.run_sequence_plot drippy.weibull_plot Package Contents ---------------- .. py:function:: block_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Creates a block plot of y vs treatment, grouped by block. Shows treatment effects within each block as connected line segments, one series per block level. :param data: EDAData container. Requires factors with keys ``"treatment"`` and ``"block"``. :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :returns: The figure and axes containing the plot. :raises ValueError: If factors is None or missing required keys. .. py:function:: star_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Creates a star (radar) plot of multivariate data. Each observation is drawn as a polygon on a polar axis, with one spoke per variable. Values are normalized 0-1 per variable. :param data: EDAData container. Requires factors for additional variables beyond y. :param fig: Matplotlib figure. If None, creates new polar figure. :param ax: Matplotlib axes (polar). If None, creates new polar axes. :returns: The figure and axes containing the plot. :raises ValueError: If factors is None. .. py:function:: youden_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None, doe: bool = False) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Creates a Youden plot comparing two labs or measurement methods. Plots Lab 1 (y) vs Lab 2 (x) with an equality line and median reference lines to reveal bias and lab effects. :param data: EDAData container. Requires x (Lab 2 measurements) and y (Lab 1 measurements). :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :param doe: If True, overlays DOE design point markers. :returns: The figure and axes containing the plot. :raises ValueError: If x is None. .. py:class:: EDAData(y: collections.abc.Iterable[float], x: collections.abc.Iterable | None = None, t: collections.abc.Iterable[float] | None = None, factors: dict[str, collections.abc.Iterable] | None = None) Validated data container for EDA analysis. :param y: Response variable. Must be 1D and non-empty. :param x: Continuous predictor or single categorical factor. Must match len(y) if provided. :param t: Continuous index variable (e.g. time, 1/B, position). Not restricted to real time. Must match len(y) if provided. :param factors: Named factor arrays for multi-factor/DOE/comparative plots. Each value must match len(y). .. py:attribute:: y .. py:attribute:: x :value: None .. py:attribute:: t :value: None .. py:attribute:: factors :value: None .. py:method:: run_sequence_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegates to drippy.univariate.run_sequence_plot. .. py:method:: lag_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegates to drippy.univariate.lag_plot. .. py:method:: histogram(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegates to drippy.univariate.histogram. .. py:method:: normal_probability_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes, float | None] Delegates to drippy.univariate.normal_probability_plot. .. py:method:: four_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, numpy.ndarray] Delegates to drippy.univariate.four_plot. .. py:method:: ppcc_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, numpy.ndarray] Delegates to drippy.univariate.ppcc_plot. .. py:method:: weibull_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegates to drippy.univariate.weibull_plot. .. py:method:: probability_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegates to drippy.univariate.probability_plot. .. py:method:: box_cox_linearity_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegates to drippy.univariate.box_cox_linearity_plot. .. py:method:: box_cox_normality_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, numpy.ndarray] Delegates to drippy.univariate.box_cox_normality_plot. .. py:method:: bootstrap_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegates to drippy.univariate.bootstrap_plot. .. py:method:: spectral_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegates to drippy.timeseries.spectral_plot. .. py:method:: autocorrelation_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegates to drippy.timeseries.autocorrelation_plot. .. py:method:: complex_demodulation_amplitude_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegate to timeseries.complex_demodulation_amplitude_plot. .. py:method:: complex_demodulation_phase_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegate to drippy.timeseries.complex_demodulation_phase_plot. .. py:method:: scatter_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegates to drippy.onefactor.scatter_plot. .. py:method:: box_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegates to drippy.onefactor.box_plot. .. py:method:: bihistogram(**kwargs: Any) -> tuple[matplotlib.figure.Figure, numpy.ndarray] Delegates to drippy.onefactor.bihistogram. .. py:method:: qq_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegates to drippy.onefactor.qq_plot. .. py:method:: mean_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegates to drippy.onefactor.mean_plot. .. py:method:: sd_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegates to drippy.onefactor.sd_plot. .. py:method:: doe_scatter_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegates to drippy.multifactor.doe_scatter_plot (Phase 2). .. py:method:: doe_mean_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegates to drippy.multifactor.doe_mean_plot (Phase 2). .. py:method:: doe_sd_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegates to drippy.multifactor.doe_sd_plot (Phase 2). .. py:method:: contour_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegates to drippy.multifactor.contour_plot (Phase 2). .. py:method:: six_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, tuple[matplotlib.axes.Axes, matplotlib.axes.Axes, matplotlib.axes.Axes, matplotlib.axes.Axes, matplotlib.axes.Axes, matplotlib.axes.Axes]] Delegates to drippy.regression.six_plot (Phase 3). .. py:method:: linear_correlation_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegate to drippy.regression.linear_correlation_plot (Phase 3). .. py:method:: linear_intercept_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegate to drippy.regression.linear_intercept_plot (Phase 3). .. py:method:: linear_slope_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegates to drippy.regression.linear_slope_plot (Phase 3). .. py:method:: linear_residual_sd_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegate to drippy.regression.linear_residual_sd_plot (Phase 3). .. py:method:: block_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegates to drippy.comparative.block_plot (Phase 4). .. py:method:: youden_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegates to drippy.comparative.youden_plot (Phase 4). .. py:method:: star_plot(**kwargs: Any) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Delegates to drippy.comparative.star_plot (Phase 4). .. py:method:: _validate_y() -> None Validate y array. .. py:method:: _validate_and_convert_x(x: collections.abc.Iterable | None) -> numpy.ndarray | None Validate and convert x array. .. py:method:: _validate_and_convert_t(t: collections.abc.Iterable[float] | None) -> numpy.ndarray | None Validate and convert t array. .. py:method:: _validate_and_convert_factors(factors: dict[str, collections.abc.Iterable] | None) -> dict[str, numpy.ndarray] | None Validate and convert factors dict. .. py:function:: contour_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None, doe: bool = False) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Creates a contour plot of y over the 2D factor space. Uses tricontourf for robustness with irregular/DOE grids. :param data: EDAData container. Requires exactly 2 factors. :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :param doe: If True, overlays design point markers. :returns: The figure and axes containing the plot. .. py:function:: doe_mean_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, axes: numpy.ndarray | None = None) -> tuple[matplotlib.figure.Figure, numpy.ndarray] Creates mean plots of y grouped by each factor's levels. Shows group means connected by a line and a horizontal grand-mean reference line for each factor. :param data: EDAData container. Requires factors. :param fig: Matplotlib figure. If None, creates new figure. :param axes: 1-D array of Axes, one per factor. If None, creates new axes. :returns: (fig, axes) where axes is a 1-D array of Axes. .. py:function:: doe_scatter_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, axes: numpy.ndarray | None = None) -> tuple[matplotlib.figure.Figure, numpy.ndarray] Creates scatter plots of y vs each factor. One subplot per factor in data.factors. :param data: EDAData container. Requires factors. :param fig: Matplotlib figure. If None, creates new figure. :param axes: 1-D array of Axes, one per factor. If None, creates new axes. :returns: (fig, axes) where axes is a 1-D array of Axes. .. py:function:: doe_sd_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, axes: numpy.ndarray | None = None) -> tuple[matplotlib.figure.Figure, numpy.ndarray] Creates standard deviation plots of y by each factor's levels. Shows group standard deviations connected by a line and a horizontal overall-SD reference line for each factor. :param data: EDAData container. Requires factors. :param fig: Matplotlib figure. If None, creates new figure. :param axes: 1-D array of Axes, one per factor. If None, creates new axes. :returns: (fig, axes) where axes is a 1-D array of Axes. .. py:function:: bihistogram(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, axes: numpy.ndarray | None = None, bins: int | str = 'auto') -> tuple[matplotlib.figure.Figure, numpy.ndarray] Creates side-by-side histograms for exactly 2 factor levels. :param data: EDAData container. Requires x with exactly 2 unique levels. :param fig: Matplotlib figure. If None, creates new figure. :param axes: Array of 2 Axes. If None, creates new axes. :param bins: Number of bins or bin strategy. :returns: (fig, axes) where axes is a 1-D array of 2 Axes. .. py:function:: box_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Creates a box plot of y grouped by factor levels in x. :param data: EDAData container. Requires x (categorical). :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :returns: The figure and axes containing the plot. .. py:function:: mean_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Creates a mean plot of y grouped by factor levels in x. Shows group means connected by a line, with a horizontal grand mean. :param data: EDAData container. Requires x. :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :returns: The figure and axes containing the plot. .. py:function:: qq_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Creates a quantile-quantile plot comparing 2 factor level distributions. :param data: EDAData container. Requires x with exactly 2 unique levels. :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :returns: The figure and axes containing the plot. .. py:function:: scatter_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Creates a scatter plot of y vs x. Also used in regression context (see drippy.regression). :param data: EDAData container. Requires x. :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :returns: The figure and axes containing the plot. .. py:function:: sd_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Creates a standard deviation plot of y grouped by factor levels in x. Shows group standard deviations connected by a line, with a horizontal overall standard deviation reference line. :param data: EDAData container. Requires x. :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :returns: The figure and axes containing the plot. .. py:function:: linear_correlation_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None, window: int = 10) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Plots Pearson correlation coefficient for rolling windows of data. :param data: EDAData container. Requires x. :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :param window: Number of observations per rolling window. :returns: The figure and axes containing the plot. .. py:function:: linear_intercept_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None, window: int = 10) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Plots OLS regression intercept for rolling windows of data. :param data: EDAData container. Requires x. :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :param window: Number of observations per rolling window. :returns: The figure and axes containing the plot. .. py:function:: linear_residual_sd_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None, window: int = 10) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Plots residual standard deviation for rolling windows of data. :param data: EDAData container. Requires x. :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :param window: Number of observations per rolling window. :returns: The figure and axes containing the plot. .. py:function:: linear_slope_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None, window: int = 10) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Plots OLS regression slope for rolling windows of data. :param data: EDAData container. Requires x. :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :param window: Number of observations per rolling window. :returns: The figure and axes containing the plot. .. py:function:: six_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, axes: numpy.ndarray | None = None) -> tuple[matplotlib.figure.Figure, numpy.ndarray] Creates a 2x3 composite regression diagnostic plot. The six panels are: scatter with regression line, residuals vs x, lag plot of residuals, histogram of residuals, normal probability plot of residuals, and run sequence of residuals. :param data: EDAData container. Requires x. :param fig: Matplotlib figure. If None, creates new figure. :param axes: 2x3 array of Axes. If None, creates new axes. :returns: (fig, axes) where axes has shape (2, 3). .. py:function:: autocorrelation_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Creates autocorrelation plot with confidence intervals. Includes 99%, 95%, and 80% confidence intervals. :param data: EDAData container. Requires y. :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :returns: The figure and axes containing the plot. .. py:function:: complex_demodulation_amplitude_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Creates instantaneous amplitude plot via Hilbert transform. :param data: EDAData container. Requires t. :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :returns: The figure and axes containing the plot. .. py:function:: complex_demodulation_phase_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Creates instantaneous phase plot via Hilbert transform with linear fit. :param data: EDAData container. Requires t. :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :returns: The figure and axes containing the plot. .. py:function:: spectral_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None, alarm_levels: bool = True) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Creates a Lomb-Scargle periodogram. :param data: EDAData container. Requires t. :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :param alarm_levels: Whether to show false alarm probability levels. :returns: The figure and axes containing the plot. .. py:function:: bootstrap_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None, statistic: collections.abc.Callable = np.mean, n_bootstrap: int = 10000) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Creates a bootstrap distribution plot. :param data: EDAData container. Requires y. :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :param statistic: Callable to bootstrap. Must be callable. :param n_bootstrap: Number of bootstrap resamples. :returns: The figure and axes containing the plot. .. py:function:: box_cox_linearity_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None, lmbda_range: tuple[float, float] = (-2, 2), n: int = 100) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Creates a Box-Cox linearity plot. Plots ``abs(corr(Y, X^λ))`` across a range of λ values to find the power transformation of X that maximises linearity with Y. :param data: EDAData container. Requires x > 0. :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :param lmbda_range: (min, max) range of λ to evaluate. :param n: Number of λ values to evaluate. :returns: The figure and axes containing the plot. .. py:function:: box_cox_normality_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, axes: numpy.ndarray | None = None) -> tuple[matplotlib.figure.Figure, numpy.ndarray] Creates a Box-Cox normality plot (2x2 grid). Shows: original histogram, Box-Cox normality curve, transformed histogram, normal probability plot of transformed data. :param data: EDAData container. Requires y > 0. :param fig: Matplotlib figure. If None, creates new figure. :param axes: ndarray of Axes with shape (2, 2). If None, creates new. :returns: (fig, axes) where axes has shape (2, 2). .. py:function:: four_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, axes: numpy.ndarray | None = None) -> tuple[matplotlib.figure.Figure, numpy.ndarray] Creates a 4-plot (run sequence, lag, histogram, normal probability). :param data: EDAData container. Requires y. :param fig: Matplotlib figure. If None, creates new figure. :param axes: ndarray of Axes with shape (2, 2). If None, creates new axes. :returns: (fig, axes_flat) where axes_flat has shape (4,). .. py:function:: histogram(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None, bins: int | str = 'auto') -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Creates a histogram of the data. :param data: EDAData container. Requires y. :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :param bins: Number of bins or bin strategy. :returns: The figure and axes containing the plot. .. py:function:: lag_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None, lag: int = 1) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Creates a lag plot of the data. :param data: EDAData container. Requires y. :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :param lag: Number of lags. Must be positive and less than len(y). :returns: The figure and axes containing the plot. .. py:function:: normal_probability_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None, *, return_rsquared: bool = False) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes, float | None] Creates a normal probability plot. :param data: EDAData container. Requires y. :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :param return_rsquared: If True, includes R-squared as the third element. :returns: (fig, ax, r_squared) where r_squared is None if return_rsquared is False. .. py:function:: ppcc_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: numpy.ndarray | None = None, rough_range: tuple[float, float] = (-2, 2), n_rough: int = 50, n_fine: int = 100) -> tuple[matplotlib.figure.Figure, numpy.ndarray] Creates a PPCC plot (rough + fine) for distribution shape estimation. :param data: EDAData container. Requires y. :param fig: Matplotlib figure. If None, creates new figure. :param ax: ndarray of Axes with shape (2,). If None, creates new axes. :param rough_range: (min, max) range for rough search. :param n_rough: Points in rough plot. :param n_fine: Points in fine plot. :returns: (fig, axes) where axes has shape (2,). .. py:function:: probability_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None, distribution: str = 'norm') -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Creates a probability plot for a specified distribution. :param data: EDAData container. Requires y. :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :param distribution: scipy.stats distribution name. :returns: The figure and axes containing the plot. .. py:function:: run_sequence_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Creates a run sequence plot of y vs index or continuous index t. :param data: EDAData container. Uses t as x-axis if present, else index. :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :returns: The figure and axes containing the plot. .. py:function:: weibull_plot(data: drippy.data.EDAData, fig: matplotlib.figure.Figure | None = None, ax: matplotlib.axes.Axes | None = None) -> tuple[matplotlib.figure.Figure, matplotlib.axes.Axes] Creates a Weibull probability plot. :param data: EDAData container. Requires y > 0. :param fig: Matplotlib figure. If None, creates new figure. :param ax: Matplotlib axes. If None, creates new axes. :returns: The figure and axes containing the plot.