mesmer.stats.LinearRegression.predict#
- LinearRegression.predict(predictors, exclude=None)#
Predict using the linear model.
- Parameters:
predictors (dict of xr.DataArray | DataTree | xr.Dataset) – A dict of
DataArray
objects used as predictors or aDataTree
, holding each predictor in a leaf. Each predictor must be 1D and containdim
. If predictors is axr.Dataset
, it must have each predictor as a singleDataArray
.exclude (str or set of str, default: None) – Set of variables to exclude in the prediction. May include
"intercept"
to initialize the prediction with 0.
- Returns:
prediction (xr.DataArray) – Returns predicted values.