View source: R/1.1b.f.occ.thin.R
| env_thin_b | R Documentation | 
The function thins spatial points to minimize biases in the environmental space. It divides de range of variables into a desired number of @param bins and selects points closer to the bin center.
env_thin_b(
  p.lst,
  predictors.lst,
  long.col = NULL,
  lat.col = NULL,
  bins = 20,
  plot = F,
  verbose = F
)
p.lst | 
 List of two column matrix or data.frame with point coordinates
or   | 
predictors.lst | 
 A   | 
lat.col, long.col | 
 Name of columns that contain coordinates (latitude and longitude)  | 
bins | 
 Number of bins to divide each environmental variable.  | 
plot | 
 Logical. Should results be plotted?  | 
verbose | 
 Logical. Should information be printed on screen?  | 
A data.frame, matrix, sp or sf object containing the selected records.
env_thin, load_env_thin_occ
## Not run: 
file <- paste(system.file(package="dismo"), "/ex/bradypus.csv", sep="")
bradypus <- read.table(file, header=TRUE, sep=',')
coord <- bradypus [,2:3]
# Download data for present
dir.create("rasters")
predictors <- getData('worldclim', var='bio', res=10, path="rasters")
#cor(data)
#vars <- ENMwizard::select_vars(cutoff = 0.9, corr.mat = cor(data), names.only = T)[[1]]
#length(vars)
env_thin_b(list(coord), list(predictors))
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.