Title: | Download Forestry Data |
---|---|
Description: | Functions for downloading forestry and land use data for use in spatial analysis. This packages offers a user-friendly solution to quickly obtain datasets such as forest height, forest types, tree species under various climate change scenarios, or land use data among others. |
Authors: | Adrián Cidre González [aut, cre] |
Maintainer: | Adrián Cidre González <[email protected]> |
License: | GPL (>= 3) |
Version: | 0.2.1 |
Built: | 2024-11-25 20:24:09 UTC |
Source: | https://github.com/cidree/forestdata |
Downloads the TALLO database, a global tree allometry and crown architecture database. Over 500,000 data points of individual trees with several measurements
fd_allometry_tallo( country = NULL, spatial = FALSE, metadata_path = NULL, quiet = FALSE )
fd_allometry_tallo( country = NULL, spatial = FALSE, metadata_path = NULL, quiet = FALSE )
country |
a character vector with either ISO2 codes, ISO3 codes or full country names (not mixed) to filter out the data |
spatial |
logical. Whether to retrieve a |
metadata_path |
a character string of length 1 with the path to store the
metadata and bibliography. The default |
quiet |
if |
a tibble
or a sf
object
Tallo: A global tree allometry and crown architecture database. doi:10.1111/gcb.16302
## Download full database as tibble tallo_tbl <- fd_allometry_tallo() ## Download full database as sf tallo_sf <- fd_allometry_tallo(spatial = TRUE) ## Download data as sf for Czechia and Germany tallo_cz_ge_sf <- fd_allometry_tallo(country = c("Czechia", "Germany"))
## Download full database as tibble tallo_tbl <- fd_allometry_tallo() ## Download full database as sf tallo_sf <- fd_allometry_tallo(spatial = TRUE) ## Download data as sf for Czechia and Germany tallo_cz_ge_sf <- fd_allometry_tallo(country = c("Czechia", "Germany"))
Download the ETH Global Sentinel-2 10m Canopy Height (2020) or the Meta High Resolution 1m Global Canopy Height Map
fd_canopy_height( x = NULL, lon = NULL, lat = NULL, model = "eth", layer = "chm", crop = FALSE, mask = FALSE, quiet = FALSE )
fd_canopy_height( x = NULL, lon = NULL, lat = NULL, model = "eth", layer = "chm", crop = FALSE, mask = FALSE, quiet = FALSE )
x |
a |
lon |
a number specifying the longitude of the area where we want the tile |
lat |
a number specifying the latitude of the area where we want the tile |
model |
a string specifying the model to download. One of " |
layer |
a string for the layer to download (valid only for eth). The default " |
crop |
when |
mask |
when |
quiet |
if |
There are currently two global canopy height models available within this function.
eth: the ETH Global Sentinel-2 10m Canopy Height from the year 2020. Visit https://www.research-collection.ethz.ch/handle/20.500.11850/609802 for more information
meta: the Meta High Resolution 1m Global Canopy Height. Visit doi:10.1016/j.rse.2023.113888 for more information
Data may be freely used for research, study, or teaching, but be cited appropriately (see references below).
A SpatRaster
Lang, Nico, Walter Jetz, Konrad Schindler, and Jan Dirk Wegner. "A high-resolution canopy height model of the Earth." arXiv preprint arXiv:2204.08322 (2022).
Tolan, J., Yang, H.I., Nosarzewski, B., Couairon, G., Vo, H.V., Brandt, J., Spore, J., Majumdar, S., Haziza, D., Vamaraju, J. and Moutakanni, T., 2024. Very high resolution canopy height maps from RGB imagery using self-supervised vision transformer and convolutional decoder trained on aerial lidar. Remote Sensing of Environment, 300, p.113888.
## Get 10m resolution CHM eth_model <- fd_canopy_height(lon = -7.27, lat = 42.43) ## Get 1m resolution CHM meta_model <- fd_canopy_height(lon = -7.27, lat = 42.43, model = "meta")
## Get 10m resolution CHM eth_model <- fd_canopy_height(lon = -7.27, lat = 42.43) ## Get 1m resolution CHM meta_model <- fd_canopy_height(lon = -7.27, lat = 42.43, model = "meta")
Download the Chorological Maps for the main European Woody Species.
fd_forest_chorological(species, range = "nat", quiet = FALSE)
fd_forest_chorological(species, range = "nat", quiet = FALSE)
species |
a character vector with the Latin name of a tree species contained in the Chorological Maps database (see details) |
range |
the default " |
quiet |
if |
Data may be freely used for research, study, or teaching, but be cited appropriately (see references below).
The chorological maps provide a general overview of the distribution of the main European woody species. The geodatabase was formed by the combination of numerous and heterogeneous data for a continental-scale overview of the species' distribution range. There are a total of 4 versions available, and the function will get the most recent version for each of the species. This means for instance that some species may be on version 2, and therefore, the data from that version will be retrieved.
sf
object
Caudullo, G., Welk, E., San-Miguel-Ayanz, J., 2017. Chorological maps for the main European woody species. Data in Brief 12, 666. DOI: doi.org/10.1016/j.dib.2017.05.007
metadata_forestdata for a list of possible species
# Download data for sweet chestnut chestnut_nat_sf <- fd_forest_chorological(species = "Castanea sativa", range = "nat") # Plot the data plot(chestnut_nat_sf$geometry)
# Download data for sweet chestnut chestnut_nat_sf <- fd_forest_chorological(species = "Castanea sativa", range = "nat") # Plot the data plot(chestnut_nat_sf$geometry)
Download data for tree species distribution in Europe for current (2005) distribution, and future distribution (2035, 2065, 2095).
fd_forest_eutrees4f( species, model = "clim", period = "all", scenario = "rcp45", type = "bin", distrib = "pot", quiet = FALSE )
fd_forest_eutrees4f( species, model = "clim", period = "all", scenario = "rcp45", type = "bin", distrib = "pot", quiet = FALSE )
species |
a character vector of length 1 with the Latin name of the tree species (genus and species) |
model |
a character vector of length 1 with the name of the ensemble projection. One of 'clim' or 'sdms' (see details) |
period |
a numeric or character vector of length 1 with the center of the 30-year time period used for the model. One of '2005', '2035', '2065', '2095', or 'all' (see details) |
scenario |
a character vector of length 1 with the climate change scenario used. One of 'rcp45' or 'rcp85' (see details) |
type |
a character vector of length 1 with the type of output layer. One of 'bin', 'prob' or 'std' (see details) |
distrib |
a character vector of length 1 with the type of distribution. One of 'nat', 'pot', 'disp' or 'disp_lu' (see details) |
quiet |
if |
Data may be freely used for research, study, or teaching, but be cited appropriately (see references below).
The data of EU-Trees4F database represent the distribution of the main woody species in Europe at 5 arc-minutes (~ 10 km) spatial resolution, in the Lambert Azimuthal Equal Area (EPSG:3035) CRS. The possible models to download are the following:
Model: type of model used
clim: climatic ensemble. A ensemble mean model that projects a consensus model
from biomod2
into future conditions using the average of 11 Regional
Climate Models (RCM).
sdms: Species Distribution Model (SDM) ensemble. A model that projects the consensus model for every single RCM, and then it averages the output of then 11 SDMs.
Period: 30-year time period
2005: for current projections. This option ignores the scenario argument.
They are not available for model = 'sdms'
with type = 'std'
.
2035: average of 2020-2050
2065: average of 2050-2080
2095: average of 2080-2110
all: get the four periods (or three for std type). Note that for some species or configurations this might fail, because the raster extent might not match in different periods
Scenario: climate change scenario
rcp45: a climate change scenario that assumes moderate emissions reductions
rcp85: a climate change scenario with high greenhouse gas emissions and limited mitigation efforts
Type: type of output layer
bin: binary distribution map, where 1 represents presence of the tree species, while 0 represents absence of the tree species, derived from the prob map
prob: probability distribution map (0-1000). Represents the probability of being the potential distribution of the species
std: standard deviation of prob map. Only available for model = 'sdms'
.
Distrib: type of species distribution
nat: realized distribution (masked with native range). Only available
with type = 'bin'
pot: potential distribution
disp: natural dispersal model (migclim). Only available
with type = 'bin'
disp_lu: natural dispersal model clipped by forest areas. Only available
with type = 'bin'
A single-band or multi-band SpatRaster
Mauri, Achille; Cescatti, Alessandro; GIRARDELLO, MARCO; Strona, Giovanni; Beck, Pieter; Caudullo, Giovanni; et al. (2022). EU-Trees4F. A dataset on the future distribution of European tree species.. figshare. Collection. https://doi.org/10.6084/m9.figshare.c.5525688.v2
metadata_forestdata for a list of possible species
# Download data for Betula pendula betula_pendula_sr <- fd_forest_eutrees4f(species = "Betula pendula")
# Download data for Betula pendula betula_pendula_sr <- fd_forest_eutrees4f(species = "Betula pendula")
This function is deprecated in favour of fd_forest_glad. Download the Forest Extent raster from the Global Land Analysis & Discovery by using a vectorial object or a pair of coordinates (latitude, longitude).
fd_forest_extent_glad( x = NULL, lon = NULL, lat = NULL, year = 2020, crop = FALSE, quiet = FALSE, ... )
fd_forest_extent_glad( x = NULL, lon = NULL, lat = NULL, year = 2020, crop = FALSE, quiet = FALSE, ... )
x |
a |
lon |
a number specifying the longitude of the area where we want the tile |
lat |
a number specifying the latitude of the area where we want the tile |
year |
year of the forest extent data. One of 2000, 2020 or 'all' |
crop |
when |
quiet |
if |
... |
additional arguments passed to the crop function |
The Forest Extent Map is a product offered by the Global Land Analysis & Discovery organization. The spatial resolution of the product is 0.00025º (approximately 30 meters at the Equator), and it's distributed in tiles of 10ºx10º. Pixels with forest height > 5 meters are classified as the forest class.
Note that each tile is stored as a raster file of 1.5 GB, so for big extensions the function might take some time to retrieve the data.
SpatRaster
object
Potapov P., Hansen M.C., Pickens A., Hernandez-Serna A., Tyukavina A., Turubanova S., Zalles V., Li X., Khan A., Stolle F., Harris N., Song X.-P., Baggett A., Kommareddy I., Kommareddy A. (2022) The global 2000-2020 land cover and land use change dataset derived from the Landsat archive: first results. Frontiers in Remote Sensing doi:10.3389/frsen.2022.856903
# Get tile for Galicia (Spain) galicia_forest_extent <- fd_forest_extent_glad(lon = -7.8, lat = 42.7, year = 2020)
# Get tile for Galicia (Spain) galicia_forest_extent <- fd_forest_extent_glad(lon = -7.8, lat = 42.7, year = 2020)
Download the BD Forêt data for a French Department. This function downloads the polygons of forest vegetation in France.
fd_forest_france(department, path_metadata = NULL, version = 2, quiet = FALSE)
fd_forest_france(department, path_metadata = NULL, version = 2, quiet = FALSE)
department |
a character string of length 1 with the name of a French department (see examples) |
path_metadata |
a character string of length 1 with the path to store
the metadata of the BD Forêt database. The default |
version |
the version number of the BD Forêt data. Either 1 or 2 (see details) |
quiet |
if |
The BD Forêt is a database where the forest cover of France is stored by department, with the spatial distribution of tree species in the country.
The BD Forêt version 1 was developed by photointerpretation of infrared color aerial images with a minimum mapped area of 2.25 hectares. The year of reference for each department varies between 1987 and 2002. The version 1 contains the following variables:
ID: surface object identifier
CODE_TFV: alphanumeric code of the vegetation formation
TFV: vegetation formation type
TFV_G11: type of coverage and predominant composition of the vegetation in 11 groups
ESSENCE: description of tree species according to the unique basic nomenclature for all departments
The BD Forêt version 2 was developed between 2007 and 2018 by photointerpretation
of color infrared images from the BD ORTHO. It assigns a vegetation formation
type to each mapped area larger than 5,000. This version contains the variables:
DEP: department name
CYCLE: order number of the departmental revision
ANREF: year of reference of the data
TFIFN: code of the departalmental type of vegetation cover. The nomenclature is specific to each department
LIBELLE: departamental type of vegetation cover. The nomenclature is specific to each department
LIBELLE2: departamental type of vegetation cover in capital letters. The nomenclature is specific to each department
TYPN: code of the national type of vegetation cover
NOMB_TYPN: national type of vegetation cover
For more information, download the metadata using the argument
path_metadata
(information in French).
A sf
object with POLYGON
geometry
https://geoservices.ign.fr/bdforet
metadata_forestdata for a list of possible Department names
# Download BD Foret V2 for the department of Ardèche ardeche_bdforet1_sf <- fd_forest_france(department = "Ardeche", version = 1)
# Download BD Foret V2 for the department of Ardèche ardeche_bdforet1_sf <- fd_forest_france(department = "Ardeche", version = 1)
Download data from GLAD database including forest extent, forest height, and land cover at ~30m spatial resolution
fd_forest_glad( x = NULL, lon = NULL, lat = NULL, model = "extent", year = 2020, crop = FALSE, mask = FALSE, quiet = FALSE )
fd_forest_glad( x = NULL, lon = NULL, lat = NULL, model = "extent", year = 2020, crop = FALSE, mask = FALSE, quiet = FALSE )
x |
a |
lon |
a number specifying the longitude of the area where we want the tile |
lat |
a number specifying the latitude of the area where we want the tile |
model |
a character vector of length 1 indicating the model to retrieve (see details) |
year |
year of the data (see details) |
crop |
when |
mask |
when |
quiet |
if |
The Global Land Analysis & Discovery (GLAD) includes several datasets which
can be accessed through the model
argument:
landcover: global land cover and land use dataset. Dataset divided into 10ºx10º tiles containing measures of bare ground and tree height inside and outside of wetlands, seasonal water percent, binary labels of built-up, permanent ice/snow, and cropland. Available for the years 2000, 2005, 2010, 2015, and 2020.
landcover-change: changes of landcover from 2000 to 2020. Argument
year
is ignored.
extent: dataset showing presence of forest, defined as wildland, managed, and planted tree cover including agroforestry and orchards. Includes areas where the vegetation is taller than 5 meters. Available for the years 2000 and 2020.
height: dataset measuring the height of woody vegetation taller than 3 meters. Available for the years 2000 and 2020.
The spatial resolution of the product is 0.00025º (approximately 30 meters at the Equator), and it's distributed in tiles of 10ºx10º.
Note that each tile is stored as a raster file of 1.5 GB, so for big extensions the function might take some time to retrieve the data.
SpatRaster
object
Potapov P., Hansen M.C., Pickens A., Hernandez-Serna A., Tyukavina A., Turubanova S., Zalles V., Li X., Khan A., Stolle F., Harris N., Song X.-P., Baggett A., Kommareddy I., Kommareddy A. (2022) The global 2000-2020 land cover and land use change dataset derived from the Landsat archive: first results. Frontiers in Remote Sensing doi:10.3389/frsen.2022.856903
P. Potapov, X. Li, A. Hernandez-Serna, A. Tyukavina, M.C. Hansen, A. Kommareddy, A. Pickens, S. Turubanova, H. Tang, C.E. Silva, J. Armston, R. Dubayah, J. B. Blair, M. Hofton (2020) Mapping and monitoring global forest canopy height through integration of GEDI and Landsat data. Remote Sensing of Environment, 112165.doi:10.1016/j.rse.2020.112165
# Get tile for Galicia (Spain) galicia_forest_extent <- fd_forest_glad(lon = -7.8, lat = 42.7, year = 2020)
# Get tile for Galicia (Spain) galicia_forest_extent <- fd_forest_glad(lon = -7.8, lat = 42.7, year = 2020)
Download the MFE50 (Spanish Forestry Map 1:50,000) for a province. The MFE50 was built during 1997-2006.
fd_forest_spain_mfe50(province, path_metadata = NULL, quiet = FALSE)
fd_forest_spain_mfe50(province, path_metadata = NULL, quiet = FALSE)
province |
a character string of length 1 with the name of a Spanish province |
path_metadata |
a character string of length 1 with the path to store the
metadata of the MFE50. The default |
quiet |
if |
The Spanish Forestry Map at scale 1:50,000 is a project that was undertaken
during the years 1997-2006. The data contains the cartography of forest
stands in Spain. The definition of the variables is contained in an excel
file that can be downloaded by using the argument path_metadata
.
A sf
object with POLYGON
geometry
metadata_forestdata for a list of possible species
# Download MFE50 for the province of Lugo lugo_mfe50_sf <- fd_forest_spain_mfe50(province = "Lugo")
# Download MFE50 for the province of Lugo lugo_mfe50_sf <- fd_forest_spain_mfe50(province = "Lugo")
Download the tables and SIG data from the Spanish Forest Inventory
fd_inventory_spain( province, ifn = 4, database = "field", path_metadata = NULL, quiet = FALSE )
fd_inventory_spain( province, ifn = 4, database = "field", path_metadata = NULL, quiet = FALSE )
province |
a character string of length 1 with the name of a Spanish province |
ifn |
number of Spanish Forest Inventory (from 2 to 4) |
database |
the name of the database (either 'field' or 'gis') |
path_metadata |
a character string of length 1 with the path to store the
metadata of the selected database. The default |
quiet |
if |
The IFN2 doesn't have 'gis' data for Asturias, Cantabria and Navarra.
In the future a function to process the data will be added.
A list
with the tables
metadata_forestdata for a list of possible species
# Download MFE50 for Canary Islands canarias_ifn4_lst <- fd_inventory_spain("Canarias") cantabria_ifn3_gis_lst <- fd_inventory_spain("cantabria", ifn = 3, database = "gis")
# Download MFE50 for Canary Islands canarias_ifn4_lst <- fd_inventory_spain("Canarias") cantabria_ifn3_gis_lst <- fd_inventory_spain("cantabria", ifn = 3, database = "gis")
Download a SpatRaster
from the Global Land Cover from the Copernicus Global
Land Service.
fd_landcover_copernicus( x, lon = NULL, lat = NULL, year = 2019, layer = "forest", crop = FALSE, ... )
fd_landcover_copernicus( x, lon = NULL, lat = NULL, year = 2019, layer = "forest", crop = FALSE, ... )
x |
an |
lon |
a number specifying the longitude of the area where we want the tile |
lat |
a number specifying the latitude of the area where we want the tile |
year |
year of the land cover data. One of 2015:2019 or 'all' |
layer |
a character vector of the layer(s) to use from the Global Land Cover. See details |
crop |
when |
... |
additional arguments passed to the crop function |
There are 14 different layers that can be downloaded:
"discrete": land cover discrete classification
"classification": land cover classification probability
"bare": cover fraction of bare and sparse vegetation
"builtup": cover fraction of builtup
"crops": cover fraction of cropland
"tree": cover fraction of forest
"grass": cover fraction of herbaceous vegetation
"mosslichen": cover fraction of moss and lichen
"seasonalwater": cover fraction of seasonal inland water
"shrub": cover fraction of shrubland
"snow": cover fraction of snow and ice
"permanentwater": cover fraction of permanent inland water
"forest" (default): forest types. (0): unknown; (1): evergreen needle leaf forest; (2): evergreen broad leaf forest; (3): deciduous needle leaf; (4): deciduous broad leaf; (5): mix of forest types
"datadensityindicator": input data density
SpatRaster
object
Buchhorn, M.; Smets, B.; Bertels, L.; De Roo, B.; Lesiv, M.; Tsendbazar, N. - E.; Herold, M.; Fritz, S. Copernicus Global Land Service: Land Cover 100m: collection 3: epoch 2019: Globe 2020. DOI 10.5281/zenodo.3939050
# Get tile for Galicia (Spain) and year 2019 galicia_forest_extent <- fd_landcover_copernicus( lat = 42.7, lon = -7.8, year = 2019 ) # Get forest and discrete classification tiles for all years galicia_forest_extent <- fd_landcover_copernicus( lat = 42.7, lon = -7.8, year = "all", layer = c("forest", "discrete") )
# Get tile for Galicia (Spain) and year 2019 galicia_forest_extent <- fd_landcover_copernicus( lat = 42.7, lon = -7.8, year = 2019 ) # Get forest and discrete classification tiles for all years galicia_forest_extent <- fd_landcover_copernicus( lat = 42.7, lon = -7.8, year = "all", layer = c("forest", "discrete") )
Download an UTM tile of the ESRI Land Cover Explorer for a specified year
fd_landcover_esri(utm_code, year, quiet = TRUE)
fd_landcover_esri(utm_code, year, quiet = TRUE)
utm_code |
a character string of length 1 with an UTM code (e.g. "29N") |
year |
an integer or vector of integers corresponding to the base year
of the land cover tile. The option |
quiet |
if |
A SpatRaster
https://livingatlas.arcgis.com/en/home/
# Download Land Cover for UTM tile 29N year 2023 lc <- fd_landcover_esri("29N", year = 2023) # Download Land Cover for UTM time 29N for all years lc <- fd_landcover_esri("29N", year = "all")
# Download Land Cover for UTM tile 29N year 2023 lc <- fd_landcover_esri("29N", year = 2023) # Download Land Cover for UTM time 29N for all years lc <- fd_landcover_esri("29N", year = "all")
Download the Database of European Forest Insect and Disease Disturbances.
fd_pathogens_defid2( agent = "all", host = "all", symptoms = "all", country = "all", geometry = "polygon", quiet = TRUE )
fd_pathogens_defid2( agent = "all", host = "all", symptoms = "all", country = "all", geometry = "polygon", quiet = TRUE )
agent |
a character vector with the desired forest insect(s) and/or
disease(s). The default ' |
host |
a character vector with the desired host tree(s) species. The
default ' |
symptoms |
a character vector with the desired symptom(s). The default
' |
country |
a character vector with the desired country(ies). The default
' |
geometry |
a string with ' |
quiet |
if |
Data may be freely used for research, study, or teaching, but be cited appropriately (see references below).
This function will download the DEFID2 database to the temporary directory once per session. After it's downloaded, the queries to the database are faster than the first time.
Note that 99.6% of the observations correspond to Picea abies. Also, 99.3% of the observations are in Czechia.
The data comprises over 650,000 georeferenced records, which can be retrieved as points or polygons, representing insects and diseases that occurred between 1963 and 2021 in European Forests.
Please, cite the data with the reference below.
sf
object with MULTIPOLYGON
or POINT
geometry
Forzieri G, Dutrieux LP, Elia A, Eckhardt B, Caudullo G, Taboada FÁ, Andriolo A, Bălacenoiu F, Bastos A, Buzatu A, Castedo Dorado F, Dobrovolný L, Duduman M, Fernandez-Carillo A, Hernández-Clemente R, Hornero A, Ionuț S, Lombardero MJ, Junttila S, Lukeš P, Marianelli L, Mas H, Mlčoušek M, Mugnai F, Nețoiu C, Nikolov C, Olenici N, Olsson P, Paoli F, Paraschiv M, Patočka Z, Pérez-Laorga E, Quero JL, Rüetschi M, Stroheker S, Nardi D, Ferenčík J, Battisti A, Hartmann H, Nistor C, Cescatti A, Beck PSA (2023). The Database of European Forest Insect and Disease Disturbances: DEFID2. Global Change Biology
# Get the entire database (takes some seconds/minutes) defid2_sf <- fd_pathogens_defid2() # Get data for Spain and Portugal defid2_iberia_sf <- fd_pathogens_defid2(country = c("Spain", "Portugal"))
# Get the entire database (takes some seconds/minutes) defid2_sf <- fd_pathogens_defid2() # Get data for Spain and Portugal defid2_iberia_sf <- fd_pathogens_defid2(country = c("Spain", "Portugal"))
forestdata
functionsA list
with the names of tree species or regions depending on the
dataset.
metadata_forestdata
metadata_forestdata
A list of 7 elements:
Latin name of tree species for fd_forest_chorological
Latin name of tree species for fd_forest_eutrees4f
Departments of France for fd_forest_france
Province names for fd_forest_spain_mfe50
Province names for fd_inventory_spain