Package {datazoom.amazonia}


Title: Simplify Access to Data from the Amazon Region
Version: 1.2.0
Description: Provides tools for downloading and processing data on the Brazilian Amazon region from a variety of official sources. Covers environmental, agricultural, economic, and social indicators, including deforestation and land use, greenhouse gas emissions, climate, agricultural and livestock production, mining, energy, and foreign trade, from providers such as the Brazilian Institute of Geography and Statistics (IBGE), the National Institute for Space Research (INPE), and MapBiomas. Data are cleaned and standardized for analysis at the municipality, state, and regional levels.
License: MIT + file LICENSE
URL: https://datazoom.com.br/amazonia/en/, https://github.com/datazoompuc/datazoom.amazonia
Depends: R (≥ 4.1.0)
Imports: data.table, dplyr, googledrive, janitor, magrittr, openxlsx, purrr, readr, readxl, sf, sidrar, stringi, stringr, tibble, tidyr, tidyselect, utils, rlang
Suggests: knitr, rmarkdown, terra, units
VignetteBuilder: knitr
Encoding: UTF-8
LazyData: true
RoxygenNote: 7.3.3
BugReports: https://github.com/datazoompuc/datazoom.amazonia/issues
NeedsCompilation: no
Packaged: 2026-07-03 13:50:48 UTC; Ro
Author: Laura Tavares Regadas [aut, cre], DataZoom (PUC-Rio) [fnd], Gustavo Gonzaga [aut], Igor Rigolon Veiga [aut], Guilherme Jardim [aut], Daniel AC Barbosa [aut], Bruno Alcantara Duarte [aut], Fredie Didier [aut], Tito Bruni [aut], Luiz Guilherme Lopes Moussatche [aut], Victor Aliende da Matta [aut], Anna Carolina Dutra Saraiva [aut], Arthur Carvalho Brito [aut], Francisco de Lima Cavalcanti [aut], Maria Mittelbach [aut], Felipe de Moraes Nunes [aut], Joao Paulo Santos P. Barbosa [aut], Bernardo Furlanetto Sieira [aut]
Maintainer: Laura Tavares Regadas <lauratregadas@gmail.com>
Repository: CRAN
Date/Publication: 2026-07-03 21:50:08 UTC

Pipe operator

Description

See magrittr::%>% for details.

Usage

lhs %>% rhs

Arguments

lhs

A value or the magrittr placeholder.

rhs

A function call using the magrittr semantics.

Value

The result of calling rhs(lhs).


ANEEL

Description

National Electric Energy Agency - ANEEL

Usage

load_aneel(dataset, raw_data = FALSE, language = "eng", year = NULL)

Arguments

dataset

A dataset name ("energy_development_budget", "energy_generation" or "energy_enterprises_distributed")

raw_data

A boolean setting the return of raw (TRUE) or processed (FALSE) data.

language

A string that indicates in which language the data will be returned. Portuguese ("pt") and English ("eng") are supported.

year

A numeric value or vector of years (2017-2022). Required for the "energy_development_budget" dataset. Ignored for the other datasets.

Value

A data.frame: the raw source data when raw_data = TRUE, or a treated tibble when raw_data = FALSE.

Examples


### DO NOT RUN ###
# download treated data about energy generation
clean_aneel <- load_aneel(
  dataset = "energy_generation",
  raw_data = FALSE
)

# download raw annual CDE budget data
raw_cde <- load_aneel(
  dataset = "energy_development_budget",
  year = 2021,
  raw_data = TRUE
)


BACI - Global foreign trade

Description

Loads disaggregated data on bilateral trade flows for more than 5000 products and 200 countries.

Usage

load_baci(dataset = "HS92", raw_data = FALSE, time_period, language = "eng")

Arguments

dataset

A dataset name ("HS92").

raw_data

A boolean setting the return of raw (TRUE) or processed (FALSE) data.

time_period

A numeric indicating for which years the data will be loaded, in the format YYYY. Can be any vector of numbers, such as 2010:2012.

