View source: R/1.2b.f.sel.env.R
select_vars_b | R Documentation |
This function is a wrapper for ENMwizard::env.sel. See ?ENMwizard::env.sel for details It works with a named list of environmental variables (raster brick/stack). It creates a correlation matrix for the layers of a raster brick/stack for each species (item in the list) and returns a brick containing the least correlated variables below the cutoff value.
select_vars_b(
env.l,
cutoff = 0.9,
corr.mat.l = NULL,
sample.size = NULL,
names.only = F,
plot.dend = T,
rm.old = F,
filename = NULL
)
env.l |
List of raster brick/stack. |
cutoff |
A numeric value for the pair-wise absolute correlation cutoff. |
corr.mat.l |
List of correlation matrices from which variables will be selected. If the correlation matrix was already computed from env, you can just input here and choose other cutoff values for selecting variable layers. |
sample.size |
Numeric. Number of cells of each layer to be sampled and used for computing correlation. If NULL (default), all cells are used to compute correlation. between variables. |
names.only |
Logical. Return only the names of selected variables (T) or return the raster brick containing the least correlated variables (F). |
plot.dend |
Logical. Plot dendrogram of correlation distance between variables, showing cutoff limit and selected (black) and discarded (red) variables |
rm.old |
Logical. Remove (T) old env variables from folder? |
filename |
Output filename |
select_vars
, correlated
, findCorrelation
## Not run:
select_vars_b(occ.b.env, .9, names.only=T)
occ.b.env <- select_vars_b(occ.b.env, .9, names.only=F, rm.old=F)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.