predict | R Documentation |
Make predictions with models defined in the predicts
package
## S4 method for signature 'MaxEnt_model'
predict(object, x, ext=NULL, args="", filename="", ...)
## S4 method for signature 'envelope_model'
predict(object, x, tails=NULL, ext=NULL, filename="", ...)
## S4 method for signature 'hull_model'
predict(object, x, ext=NULL, mask=FALSE, filename="", ...)
object |
model defined in this package (e.g. "envelope_model" and "maxent_model") |
x |
data to predict to. Either a data.frame or a SpatRaster |
tails |
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. |
args |
Pass *prediction* arguments (options) to the maxent software. See |
ext |
|
mask |
logical. If |
filename |
character. Output filename |
... |
additional arguments for writing files as in |
SpatRaster or vector (if x
is a data.frame).
predict
function in the "terra" package for spatial predictions with glm, randomForest, etc.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.