language

A string that indicates in which language the data will be returned. Portuguese ("pt") and English ("eng") are supported.

Value

A tibble.

Examples


### DO NOT RUN ###
# download treated trade data for 2016 (HS92 classification)
trade_2016 <- load_baci(
  dataset = "HS92",
  raw_data = FALSE,
  time_period = 2016,
  language = "eng"
)


Comex - Brazilian foreign trade

Description

Loads data on all products imported to or exported from Brazil.

Usage

load_br_trade(dataset, raw_data = FALSE, time_period, language = "eng")

Arguments

dataset

A dataset name ("export_mun", "import_mun", "export_prod" or "import_prod").

raw_data

A boolean setting the return of raw (TRUE) or processed (FALSE) data.

time_period

A numeric indicating for which years the data will be loaded, in the format YYYY. Can be any vector of numbers, such as 2010:2012.

language

A string that indicates in which language the data will be returned. Portuguese ("pt") and English ("eng") are supported.

Value

A tibble.

Examples


### DO NOT RUN ###
# download treated exports data by municipality from 2020 to 2021
data <- load_br_trade(
  dataset = "export_mun",
  raw_data = FALSE,
  time_period = 2020:2021,
  language = "eng"
)

# download treated imports data by municipality from 2020 to 2021
data <- load_br_trade(
  dataset = "import_mun",
  raw_data = FALSE,
  time_period = 2020:2021,
  language = "eng"
)


CEMPRE - Central Register of Companies

Description

Loads information on companies and other organizations and their respective formally constituted local units, registered with the CNPJ - National Register of Legal Entities.

Usage

load_cempre(
  dataset = "cempre",
  raw_data = FALSE,
  geo_level,
  time_period,
  language = "eng",
  sectors = FALSE
)

Arguments

dataset

A dataset name ("cempre").

raw_data

A boolean setting the return of raw (TRUE) or processed (FALSE) data.

geo_level

A string that defines the geographic level of the data. Can be one of "country", "state" or "municipality".

time_period

A numeric indicating for which years the data will be loaded, in the format YYYY. Can be any vector of numbers, such as 2010:2012.

language

A string that indicates in which language the data will be returned. Portuguese ("pt") and English ("eng") are supported.

sectors

A boolean that defines if the data will be return separated by sectors (TRUE) or not (FALSE).

Value

A tibble.

Examples


### DO NOT RUN ###
# download treated national-level data from 2008 to 2010
data <- load_cempre(
  raw_data = FALSE,
  geo_level = "country",
  time_period = 2008:2010,
  language = "eng"
)

# download treated state-level data split by sector
data <- load_cempre(
  raw_data = FALSE,
  geo_level = "state",
  time_period = 2008:2010,
  language = "pt",
  sectors = TRUE
)


Censo Agropecuario

Description

Loads information on agricultural establishments and activities

Usage

load_censoagro(
  dataset,
  raw_data = FALSE,
  geo_level,
  time_period,
  language = "eng"
)

Arguments

dataset

A dataset name ("agricultural_land_area", "agricultural_area_use", "agricultural_employees_tractors", "agricultural_producer_condition", "animal_species", "animal_products", "vegetable_production_area", "vegetable_production_permanent", "vegetable_production_temporary", "livestock_production").

raw_data

A boolean setting the return of raw (TRUE) or processed (FALSE) data.

geo_level

A string that defines the geographic level of the data. Can be of "country" or "state".

  • For dataset "livestock_production", can be one of "country", "state", or "municipality"

time_period

A numeric indicating for which years the data will be loaded, in the format YYYY. Can be any vector of numbers, such as 2010:2012.

language

A string that indicates in which language the data will be returned. Portuguese ("pt") and English ("eng") are supported.

Value

A tibble.

Examples


### DO NOT RUN ###
# download treated land area data at the country level in 2017
data <- load_censoagro(
  dataset = "agricultural_land_area",
  raw_data = FALSE,
  geo_level = "country",
  time_period = 2017,
  language = "eng"
)

