plot_bland_altman
Note
This page is a reference documentation. It only explains the function signature, and not how to use it. Please refer to the Habitat Guide and Python API guide (v2.0) for usage.
- plot_bland_altman(y_true: ndarray, y_pred: ndarray, *, x_label: str = 'Mean of observed and predicted', y_label: str = 'Difference (observed - predicted)', sd_factor: float = 1.96)[source]
Bland-Altman limits-of-agreement plot.
The difference between two measurements is plotted against their mean, with the bias (mean difference) and the limits of agreement at
sd_factorstandard deviations. This is the standard way to show whether a predictor agrees with the reference across the whole range, rather than only on average.- Parameters:
y_true – Observed (reference) responses.
y_pred – Predicted responses.
x_label – X-axis label (sanitised).
y_label – Y-axis label (sanitised).
sd_factor – Multiplier for the limits of agreement (1.96 for ~95%).
- Returns:
The matplotlib
Figure.