Description Usage Arguments Value References Examples
This function computes species distribution models using
four modelling algorithms: generalized linear models,
generalized boosted models, random forests, and maximum entropy (only if
rJava
is available). Note: this is an experimental function, and
may change in the future.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 
x 
A dataframe containing the species occurrences and geographic coordinates. Column 1 labeled as "species", column 2 "lon", column 3 "lat". 
pol 
A polygon shapefile specifying the boundary to restrict the prediction. If not specified, a minimum convex polygon is estimated using the input data frame of species occurrences. 
predictors 
RasterStack of environmental descriptors on which the models will be projected 
blank 
A blank raster upon which the prediction layer is aggregated to. 
res 
Desired resolution of the predicted potential species distribution (if blank raster is not specified). 
tc 
Integer. Tree complexity. Sets the complexity of individual trees 
lr 
Learning rate. Sets the weight applied to individual trees 
bf 
Bag fraction. Sets the proportion of observations used in selecting variables 
n.trees 
Number of initial trees to fit. Set at 50 by default 
step.size 
Number of trees to add at each cycle 
k 
Number of groups 
herbarium.rm 
Logical, remove points within 50 km of herbaria. 
n_points 
Minimum number of points required to successfully run a species distribution model 
A list with the following objects:
ensemble_raster
The ensembled raster that predicts
the potential species distribution.
ensemble_AUC
The median AUCs of models.
data
The dataframe that was used to implement the model.
indiv_models
Raster layers for the separate models that
predict the potential species distribution.
single_AUCs
The AUCs for the seperate models.
Phillips, S.J., Anderson, R.P. & Schapire, R.E. (2006) Maximum entropy modeling of species geographic distributions. Ecological Modelling 190: 231259.
1 2 3 4 5 6 7 8 9 10 11  library(raster)
# get predictor variables
f < list.files(path=paste(system.file(package="phyloregion"), '/ex', sep=''),
pattern='.tif', full.names=TRUE )
preds < stack(f)
#plot(preds)
# get species occurrences
d < read.csv(system.file("ex/Bombax.csv", package="phyloregion"))
# fit ensemble model for four algorithms
mod < sdm(d, predictors = preds)

Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.