# download treated temporary crop data by state in 1995
data <- load_censoagro(
  dataset = "vegetable_production_temporary",
  raw_data = FALSE,
  geo_level = "state",
  time_period = 1995,
  language = "pt"
)


TerraClimate - Climate monitoring

Description

Spatial data on climate variables, extracted from Climatology Lab's TerraClimate.

Usage

load_climate(
  dataset,
  raw_data = FALSE,
  time_period,
  language = "eng",
  legal_amazon_only = FALSE
)

Arguments

dataset

A dataset name, choosing which variable will be loaded. One of ("max_temperature", "min_temperature", "wind_speed", "vapor_pressure_deficit", "vapor_pressure", "snow_water_equivalent", "shortwave_radiation_flux", "soil_moisture", "runoff", "precipitation", "potential_evaporation", "climatic_water_deficit", "water_evaporation", "palmer_drought_severity_index"). For extra details, try vignette("TERRACLIMATE").

raw_data

A boolean setting the return of raw (TRUE) or processed (FALSE) data.

time_period

A numeric indicating for which years the data will be loaded, in the format YYYY. Can be any vector of numbers, such as 2010:2012.

language

A string that indicates in which language the data will be returned. Portuguese ("pt") and English ("eng") are supported.

legal_amazon_only

A boolean setting the return of Legal Amazon Data (TRUE) or Country's Data (FALSE). Defaults to FALSE

Value

An sf object with the selected climate data merged onto Brazilian municipalities.

Examples


### DO NOT RUN ###
# download maximum temperature data from 2000 to 2001
max_temp <- load_climate(
  dataset = "max_temperature",
  time_period = 2000:2001,
  language = "eng"
)

# download precipitation data only for the legal Amazon in 2010
amz_precip <- load_climate(
  dataset = "precipitation",
  time_period = 2010,
  legal_amazon_only = TRUE,
  language = "eng"
)


DATASUS - No longer available

Description

The load_datasus function is no longer part of the package. Updates on the matter coming soon. It is kept only for compatibility and will return a warning when called.

Usage

load_datasus(
  dataset = NULL,
  raw_data = NULL,
  time_period = NULL,
  language = "eng"
)

Arguments

dataset

Ignored. Kept only for compatibility.

raw_data

Ignored. Kept only for compatibility.

time_period

Ignored. Kept only for compatibility.

language

Ignored. Kept only for compatibility.

Value

NULL. Always returns empty.


Degrad - Forest Degradation in the Brazilian Amazon

Description

Loads information on forest degradation in the Brazilian Amazon, replaced by DETER-B in December 2016.

Usage

load_degrad(
  dataset = "degrad",
  raw_data = FALSE,
  time_period,
  language = "eng"
)

Arguments

dataset

A dataset name ("degrad").

raw_data

A boolean setting the return of raw (TRUE) or processed (FALSE) data.

time_period

A numeric indicating for which years the data will be loaded, in the format YYYY. Can be any vector of numbers, such as 2010:2012.

language

A string that indicates in which language the data will be returned. Portuguese ("pt") and English ("eng") are supported.

Value

A list of tibbles (if raw_data = TRUE) or a tibble (if raw_data = FALSE).

Examples


### DO NOT RUN ###
# download treated forest degradation data from 2010 to 2012
data <- load_degrad(
  dataset = "degrad",
  raw_data = FALSE,
  time_period = 2010:2012,
  language = "eng"
)


DETER - Forest Degradation in the Brazilian Amazon

Description

Loads data on changes in forest cover in the Legal Amazon and the Cerrado biome.

Usage

load_deter(dataset, raw_data = FALSE, language = "eng")

Arguments

dataset

A dataset name ("deter_amz", "deter_cerrado") with information about the Legal Amazon and Cerrado, respectively

raw_data

A boolean setting the return of raw (TRUE) or processed (FALSE) data.

