predict_model | R Documentation |
predict_model function takes a disag_model object created by disaggregation::disag_model and predicts mean maps.
predict_model(
model_output,
new_data = NULL,
predict_iid = FALSE,
newdata = NULL
)
model_output |
disag_model object returned by disag_model function |
new_data |
If NULL, predictions are made using the data in model_output. If this is a SpatRaster, predictions will be made over this data. Default NULL. |
predict_iid |
If TRUE, any polygon iid effect from the model will be used in the prediction. Default FALSE. |
newdata |
Deprecated. |
Function returns rasters of the mean predictions as well as the covariate and field contributions to the linear predictor.
To predict over a different spatial extent to that used in the model, a SpatRaster covering the region to make predictions over is passed to the argument new_data. If this is not given predictions are made over the data used in the fit.
The predict_iid logical flag should be set to TRUE if the results of the iid effect from the model are to be used in the prediction.
The mean prediction, which is a list of:
prediction Raster of mean predictions based.
field Raster of the field component of the linear predictor.
iid Raster of the iid component of the linear predictor.
covariates Raster of the covariate component of the linear predictor.
## Not run:
predict_model(result)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.