predict_raster {tidysdm}R Documentation

Make predictions for a whole raster

Description

This function allows to use a raster as data to make predictions from a variety of tidymodels objects, such as simple_ensemble or stacks::stacks

Usage

predict_raster(object, raster, ...)

## Default S3 method:
predict_raster(object, raster, ...)

Arguments

object

the tidymodels object of interest

raster

the terra::SpatRaster with the input data. It has to include levels with the same names as the variables used in object

...

parameters to be passed to the standard predict() function for the appropriate object type (e.g. metric_thresh or class_thresh).

Value

a terra::SpatRaster with the predictions


[Package tidysdm version 0.9.5 Index]