Make predictions with models defined in the predicts
package
# S4 method for MaxEnt_model
predict(object, x, ext=NULL, args="", filename="", ...)# S4 method for envelope_model
predict(object, x, tails=NULL, ext=NULL, filename="", ...)
# S4 method for hull_model
predict(object, x, ext=NULL, mask=FALSE, filename="", ...)
SpatRaster or vector (if x
is a data.frame).
model defined in this package (e.g. "envelope_model" and "maxent_model")
data to predict to. Either a data.frame or a SpatRaster
character. You can use this to ignore the left or right tail of the percentile distribution for a variable. If supplied, tails should be a character vector with a length equal to the number of variables used in the model. Valid values are "both" (the default), "low" and "high". For example, if you have a variable x with an observed distribution between 10 and 20 and you are predicting the bioclim value for a value of 25, the default result would be zero (outside of all observed values); but if you use tail='low', the high (right) tail is ignored and the value returned will be 1.
Pass *prediction* arguments (options) to the maxent software. See maxent
NULL
or a SpatExtent
to limit the prediction to a sub-region of x
logical. If TRUE
areas that are NA
in x
are set to NA
in the output
character. Output filename
additional arguments for writing files as in writeRaster
predict
function in the "terra" package for spatial predictions with glm, randomForest, etc.