language

A string that indicates in which language the data will be returned. Portuguese ("pt") and English ("eng") are supported.

Value

A sf object.

Examples


### DO NOT RUN ###
# download treated DETER Amazon data
deter_amz <- load_deter(
  dataset = "deter_amz",
  raw_data = FALSE,
  language = "eng"
)

# download treated DETER Cerrado data
deter_cerrado <- load_deter(
  dataset = "deter_cerrado",
  raw_data = FALSE,
  language = "eng"
)


EPE

Description

Electrical Energy Monthly Consumption per Class or Industrial Sector

Usage

load_epe(dataset, geo_level = "state", raw_data = FALSE, language = "eng")

Arguments

dataset

Dataset name: "consumer_energy_consumption", "industrial_energy_consumption", "national_energy_balance", or "energy_state_panel"

geo_level

Geographical level: "state" or "subsystem". Only applies to consumer or industrial datasets.

raw_data

A boolean setting the return of raw (TRUE) or processed (FALSE) data.

language

A string that indicates in which language the data will be returned. Portuguese ("pt") and English ("eng") are supported.

Value

A list of tibbles (if raw_data = TRUE) or a tibble (if raw_data = FALSE).

Examples


### DO NOT RUN ###
# download treated (raw_data = FALSE) data about
# consumer energy consumption (dataset = "consumer_energy_consumption")
# at the state level (geo_level = "state")
data <- load_epe(
  dataset = "consumer_energy_consumption",
  geo_level = "state",
  raw_data = FALSE
)
# download treated (raw_data = FALSE) data
# from the National Energy Balance (dataset = "national_energy_balance")
balance <- load_epe(
  dataset = "national_energy_balance",
  raw_data = FALSE
)


IBAMA - Brazilian Institute for the Environment and Renewable Natural Resources

Description

Loads information on environmental fines in the Amazon region

Usage

load_ibama(dataset, raw_data = FALSE, states = "all", language = "eng")

Arguments

dataset

A dataset name ("embargoed_areas", "distributed_fines", or "collected_fines")

raw_data

A boolean setting the return of raw (TRUE) or processed (FALSE) data.

states

A string specifying for which states to download the data. It is "all" by default, but can be a single state such as "AC" or any vector such as c("AC", "AM"). Does not apply to the "embargoed_areas" dataset.

language

A string that indicates in which language the data will be returned. Currently, only Portuguese ("pt") and English ("eng") are supported.

Value

A tibble.

Examples


### DO NOT RUN ###
# download treated embargoed areas data in english
data <- load_ibama(
  dataset = "embargoed_areas",
  raw_data = FALSE,
  language = "eng"
)

# download treated collected fines data from Bahia
data <- load_ibama(
  dataset = "collected_fines",
  raw_data = FALSE,
  states = "BA",
  language = "pt"
)


IEMA - Institute of Environment and Water Resources

Description

Loads information on electric energy access at the municipality level in the Amazon region

Usage

load_iema(dataset = "iema", raw_data = FALSE, language = "eng")

Arguments

dataset

A dataset name ("iema")

raw_data

A boolean setting the return of raw (TRUE) or processed (FALSE) data.

language

A string that indicates in which language the data will be returned. Portuguese ("pt") and English ("eng") are supported.

Value

A tibble.

Examples


### DO NOT RUN ###
# download treated IEMA energy access data
data <- load_iema(
  raw_data = FALSE,
  language = "eng"
)


IMAZON - Deforestation pressure by municipality

Description

Loads data categorizing each municipality by the level of deforestation pressure it faces

Usage

load_imazon(dataset = "imazon_shp", raw_data = FALSE, language = "eng")

Arguments

dataset

There is one dataset available ("imazon_shp")

raw_data

A boolean setting the return of raw (TRUE) or processed (FALSE) data.

language

A string that indicates in which language the data will be returned. Portuguese ("pt") and English ("eng") are supported.

Value

A tibble.

Examples


