make_grid | R Documentation |
Make a grid over a study area.
make_grid(an_area = NULL, var_names = NULL, new_name = NULL, dir_path = NULL)
an_area |
A |
var_names |
A list of variable names to keep on cells. It try to match each variable name (ignoring case and partially matched) in the study area. Variables are calculated using the average of features (polygons or lines) coverage by each cell. |
new_name |
A name to new area study after make a grid over area. |
centroid |
A boolean indicating if x_centroid and y_centroid variables must be computed and appended |
A SDM_area
object with cells covering the study area. The dataframe contains the variables
matched and computed acoording to each cell.
## Not run: SPDF <- readOGR( system.file("vect_files/brasil_uf.gpkg", package="sdmTools"), layer = "brasil_uf", verbose = F ) SLDF <- readOGR( system.file("vect_files/hydro_uper_prpy.gpkg", package="sdmTools"), layer = "hydro_uper_prpy", verbose = F gridded_area <- SPDF %>% sdm_area("Test area", "EPSG:6933", c(50000, 50000)) %>% make_grid(var_names = list(), new_name = T) plot(gridded_area) gridded_area <- SLDF %>% sdm_area("Test area", "EPSG:6933", c(10000, 10000)) %>% make_grid(var_names = list("Length", "xxx", "Main_ri")) plot(gridded_area) ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.