View source: R/fnc_create_IDs.R
fnc_create_IDs | R Documentation |
This function creates a regular pattern of modelling points for a given test area and a given resolution.
fnc_create_IDs(
poly,
res = 50,
ID_pre = "ID_",
out_dir = NA,
out_name = "IDs",
tranches = NA,
reduce_to_forest = T,
with_clim_meta = T
)
poly |
polygon of the test area in EPSG:32632 as full path with file name and ending. Accepts all files that can be read with |
res |
resolution in m |
ID_pre |
optional, prefix for ID_custom-name as character. Default is |
out_dir |
directory where df.ids shall be stored as |
out_name |
optional, name for ID-files, default is |
reduce_to_forest |
exclude points that do not lie in forests. Will speed up all following steps like creating soils and parameter sets. Default is |
with_clim_meta |
whether the columns |
add_tranches |
when large areas are modelled with a high resolution, it can be useful to model your area as tranches similar to a SUDOKU-field. This way you can calculate the results tranche by tranche and in a 9th of the total computing time you get a result covering the whole modelling area. In this case the IDs are assigned to a number of tranches set by |
returns a list of points with ID_custom (optional), x- and y- coordinates
df.ids <- fnc_create_IDs(poly = "H:/FVA-Projekte/P01540_WHHKW/Daten/Urdaten/GIS/metadaten/Freiburg_Wald.shp",
res = 100,
ID_pre = "ID_",
out_dir = NA,
out_name = "IDs",
tranches = 16)
sf.ids <- sf::st_as_sf(df.ids,
coords = c("easting", "northing"),
crs = 32632)
ggplot(sf.ids)+
geom_sf(aes(color = factor(Tranche)))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.