### DO NOT RUN ###
# download treated Imazon deforestation pressure data
data <- load_imazon(
  raw_data = FALSE,
  language = "eng"
)


IPS - Amazon Social Progress Index

Description

Loads information on the social and environmental performance of the Legal Amazon.

Usage

load_ips(
  dataset = "all",
  raw_data = FALSE,
  time_period = c(2014, 2018, 2021, 2023),
  language = "eng"
)

Arguments

dataset

A dataset name ("all", "life_quality", "sanit_habit", "violence", "educ", "communic", "mortality", or "deforest")

raw_data

A boolean setting the return of raw (TRUE) or processed (FALSE) data.

time_period

Year to download. Can be 2014, 2018, 2021, 2023, or a vector with some combination thereof

language

A string that indicates in which language the data will be returned. Portuguese ("pt") and English ("eng") are supported.

Value

A tibble.

Examples


### DO NOT RUN ###
# download raw IPS data from 2014
data <- load_ips(
  dataset = "all",
  raw_data = TRUE,
  time_period = 2014,
  language = "eng"
)

# download treated deforestation IPS data from 2018 in portuguese
data <- load_ips(
  dataset = "deforest",
  raw_data = FALSE,
  time_period = 2018,
  language = "pt"
)


MAPBIOMAS - The Annual Land Cover and Use Mapping Project in Brazil

Description

Loads information about land cover and use

Usage

load_mapbiomas(
  dataset,
  raw_data = FALSE,
  geo_level = "municipality",
  language = "eng"
)

Arguments

dataset

A dataset name ("mapbiomas_cover", "mapbiomas_transition", "mapbiomas_irrigation", "mapbiomas_deforestation_regeneration", "mapbiomas_mining", "mapbiomas_water" or "mapbiomas_fire")

raw_data

A boolean setting the return of raw (TRUE) or processed (FALSE) data.

geo_level

A string that defines the geographic level of the data

  • For dataset "mapbiomas_cover", can only be "municipality"

  • For dataset "mapbiomas_transition", can be "municipality" or "biome" (faster download)

  • For dataset "mapbiomas_deforestation_regeneration", can only be "municipality"

  • For dataset "mapbiomas_mining", can be "indigenous_land" or "municipality"

  • For dataset "mapbiomas_irrigation" (temporarily unavailable, a new collection will be soon delivered), can be "state" or "biome"

  • For dataset "mapbiomas_water"(temporarily unavailable, a new collection will be soon delivered), can be "municipality", "state" or "biome"

  • For dataset "mapbiomas_fire", can only be "state"

language

A string that indicates in which language the data will be returned. Portuguese ("pt") and English ("eng") are supported.

Value

A tibble.

Examples


### DO NOT RUN ###
# download treated MapBiomas land cover data by municipality
data <- load_mapbiomas(
  dataset = "mapbiomas_cover",
  raw_data = FALSE,
  geo_level = "municipality",
  language = "eng"
)

# download treated data on mining on indigenous lands
data <- load_mapbiomas(
  dataset = "mapbiomas_mining",
  raw_data = FALSE,
  geo_level = "indigenous_land",
  language = "eng"
)


PAM - Municipal Agricultural Production

Description

Loads information on the quantity, value and area of temporary and permanent crops cultivated.

Usage

load_pam(dataset, raw_data = FALSE, geo_level, time_period, language = "eng")

Arguments

dataset

A dataset name ("all_crops", "permanent_crops", "temporary_crops" or many individual crop possibilities (see vignette(load_pam))). You can also use SIDRA codes (see https://sidra.ibge.gov.br/pesquisa/pam/tabelas)

raw_data

A boolean setting the return of raw (TRUE) or processed (FALSE) data.

geo_level

A string that defines the geographic level of the data. Can be one of "country", "state" or "municipality".

time_period

A numeric indicating for which years the data will be loaded, in the format YYYY. Can be any vector of numbers, such as 2010:2012.

language

A string that indicates in which language the data will be returned. Portuguese ("pt") and English ("eng") are supported.

Value

A tibble consisting of geographic units that present positive values for any of the variables in the dataset.

Examples


### DO NOT RUN ###
# download treated data at the state level from 2010 to 2011 for all crops
data <- load_pam(
  dataset = "all_crops",
  raw_data = FALSE,
  geo_level = "state",
  time_period = 2010:2011,
  language = "eng"
)


PEVS - Forestry Activities

Description

Loads information on the amount and value of the production of the exploitation of native plant resources and planted forest massifs, as well as existing total and harvested areas of forest crops.

Usage

load_pevs(dataset, raw_data = FALSE, geo_level, time_period, language = "eng")

Arguments

dataset

A dataset name ("pevs_forest_crops", "pevs_silviculture" or "pevs_silviculture_area"). You can also use SIDRA codes (see https://sidra.ibge.gov.br/pesquisa/pevs/quadros/brasil/2019)

raw_data

A boolean setting the return of raw (TRUE) or processed (FALSE) data.

geo_level

A string that defines the geographic level of the data. Can be one of "country", "region", "state", or "municipality".

time_period

A numeric indicating for which years the data will be loaded, in the format YYYY. Can be any vector of numbers, such as 2010:2012.

language

A string that indicates in which language the data will be returned. Portuguese ("pt") and English ("eng") are supported.

Value

A tibble consisting of geographic units that present positive values for any of the variables in the dataset.

Examples


### DO NOT RUN ###
# download treated silviculture data by state from 2012 in portuguese
data <- load_pevs(
  dataset = "pevs_silviculture",
  raw_data = FALSE,
  geo_level = "state",
  time_period = 2012,
  language = "pt"
)

# download raw forest crops data by region from 2012 to 2013
data <- load_pevs(
  dataset = "pevs_forest_crops",
  raw_data = TRUE,
  geo_level = "region",
  time_period = 2012:2013,
  language = "eng"
)


PIB MUNICIPAL - Municipal GDP

Description

Loads information on gross domestic product at current prices, taxes, net of subsidies, on products at current prices and gross value added at current prices, total and by economic activity, and respective shares.

Usage

load_pibmunic(
  dataset = "pibmunic",
  raw_data = FALSE,
  geo_level,
  time_period,
  language = "eng"
)

Arguments

dataset

A dataset name ("pibmunic") with Municipal GDP information. You can also use SIDRA codes (See https://sidra.ibge.gov.br/pesquisa/pib-munic/tabelas)

raw_data

A boolean setting the return of raw (TRUE) or processed (FALSE) data.

geo_level

A string that defines the geographic level of the data. Can be one of "country", "state" or "municipality".

time_period

A numeric indicating for which years the data will be loaded, in the format YYYY. Can be any vector of numbers, such as 2010:2012.

language

A string that indicates in which language the data will be returned. Portuguese ("pt") and English ("eng") are supported.

Value

A tibble.

Examples


### DO NOT RUN ###
# download treated municipal GDP data at the state level for 2010 to 2012
data <- load_pibmunic(
  raw_data = FALSE,
  geo_level = "state",
  time_period = 2010:2012,
  language = "eng"
)


Population

Description

Loads information on (estimated) population

Usage

load_population(
  dataset = "population",
  raw_data = FALSE,
  geo_level,
  time_period,
  language = "eng"
)

Arguments

dataset

A dataset name ("population").

raw_data

A boolean setting the return of raw (TRUE) or processed (FALSE) data.

geo_level

A string that defines the geographic level of the data. Can be one of "country", "state" or "municipality".

time_period

A numeric indicating for which years the data will be loaded, in the format YYYY. Can be any vector of numbers, such as 2010:2012.

language

A string that indicates in which language the data will be returned. Portuguese ("pt") and English ("eng") are supported.

Value

A tibble.

Examples


### DO NOT RUN ###
# download raw population data at the country level from 2008 to 2010
data <- load_population(
  raw_data = TRUE,
  geo_level = "country",
  time_period = 2008:2010,
  language = "eng"
)

# download treated population data by state from 2008 to 2010 in portuguese
data <- load_population(
  raw_data = FALSE,
  geo_level = "state",
  time_period = 2008:2010,
  language = "pt"
)


PPM - Municipal Livestock Production

Description

Loads information on animal farming inventories and livestock products (IBGE).

Usage

load_ppm(dataset, raw_data = FALSE, geo_level, time_period, language = "eng")

Arguments

dataset

A dataset name ("ppm_livestock_inventory", "ppm_sheep_farming", "ppm_animal_origin_production", "ppm_cow_farming" or "ppm_aquaculture". You can also use SIDRA codes (see https://sidra.ibge.gov.br/pesquisa/ppm/tabelas/brasil/2021)

raw_data

A boolean setting the return of raw (TRUE) or processed (FALSE) data.

geo_level

A string that defines the geographic level of the data. Can be one of "country", "state" or "municipality".

time_period

A numeric indicating for which years the data will be loaded, in the format YYYY. Can be any vector of numbers, such as 2010:2012.

language

A string that indicates in which language the data will be returned. Portuguese ("pt") and English ("eng") are supported.

Value

A tibble consisting of geographic units that present positive values for any of the variables in the dataset.

Examples


### DO NOT RUN ###
# download treated aquaculture data at the country level from 2013 to 2015
data <- load_ppm(
  dataset = "ppm_aquaculture",
  raw_data = FALSE,
  geo_level = "country",
  time_period = 2013:2015,
  language = "eng"
)

# download raw sheep farming data by state from 1980 to 1995 in portuguese
data <- load_ppm(
  dataset = "ppm_sheep_farming",
  raw_data = TRUE,
  geo_level = "state",
  time_period = 1980:1995,
  language = "pt"
)


PRODES - Deforestation Monitoring Project in the Legal Amazon by Satellite

Description

Loads data on deforestation in the Legal Amazon region.

Usage

load_prodes(
  dataset = "deforestation",
  raw_data = FALSE,
  time_period = 2023,
  language = "eng"
)

Arguments

dataset

A dataset name. Can be one of "deforestation", "residual_deforestation", "native_vegetation", "hydrography", "non_forest", or "clouds".

raw_data

A boolean setting the return of raw (TRUE) or processed (FALSE) data.

time_period

A numeric indicating for which years the data will be loaded, in the format YYYY. Can be any vector of numbers, such as 2010:2012.

  • Between 2007 - 2023 for dataset "deforestation". Deforestation for 2007 includes all cumulative deforestation up to 2007. For other years, deforestation is incremental

  • Between 2010 - 2023 for dataset "residual_deforestation"

  • Only 2023 for all other datasets

language

A string that indicates in which language the data will be returned. Portuguese ("pt") and English ("eng") are supported.

Value

A tibble with the selected data if raw_data is FALSE, and a SpatRaster is TRUE.

Examples


### DO NOT RUN ###
# download treated deforestation data for 2023
deforestation <- load_prodes(
  dataset = "deforestation",
  raw_data = FALSE,
  time_period = 2023,
  language = "eng"
)

# download treated deforestation data for 2008 to 2023
deforestation_series <- load_prodes(
  dataset = "deforestation",
  raw_data = FALSE,
  time_period = 2008:2023,
  language = "eng"
)

# download treated residual deforestation data for 2020
residual <- load_prodes(
  dataset = "residual_deforestation",
  raw_data = FALSE,
  time_period = 2020,
  language = "eng"
)


Greenhouse gas emission estimates (SEEG)

Description

Loads data of estimates of emission of greenhouse gases

Usage

load_seeg(dataset, raw_data = FALSE, geo_level, language = "eng")

Arguments

dataset

A dataset name ("seeg", seeg_farming", "seeg_industry", "seeg_energy", "seeg_land", "seeg_residuals"). On which "seeg" contains all five sectors (only works with raw_data = TRUE) and the others are filtered specifically by a main source of emission.

raw_data

A boolean setting the return of raw (TRUE) or processed (FALSE) data.

geo_level

A string that defines the geographic level of the data. Can be one of "country", "state" or "municipality".

language

A string that indicates in which language the data will be returned. Portuguese ("pt") and English ("eng") are supported.

Value

A tibble.

Examples


### DO NOT RUN ###
# download raw SEEG data (all sectors) at the country level
all_emissions <- load_seeg(
  dataset = "seeg",
  raw_data = TRUE,
  geo_level = "country",
  language = "eng"
)

# download treated agricultural emissions at the state level
farming <- load_seeg(
  dataset = "seeg_farming",
  raw_data = FALSE,
  geo_level = "state",
  language = "eng"
)

# download treated land use change emissions at the state level
land_use <- load_seeg(
  dataset = "seeg_land",
  raw_data = FALSE,
  geo_level = "state",
  language = "eng"
)

# download treated energy emissions at the municipality level
energy <- load_seeg(
  dataset = "seeg_energy",
  raw_data = FALSE,
  geo_level = "municipality",
  language = "eng"
)

# download treated industrial process emissions at the state level
industry <- load_seeg(
  dataset = "seeg_industry",
  raw_data = FALSE,
  geo_level = "state",
  language = "eng"
)

# download treated waste emissions at the state level
residuals <- load_seeg(
  dataset = "seeg_residuals",
  raw_data = FALSE,
  geo_level = "state",
  language = "eng"
)


SIGMINE - Mining Geographic Information System

Description

Loads information the mines being explored legally in Brazil, including their location, status, product being mined and area in square meters.

Usage

load_sigmine(dataset = "sigmine_active", raw_data = FALSE, language = "eng")

Arguments

dataset

A dataset name ("sigmine_active")

raw_data

A boolean setting the return of raw (TRUE) or processed (FALSE) data.

language

A string that indicates in which language the data will be returned. Portuguese ("pt") and English ("eng") are supported.

Value

A tibble.

Examples


### DO NOT RUN ###
# download treated active mining data in portuguese
mining_active <- load_sigmine(
  dataset = "sigmine_active",
  raw_data = FALSE,
  language = "pt"
)


IBGE codes and Legal Amazon identification of Brazilian municipalities

Description

A dataset containing each municipality's IBGE code, state, mesoregion, microregion, as well as a binary variable for whether it is part of the Legal Amazon. Mostly for our functions' internal use.

Usage

municipalities

Format

A data frame with 5570 rows and 12 variables:

code_muni

IBGE 7-digit municipality code

name_muni

municipality name

code_state

2-digit state code

abbrev_state

state abbreviations (e.g. "AM")

name_state

full name of the states

code_region

1-digit regional code

name_region

name of the region

legal_amazon

takes value 1 for municipalities in the legal amazon, 0 otherwise

municipality_mapbiomas

municipality name in MAPBIOMAS data

code_micro

5-digit microregion code

name_micro

name of the microregion

code_meso

4-digit mesoregion code

name_meso

name of the mesoregion

Source

Package geobr and https://www.ibge.gov.br/geociencias/cartas-e-mapas/mapas-regionais/15819-amazonia-legal.html?=&t=acesso-ao-produto


IBGE codes and MAPBIOMAS id of Brazilian municipalities and biomes

Description

A dataset containing each municipality-biome's IBGE code, state, biome, name and MAPBIOMAS ID. Mostly for our functions' internal use.

Usage

municipalities_biomes

Format

A data frame with 6537 rows and 5 variables:

feature_id

MAPBIOMAS biome-municipality ID

code_muni

IBGE 7-digit municipality code

abbrev_state

state abbreviations (e.g. "AM")

municipality_mapbiomas

municipality name in MAPBIOMAS data

biome

biome

Source

Package geobr and https://mapbiomas.org/