Package 'mrcommons'

Title: MadRat commons Input Data Library
Description: Provides useful functions and a common structure to all the input data required to run models like MAgPIE and REMIND of model input data.
Authors: Benjamin Leon Bodirsky [aut], Kristine Karstens [aut], Lavinia Baumstark [aut], Isabelle Weindl [aut], Xiaoxi Wang [aut], Abhijeet Mishra [aut], Stephen Wirth [aut], Mishko Stevanovic [aut], Nele Steinmetz [aut], Ulrich Kreidenweis [aut], Renato Rodrigues [aut], Roman Popov [aut], Florian Humpenoeder [aut], Anastasis Giannousakis [aut], Antoine Levesque [aut], David Klein [aut], Ewerton Araujo [aut], Felicitas Beier [aut], Julian Oeser [aut], Michaja Pehl [aut], Debbora Leip [aut], Michael Crawford [aut], Edna Molina Bacca [aut], Patrick von Jeetze [aut], Eleonora Martinelli [aut], Felix Schreyer [aut], Bjoern Soergel [aut], Pascal Sauer [aut], David Hötten [aut], Robin Hasse [aut], Gabriel Abrahão [aut], Pascal Weigmann [aut], Jan Philipp Dietrich [aut, cre]
Maintainer: Jan Philipp Dietrich <[email protected]>
License: LGPL-3 | file LICENSE
Version: 1.46.10
Built: 2024-12-04 11:20:30 UTC
Source: https://github.com/pik-piam/mrcommons

Help Index


calc1stBioDem

Description

Calculates projections of first generation biofuels demand,including biogas, bioethamol and biodiesel, from IEA database. The unit is Petajoule.

Usage

calc1stBioDem(subtype = "all")

Arguments

subtype

all per default. ethanol_oils for selecting 1st gen crop types relevant for REMIND input.

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Xiaoxi Wang, David Klein

See Also

calc1stBioenergyPast()

Examples

## Not run: 
calcOutput("1stBioDem")

## End(Not run)

calc1stBioenergyPast

Description

Calculates first generation biofuels production, imports, exports for biogas, bioethanol and biodiesel from IEA database. The unit is Petajoule.

Usage

calc1stBioenergyPast()

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Xiaoxi Wang, Isabelle Weindl

Examples

## Not run: 
calcOutput("1stBioenergyPast")

## End(Not run)

calcACCMIP

Description

reads in the ACCMIP atmospheric deposition database. Speeds up caching

Usage

calcACCMIP(glo_incl_oceans = FALSE)

Arguments

glo_incl_oceans

if true, a global value will be returned that also includes deposition on oceans and should be equivalent to total emissions.

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

See Also

calcAtmosphericDeposition()

Examples

## Not run: 
calcOutput("ACCMIP")

## End(Not run)

calcAdjustGrassi2021

Description

Calculates the carbon emission adjustement factors as derived by Grassi et al. 2021 Adjustement factors are provided in GtCO2 yr-1. Positive and negative values possible.

Usage

calcAdjustGrassi2021()

Value

magpie object with emission adjustement factors weighted by country C removals 2000 to 2015.

Author(s)

Michael Windisch, Florian Humpenoeder

Examples

## Not run: 
calcOutput("AdjustGrassi2021")

## End(Not run)

calcAgProductionValue

Description

Calculate FAO Value Of Production

Usage

calcAgProductionValue(datasource = "FAO")

Arguments

datasource

Currently available: "FAO"

Value

FAO Value Of Production as a list of MAgPIE objects

Author(s)

Roman Popov, Mishko Stevanovic, Patrick v. Jeetze

See Also

calcOutput(), readFAO(), convertFAO(), readSource()

Examples

## Not run: 
a <- calcOutput("AgProductionValue", datasource = "FAO")

## End(Not run)

calcAnimalStocks

Description

calculates stocks of animals of different categories.

Usage

calcAnimalStocks(grouping = "IPCC")

Arguments

grouping

IPCC: Animal grouping of IPCC Guidelines

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

See Also

calcExcretionIPCC(), readIPCC()

Examples

## Not run: 
calcOutput("AnimalStocks")

## End(Not run)

calcAtmosphericDeposition

Description

Computes Atmospheric (nitrogen) deposition on different land-use types. It distinguishes ammonia (Nh3) and Nitrogen oxides (NOx) as well

Usage

calcAtmosphericDeposition(
  datasource = "ACCMIP",
  glo_incl_oceans = FALSE,
  cellular = FALSE,
  cells = "lpjcell",
  emission = FALSE,
  scenario = NULL
)

Arguments

datasource

deposition inventory

glo_incl_oceans

provides global values that include oceans, as oceans are not part of the country mapping

cellular

cellular or country level emissions

cells

magpiecell (59199 cells) or lpjcell (67420 cells)

emission

if TRUE, not the deposition but the cellular emissions are reported

scenario

if dataset contains several scenarios (e.g. ACCMIP), one scenario can be selected.

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

See Also

calcNitrogenBudgetCropland()

Examples

## Not run: 
calcOutput("AtmosphericDeposition")

## End(Not run)

calcAtmosphericRedepositionShare

Description

Calculates share of volatilised nitrogen emissions that is redeposited on different land types.

Usage

calcAtmosphericRedepositionShare(
  cellular = FALSE,
  maxshare = 0.8,
  scenario = "rcp45"
)

Arguments

cellular

cellular or country level

maxshare

the maximum amount of emissions deposited within the same cell or country. The remainder will be handled as global emission

scenario

scenario

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

Examples

## Not run: 
calcOutput("AtmosphericRedepositionShare")

## End(Not run)

calcAtmosphericRedepositionShare

Description

Calculates share of volatilised nitrogen emissions that is redeposited on different land types.

Usage

calcAtmosphericTransboundaryRedepositionShare(
  maxshare = 0.8,
  scenario = "rcp45"
)

Arguments

maxshare

the maximum amount of emissions deposited within the same cell or country. The remainder will be handled as global emission

scenario

scenario

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

Examples

## Not run: 
calcOutput("AtmosphericRedepositionShare")

## End(Not run)

calcAWMSconfShr

Description

calculates the share of manure managed in different animal waste management systems in confinements. Starting with IPCC 2005 values, turning into scenarios for the future.

Usage

calcAWMSconfShr(rev = 0.1)

Arguments

rev

revision number of madrat run

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky. Modifications by Edna J. Molina Bacca

See Also

calcAWMSconfShrPast()

Examples

## Not run: 
calcOutput("AWMSconfShr")

## End(Not run)

calcAWMSconfShrPast

Description

calculates the share of manure excreted in different types of animal waste management systems in confinements in the year 2005 using the IPCC Guidelines excretion rates.

Usage

calcAWMSconfShrPast(products = "magpie")

Arguments

products

IPCC: IPCC products. MAgPIE: Magpie products

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

See Also

calcAWMSconfShr(), calcExcretionIPCC()

Examples

## Not run: 
calcOutput("AWMSconfShrPast")

## End(Not run)

calcBiomeType

Description

Returns fraction of spatial unit (cell) belonging to a biome type of each biogeographic realm. The classification is based on data from 'the nature conservancy' (https://geospatial.tnc.org/datasets/b1636d640ede4d6ca8f5e369f2dc368b/about) originally developed by Olson et al. (2001), BioScience.

Usage

calcBiomeType(cells = "lpjcell")

Arguments

cells

magpiecell (59199 cells) or lpjcell (67420 cells)

Value

List with a magpie object

Author(s)

Patrick v. Jeetze

See Also

readTNC2019

Examples

## Not run: 
calcOutput("BiomeType", aggregate = FALSE)

## End(Not run)

calcBioplasticToBiomass

Description

calculates conversion factors from bioplastic demand to demand of biomass needed for the production, taking into account the average share of different biomass sources (glycerol, starch, sugars, cellulose, oils) for bioplastic production and corresponding content in the different crop types

Usage

calcBioplasticToBiomass()

Value

List of magpie objects with global conversion factors, unit and description.

Author(s)

Debbora Leip

Examples

## Not run: 
calcOutput("BioplasticToBiomass")

## End(Not run)

calcBodyHeight

Description

reads in the Lutz et al dataset. Aggregates the age structure. Population is divided by sex male (M) , female (F) and both (B) and divided by 8 age classes: 0-4, 5-9, 10-14, 15-19, AG1 (20-29), AG2 (30-59), AG3(60-79), AG4(80+)

Usage

calcBodyHeight(convert = TRUE)

Arguments

convert

if TRUE, the convertscript of Lutz et al is activated. Also,the year 1965 is extrapolatedusing the worldbank population data and sex, age, and education structure of 1970.


calcCentralFeedshares

Description

Calculates future central feed shares for all livestock categories based on the results of a non-linear regression between historical central feed shares and livestock productivity and using Koeppen- Geiger climate zones

Usage

calcCentralFeedshares()

Value

Central feed shares and weights as list of two MAgPIE-objects

Author(s)

Isabelle Weindl, Benjamin Bodirsky, Stephen Wirth, Jan Philipp Dietrich

Examples

## Not run: 
calcOutput("CentralFeedshares")

## End(Not run)

calcClimateClass

Description

fraction of a cell belonging to a given climate classification based on different climate cliassification schemes

Usage

calcClimateClass(datasource = "koeppen", cells = "magpiecell")

Arguments

datasource

select source from: - koeppen for Koeppen Geiger Classification http://koeppen-geiger.vu-wien.ac.at/ - ipcc, ipccReduced, ipccReduced2019 for IPCC Guideline climate classification

cells

"magpiecell" for 59199 cells or "lpjcell" for 67420 cells

Value

Clustered MAgPIE object on requested resolution

Author(s)

Abhijeet Mishra, Kristine Karstens

Examples

## Not run: 
calcOutput("ClimateClass", aggregate = FALSE)

## End(Not run)

calcClossConfinement

Description

Carbon losses for livestock confinements

Usage

calcClossConfinement()

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Kristine Karstens

Examples

## Not run: 
calcOutput("ClossConfinement")

## End(Not run)

calcConstructionWoodDemand

Description

Calculates the demand of construction wood from Galina et al. 2020 data. See

Usage

calcConstructionWoodDemand()

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Abhijeet Mishra

See Also

calcFAOmassbalance_pre()

Examples

## Not run: 
calcOutput("ConstructionWoodDemand")

## End(Not run)

calcDemography

Description

reads in the Lutz et al dataset. Aggregates the age structure. Population is divided by sex male (M) , female (F) and both (B) and divided by 8 age classes: 0-4, 5-9, 10-14, 15-19, AG1 (20-29), AG2 (30-59), AG3(60-79), AG4(80+)

Usage

calcDemography(convert = TRUE, education = TRUE)

Arguments

convert

if TRUE, the convertscript of Lutz et al is activated. Also,the year 1965 is extrapolatedusing the worldbank population data and sex, age, and education structure of 1970.

education

if FALSE, no education dimension will be provided


calc

Description

Provides development state of a country or region. We use worldbank definitions by default: above 12746 USD per capita, its a high-income country, below 1045 its a low-income country, in between its a medium-income country.

Usage

calcDevelopmentState(upper = 12746, lower = 1045)

Arguments

upper

Change upper limit (default: 12746, i.e. the upper threshold for 2013 in current US$)

lower

Change lower limit (default: 1045, i.e. the lower threshold for 2013 in current US$)

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky, Kristine Karstens

See Also

calcGDPpc()

Examples

## Not run: 
calcOutput("DevelopmentState")

## End(Not run)

calcEDGAR6

Description

Creates an emission inventory based on the EDGAR5 and EDGAR6 database.

Usage

calcEDGAR6(non_country = FALSE, nutrient = TRUE)

Arguments

non_country

can alternatively provide SEA and AIR emissions, which are global emissions that cannot be attributed to a country

nutrient

if TRUE, nitrogen is reported as N and CO2 as C

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky


calcEF3confinement

Description

Emission factors for nitrogenous emissions in livestock confinements

Usage

calcEF3confinement(products = "magpie", selection = "n_pollutants_direct")

Arguments

products

Either livestock products in MAgPIE or IPCC products

selection

defaults to n_pollutants_direct

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

Examples

## Not run: 
calcOutput("EF3confinement")

## End(Not run)

calcEF3prp

Description

Returns emission factor for manure excreted during pasture range and paddock. Differs depending on the share of small ruminants.

Usage

calcEF3prp(select_years = "y2005")

Arguments

select_years

if only one year is selected, years is set to NULL

Value

list of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

Examples

## Not run: 
calcOutput("EF3prp")

## End(Not run)

Calculate baseline emissions for maccs

Description

Provides REMIND data for baseline emissions for maccs.

Usage

calcEmiMac()

Value

REMIND data for baseline emissions for maccs and corresonding weights (NULL) as a list of two MAgPIE objects

Author(s)

Lavinia Baumstark

See Also

calcOutput(), readSource()

Examples

## Not run: 
calcOutput("calcEmiMac")

## End(Not run)

calcEmisNitrogenAWMSPast

Description

calculates nitrogenous emissions from animal waste management systems in the historical period

Usage

calcEmisNitrogenAWMSPast()

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

Examples

## Not run: 
calcOutput("EmisNitrogenAWMSPast")

## End(Not run)

calcEmisNitrogenCroplandPast

Description

calculates nitrogenous emissions from croplands in the historical period.

Usage

calcEmisNitrogenCroplandPast(method = "IPCC")

Arguments

method

IPCC: emissions are calculated according the the IPCC 2006 National Guidelines for Greenhouse Gas Inventories. Nsurplus: Emissions in 2005 are calculated according to IPCC, and the scaled with nitrogen losses from croplands.

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

Examples

## Not run: 
calcOutput("EmisNitrogenCroplandPast")

## End(Not run)

calcEmisNitrogenNonaglandPast

Description

Calculates nitrogenous emissions from non-agricultural land for the historical period

Usage

calcEmisNitrogenNonaglandPast(method = "Nsurplus")

Arguments

method

Method for calculating Atmospheric deposition: Nsurplus2 and Nsurplus are based on deposition rates based on own emission calculations after 2 or after 1 iteration, respectively.

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

See Also

calcEmisNitrogenPast(), calcExcretion()

Examples

## Not run: 
calcOutput("EmisNitrogenPasturePast")

## End(Not run)

calcEmisNitrogenOceans

Description

Conputes (nitrogen) emissions of Oceans.

Usage

calcEmisNitrogenOceans(method = "ACCMIP")

Arguments

method

deposition inventory

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

See Also

calcAtmosphericDeposition(), calcNitrogenBudgetCropland()

Examples

## Not run: 
calcOutput("EmisNitrogenOceans")

## End(Not run)

calcEmisNitrogenPast

Description

Calculates nitrogenous emissions from all emission sources for the historical period. Complements own estimates with Edgar esimtates for the historical period.

Usage

calcEmisNitrogenPast(method = "IPCC")

Arguments

method

IPCC: emissions are calculated according the the IPCC 2006 National Guidelines for Greenhouse Gas Inventories. Nsurplus: Emissions in 2005 are calculated according to IPCC, and the scaled with nitrogen losses from croplands.

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

Examples

## Not run: 
calcOutput("EmisNitrogenPast")

## End(Not run)

calcEmisNitrogenPasturePast

Description

Calculates nitrogenous emissions from pastures for the historical period

Usage

calcEmisNitrogenPasturePast(method = "IPCC")

Arguments

method

IPCC: emissions are calculated according the the IPCC 2006 National Guidelines for Greenhouse Gas Inventories. Nsurplus: Emissions in 2005 are calculated according to IPCC, and the scaled with nitrogen losses from croplands.

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

See Also

calcEmisNitrogenPast(), calcExcretion()

Examples

## Not run: 
calcOutput("EmisNitrogenPasturePast")

## End(Not run)

calcEmisNitrogenPreagriculture

Description

Calculates nitrogenous emissions Nitrogen emissions from soils under 100% natural cover (even for crop and urban) assuming a pre-agricultural time.

Usage

calcEmisNitrogenPreagriculture(cellular = FALSE, deposition = TRUE)

Arguments

cellular

cellular or country outputs

deposition

if TRUE, losses include atmospheric deposition inputs that are lost afterwards. If false, only biological fixation is considered.

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

See Also

calcEmisNitrogenPast(), calcExcretion()

Examples

## Not run: 
calcOutput("EmisNitrogenPreagriculture")

## End(Not run)

calcEmisNitrogenWater

Description

Calculates Nitrogen Budgets for surface Water on country levels.

Usage

calcEmisNitrogenWater(method = "Nsurplus")

Arguments

method

method for calculating no3_n in groundwater

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

Examples

## Not run: 
calcOutput("EmisNitrogenWater")

## End(Not run)

calcEmisNitrogenCroplandPast

Description

providees an emission inventory for the past, either from external data or own estimates.

Usage

calcEmissionInventory(
  datasource = "CEDS",
  targetResolution = "sectoral",
  from = "CEDS59",
  to = "Sectors"
)

Arguments

datasource

The Inventory that shall be used. Options are CEDS, combined_CEDS_IPCC (including own estimates where available), IPCC(own estimates), Nsurplus (own estimates)

targetResolution

Specific mapping file to be used.

from

column in mapping

to

column in mapping

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky, Michael S. Crawford

Examples

## Not run: 
calcOutput("EmisNitrogenCroplandPast")

## End(Not run)

calcExcretion

Description

calculates excretion during grazing, cropland-grazing, confinement and collected for fuel. Based on MAgPIE Feed baskets, slaughter biomass and simple allocation rules.

Usage

calcExcretion(cellular = FALSE, cells = "lpjcell", attributes = "npk")

Arguments

cellular

if TRUE value is calculate and returned (set aggregate to FALSE!) on cellular level

cells

Switch between "magpiecell" (59199) and "lpjcell" (67420)

attributes

npk (default) or npkc (inclusing carbon) can be selected

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

See Also

calcExcretionIPCC()

Examples

## Not run: 
calcOutput("Excretion")

## End(Not run)

calcExcretionIPCC

Description

calculates excretion in the year 2005 using the IPCC Guidelines excretion rates.

Usage

calcExcretionIPCC(products = "IPCC")

Arguments

products

IPCC: IPCC products. MAgPIE: Magpie products

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

See Also

calcExcretion(), calcAnimalStocks()

Examples

## Not run: 
calcOutput("ExcretionIPCC")

## End(Not run)

calcFAOIntraYearProd

Description

Distribute massbalanced or FAOSTAT staple production to monthly or quarterly interval based on GGCMI crop calendar. Only national level implemented for now as cellular production only available on 5 year time steps due to memory. Assume rainfed crop calendar date for now.

Usage

calcFAOIntraYearProd(
  day = "harvest_day",
  products = "kcr",
  frequency = "monthly",
  attribute = "dm"
)

Arguments

day

harvest_day (to market) or maturity_day (first mature)

products

"kcr" or "staples" staples uses FAO production dataset instead of calcProduction to only give maize wheat soy and rice. Allows for more years. A bit of a David-specific subtype

frequency

monthly or quarterly. Daily leads to memory limits.

attribute

dm default. can only select one at a time due to memory

#' @seealso readGGCMICropCalendar

Author(s)

David Chen


calcFAOmassbalance

Description

Calculates a massbalance dataset of agricultural production, processing and use out of the combined data of calcFAOharmonized(). Covers dry matter (DM), reactive nitrogen (Nr), Phosphorus (P), Generalizable Energy (GE) and wet matter (WM). New products are added to the Food Balance Sheets, and many processing conversions are made more explicit using simple assumptions. The first part of this function is the calcFAOmassbalance_pre.

Usage

calcFAOmassbalance()

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky, Xiaoxi Wang

See Also

calcFAOmassbalance_pre()

Examples

## Not run: 
calcOutput("FAOmassbalance")

## End(Not run)

calcFAOYield

Description

calculates the yield based on FAO data

Usage

calcFAOYield(
  physical = TRUE,
  attributes = "dm",
  irrigation = FALSE,
  cellular = FALSE,
  cut = FALSE,
  average = 5,
  areaSource = "FAO"
)

Arguments

physical

physical area or havested area

attributes

in dm, wm, ge, nr, p, k

irrigation

distinguish irrigation or not

cellular

if TRUE value is calculate on cellular level

cut

FALSE (default) - do not cut off yields, number between 0 and 1 to define percentile value for cut off

average

averaging period in years (if NULL no averaging is used)

areaSource

data source for croparea used in calculation: FAO or Toolbox

Value

MAgPIE object of yields

Author(s)

Debbora Leip, Jan Philipp Dietrich, Kristine Karstens, Felicitas Beier


calcFeedBalanceflow

Description

Calculates feed balanceflows from MAgPIE-Feed model to meet FAO data

Usage

calcFeedBalanceflow(
  per_livestock_unit = FALSE,
  cellular = FALSE,
  cells = "lpjcell",
  products = "kall",
  future = "constant"
)

Arguments

per_livestock_unit

default false

cellular

if TRUE value is calculate on cellular level

cells

Switch between "magpiecell" (59199) and "lpjcell" (67420)

products

products in feed baskets that shall be reported

future

if FALSE, only past years will be reported (reduces memory)

Value

List of magpie objects with results on country or cellular level, unit and description.

Author(s)

Isabelle Weindl, Kristine Karstens

Examples

## Not run: 
calcOutput("FeedBalanceflow")

## End(Not run)

calcFeedBaskets

Description

Combines feed baskets of the past with scenario-dependent future feed baskets.

Usage

calcFeedBaskets(non_eaten_food = FALSE, fadeout = FALSE, method = "new")

Arguments

non_eaten_food

if TRUE, non-eaten food is included in feed baskets, if not it is excluded.

fadeout

if TRUE, feed basket calibration fades out till 2050.

method

"new" for additive calibration at end, "old" for multiplikative calibration of calShr and end values.

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Isabelle Weindl, Benjamin Leon Bodirsky, Stephen Wirth, Jan Philipp Dietrich

Examples

## Not run: 
calcOutput("FeedBaskets")

## End(Not run)

calcFeedBasketsPast

Description

Calculate historical feed baskets based on output of MAgPIE_FEED model as DM feed biomass (different types of feed) needed per DM livestock products

Usage

calcFeedBasketsPast(non_eaten_food = TRUE)

Arguments

non_eaten_food

if TRUE, non-eaten food is included in feed baskets, if not it is excluded.

Value

Historical feed baskets and corresponding weights as a list of two MAgPIE objects

Author(s)

Isabelle Weindl, Benjamin Bodirsky

See Also

calcOutput(), readFeedModel()

Examples

## Not run: 
calcOutput("FeedBasketsPast")

## End(Not run)

Calculate historical system-specific feed baskets based on output of MAgPIE_FEED model as DM feed biomass (different types of feed) needed per DM livestock products of respective systems

Description

Calculate historical system-specific feed baskets based on output of MAgPIE_FEED model as DM feed biomass (different types of feed) needed per DM livestock products of respective systems

Usage

calcFeedBasketsSysPast()

Value

Historical system-specific feed baskets and corresonding weights as a list of two MAgPIE objects

Author(s)

Isabelle Weindl, Benjamin Bodirsky, Jan Philipp Dietrich

See Also

calcOutput(), readFeedModel(), calcFeedBasketsPast()

Examples

## Not run: 
calcOutput("FeedBasketsSysPast")

## End(Not run)

calcFeedBasketsUncalibrated

Description

Combines uncalibrated feed baskets of the past with scenario-dependent future feed baskets.

Usage

calcFeedBasketsUncalibrated()

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Isabelle Weindl, Benjamin Leon Bodirsky, Stephen Wirth, Jan Philipp Dietrich

Examples

## Not run: 
calcOutput("FeedBasketsUncalibrated")

## End(Not run)

calcFeedEfficiencyFuture

Description

Calculates future central feed shares for all livestock categories based on the results of a non-linear regression between historical central feed shares and livestock productivity and using Koeppen- Geiger climate zones

Usage

calcFeedEfficiencyFuture()

Value

Central feed shares and weights as list of two MAgPIE-objects

Author(s)

Isabelle Weindl, Benjamin Bodirsky, Stephen Wirth

Examples

## Not run: 
calcOutput("FeedEfficiencyFuture")

## End(Not run)

calcFeedPast

Description

Combines feed baskets of the past with livestock production to get total feed demand

Usage

calcFeedPast(
  balanceflow = TRUE,
  cellular = FALSE,
  cells = "lpjcell",
  products = "kall",
  nutrients = "all"
)

Arguments

balanceflow

if TRUE, non-eaten food is included in feed baskets, if not it is excluded.

cellular

if TRUE value is calculate on cellular level with returned datajust in dry matter

cells

Switch between "magpiecell" (59199) and "lpjcell" (67420)

products

products in feed baskets that shall be reported

nutrients

nutrients like dry matter (DM), reactive nitrogen (Nr), Phosphorus (P), Generalizable Energy (GE) and wet matter (WM).

Value

List of magpie objects with results on country or cellular level, unit and description.

Author(s)

Isabelle Weindl, Benjamin Leon Bodirsky, Kristine Karstems

Examples

## Not run: 
calcOutput("FeedPast")

## End(Not run)

calcFertilizerByCrop

Description

calculates the crop-specific use of different N inputs

Usage

calcFertilizerByCrop(
  indicator = "total",
  deposition = "Nsurplus2",
  cellular = FALSE
)

Arguments

indicator

total: estimates the inputs per total crop production; by_harvest estimates the inputs per ton harvest; by_area estimates the inputs per area harvested

deposition

if FALSE, deposition is not accounted for in the distribution. Use FALSE to avoid circularities in calcNitrogenBudget

cellular

cellular disaggreagation or national values

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

See Also

calcNitrogenBudgetCropland()

Examples

## Not run: 
calcOutput("FertilizerByCrop")

## End(Not run)

Calculate Fertilizer of N

Description

Provides FertN data for N.No changes to the content have been done.

Usage

calcFertN(
  appliedto = "total",
  cellular = FALSE,
  deposition = "CEDS",
  max_snupe = 0.85
)

Arguments

appliedto

'total' (default), 'crop' or 'past'

cellular

cellular disaggreagation or national values

deposition

for disaggregation will be passed on to calcNitrogenBudgetCropland

max_snupe

for disaggregation will be passed on to calcNitrogenBudgetCropland

Value

Fertilizer data for N and corresonding weights as a list of two MAgPIE objects

Author(s)

Lavinia Baumstark

See Also

calcOutput(), readIFA(), convertIFA(), readSource()

Examples

## Not run: 
calcOutput("FertN")

## End(Not run)

calcFoodSupplyPast

Description

Calculates the food supply (as defined by FAO, including intake and household waste) for the past.

Usage

calcFoodSupplyPast(
  per_capita = TRUE,
  products = NULL,
  product_aggr = FALSE,
  populationweight = "PopulationPast",
  attributes = c("kcal", "protein", "wm")
)

Arguments

per_capita

if true, calculates per capita demand per day, otherwhise total demand per year

products

a set with the products that shall be provided, e.g. kall. If NULL, the products are provided that are in the primary data

product_aggr

if TRUE, all products are summed up, if "maingroups" products are summed over livestock products, staples and vegfruits.

populationweight

datasource of populationweight: FAO can be selected in order to better meet exact values. Normal datasource is PopulationPast

attributes

attributes of different products,i.e., kcal,protein,wm

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky, Xiaoxi Wang

See Also

calcFAOharmonized()

Examples

## Not run: 
calcOutput("FoodSupplyPast")

## End(Not run)

calcGovernanceIndicator

Description

returns governance indicator from Andrijevic et al. 2019

Usage

calcGovernanceIndicator()

Value

magpie object at iso-country level

Author(s)

Felicitas Beier

Examples

## Not run: 
calcOutput("GovernanceIndicator", aggregate = FALSE)

## End(Not run)

calcGrowingStock

Description

Calculates the growing stocks on FAO data.

Usage

calcGrowingStock()

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Abhijeet Mishra

Examples

## Not run: 
calcOutput("GrowingStock", aggregate = TRUE)

## End(Not run)

calcGrowingStockNatVegAbsolute

Description

Calculates the growing stocks on FAO data.

Usage

calcGrowingStockNatVegAbsolute()

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Abhijeet Mishra

Examples

## Not run: 
calcOutput("GrowingStockNatVegAbsolute", aggregate = TRUE)

## End(Not run)

calcGrowingStockNRF

Description

Calculates the growing stocks from FAO data for naturally regenerating forests i.e. primary forests and secondary forests.

Usage

calcGrowingStockNRF()

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Abhijeet Mishra

Examples

## Not run: 
calcOutput("GrowingStockNRF", aggregate = TRUE)

## End(Not run)

calcGrowingStockpha

Description

Calculates the growing stocks on FAO data.

Usage

calcGrowingStockpha()

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Abhijeet Mishra

Examples

## Not run: 
calcOutput("GrowingStockpha", aggregate = TRUE)

## End(Not run)

calcGrowingStockPlantAbsolute

Description

Calculates the growing stocks on FAO data.

Usage

calcGrowingStockPlantAbsolute()

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Abhijeet Mishra

Examples

## Not run: 
calcOutput("GrowingStockPlantAbsolute", aggregate = TRUE)

## End(Not run)

calcGrowingStockPlantations

Description

Calculates the growing stocks on FAO data.

Usage

calcGrowingStockPlantations()

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Abhijeet Mishra

Examples

## Not run: 
calcOutput("GrowingStockPlantations", aggregate = TRUE)

## End(Not run)

calcGTAPTotalTransportCosts

Description

Calculates iso-level total global transport costs from GTAP for GTAP food commodities

Usage

calcGTAPTotalTransportCosts(costType = "transport", version = "9")

Arguments

costType

transport or wholesale

version

"81" or "9"

Value

List of magpie object with results on country level, unit and description.

Author(s)

David M Chen

Examples

## Not run: 
calcOutput("GTAPTotalTransportCosts")

## End(Not run)

calcHistBioplasticProd

Description

calculates historic bioplastic production based on data and linear extrapolation

Usage

calcHistBioplasticProd()

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Debbora Leip

Examples

## Not run: 
calcOutput("HistBioplasticProd")

## End(Not run)

historical emissions per sector or mac

Description

Provides historical emissions values per economic sector or per mac sector. For now it only includes European data.

Usage

calcHistEmissions(subtype = "sector")

Arguments

subtype

Either "sector" or "MAC"

Value

magpie object of historical emissions data

Author(s)

Renato Rodrigues

Examples

## Not run: 
calcOutput("HistEmissions")

## End(Not run)

calcIniFoodPrice

Description

provides global prices from the IMPACT model projections for MAgPIE commodities for the initialization of the flexible demand model.

Usage

calcIniFoodPrice(datasource = "FAO", year = "y2005", products = "kfo")

Arguments

datasource

The datasource specification. Currently available FAO and IMPACT3.2.2World_Price.

year

Specifies the year for the initialization of prices in MAgPIE. Default is y2005.

products

subselection of products to be returned

Value

List with a magpie object with commodity prices on global level in $17/tDM.

Note

The IMPACT projections start in 2005 and the prices are taken from that year.

Author(s)

Mishko Stevanovic, Benjamin Leon Bodirsky

See Also

readIMPACT3.2.2World_Price()

Examples

## Not run: 
calcOutput("IniFoodPrice", aggregate = FALSE)

## End(Not run)

calcIntake

Description

it computes the total intake kcal/day procapita through the population dataset by Lutz 2014, height and BMI data of NCDrisc, and phyiscal inactivity levels based on Halal et al.

Usage

calcIntake(
  convert = TRUE,
  modelinput = FALSE,
  standardize = FALSE,
  method = "FAO_WHO_UNU1985"
)

Arguments

convert

if TRUE, Lutz data is converted (interpolated completed etc)

modelinput

if TRUE, data is aggregated to country totals for model input

standardize

if FALSE, no standardization. if "recommendations", the US recommendations are used. if BMI, a normal BMI is used.

method

method for calculating intake: either FAO_WHO_UNU1985 for estimates based on height and bodyweight, schofield for just bodyweight, or HHS_USDA for recommended values for US-americans

Value

total "healthy" intake kcal/day procap for each countries divided by sex and 8 age groups.

Author(s)

Benjamin Leon Bodirsky


calcIntakeBodyweight

Description

it computes the food intake pro capita through the bodyweight and the activity level. First it computes the basal metabolic rate (bmr) through the Schofield equation and then the estimated energy required (eer) depending on the activitiy level by FAO/WHO/UNU tables (Human Energy Requirments, Rome 2004)

Usage

calcIntakeBodyweight(
  bodyweight,
  bodyheight = NULL,
  inactivity,
  tmean = NULL,
  method = NULL
)

Arguments

bodyweight

bodyweight in kg per capita or "standardized" for assuming standard values

bodyheight

for mehthod FAO_WHO_UNU1985

inactivity

Share of population inactive, provided as magpie object with different age groups

tmean

mean annual temperature

method

method for calculating intake: either FAO_WHO_UNU1985 for estimates based on height and bodyweight, schofield for just bodyweight, or HHS_USDA for recommended values for US-americans

Author(s)

Eleonora Martinelli


calcIOEdgeBuildings

Description

Calculates buildings-related energy flows from the IEA energy balances. 'output_EDGE_buildings' is a key input to EDGE-Buildings providing the historic final energy demand from buildings. 'output_EDGE' does the same for buildings and industry together.

Usage

calcIOEdgeBuildings(
  subtype = c("output_EDGE", "output_EDGE_buildings"),
  ieaVersion = c("default", "latest")
)

Arguments

subtype

Data subtype. See default argument for possible values.

ieaVersion

Release version of IEA data, either 'default' (vetted and used in REMIND) or 'latest'.

Value

IEA data as MAgPIE object aggregated to country level

Author(s)

Pascal Sauer, Anastasis Giannousakis, Robin Hasse

See Also

calcOutput

Examples

## Not run: 
a <- calcOutput("IOEdgeBuildings", subtype = "output_EDGE_buildings")

## End(Not run)

calcIPCCefNSoil

Description

Emission factors for croplands based on IPCC using a country-level leaching fraction

Usage

calcIPCCefNSoil()

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

Examples

## Not run: 
calcOutput("IPCCefNSoil")

## End(Not run)

calcIPCCfracLeach

Description

calculates the leaching rate FRAC_LEACH as defined by the IPCC Guidelines for National Greenhouse Gas Inventories 2006. We use the approach used by Canada, see Velthof, Gerardus Lambertus, and J. Mosquera Losada. 2011. Calculation of Nitrous Oxide Emission from Agriculture in the Netherlands: Update of Emission Factors and Leaching Fraction. Alterra. http://library.wur.nl/WebQuery/wurpubs/406284.

Usage

calcIPCCfracLeach(cellular = TRUE)

Arguments

cellular

if true, returned on cell level

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

See Also

calcOutput()

Examples

## Not run: 
a <- calcOutput("IPCCfracLeach", cellular = FALSE)

## End(Not run)

calcLandArea

Description

total land area in a cell

Usage

calcLandArea(cells = "lpjcell")

Arguments

cells

"magpiecell" for 59199 cells or "lpjcell" for 67420 cells

Value

magpie object in cellular resolution

Author(s)

Jan Philipp Dietrich, Felicitas Beier

Examples

## Not run: 
calcOutput("LandArea", aggregate = FALSE)

## End(Not run)

calcLandEmissions

Description

Land emission data. This function was originally called calcValidEmissions and located in mrvalidation.

Usage

calcLandEmissions(datasource = "CEDS")

Arguments

datasource

The Emission Inventory that shall be used. For futher information, best see function calcEmissionInventory. Options are e.g. CEDS, combined_CEDS_IPCC (including own estimates where available), IPCC(own estimates), Nsurplus (own estimates)

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky, Michael S. Crawford

Examples

## Not run: 
calcOutput("LandEmissions")

## End(Not run)

calcLanduseIntensity

Description

This function prepares total tau values for use. As the source data already provides all required information this function purely removes unrequired data and moves the xref values to the weighting object which is required for aggregation.

Usage

calcLanduseIntensity(sectoral = "kcr", rescale = TRUE)

Arguments

sectoral

"kcr" (default) for MAgPIE crop items and "lpj" for LPJmL crop items, "pasture" for pasture

rescale

TRUE (default), if Tau should be rescaled in a way, that 2010 is always 1

Value

Total tau data and corresponding weights as a list of two MAgPIE objects

Author(s)

Benjamin Leon Bodirsky, Kristine Karstens, Felicitas Beier

See Also

calcTauTotal(), readTau(), convertTau()

Examples

## Not run: 
calcOutput("LanduseIntensity")

## End(Not run)

calcLivestockGridded

Description

Distributes crop, pasture and livestock production in space to 0.5 degree

Usage

calcLivestockGridded(details = FALSE)

Arguments

details

switch, if set to TRUE will lead to reporting of extensive and intensive livestock shares

Value

List of magpie objects with results on cellular level, weights on cellular level, unit and description.

Author(s)

Kristine Karstens

Examples

## Not run: 
calcOutput("calcLivestockGridded")

## End(Not run)

Calculate Yields for Livestock

Description

Provides MAgPIE-FEED data for livestock-yields calculated in the regression for feed (calcRegressionFEED).. No changes to the content have been done, besides renaming and providing weights.

Usage

calcLivestockProductivity(future = TRUE)

Arguments

future

if TRUE calculates Constant future and linear trends based on SSP Expert guesses

Value

MAgPIE-FEED data for livestock-yields and corresonding weights as a list of two MAgPIE objects

Author(s)

Isabelle Weindl, Lavinia Baumstark, Stephen Wirth

See Also

calcOutput(), readSource()

Examples

## Not run: 
calcOutput("LivestockProductivity")

## End(Not run)

calcMacBase calculate MacBase

Description

calcMacBase calculate MacBase

Usage

calcMacBaseLandUse(subtype)

Arguments

subtype

Source of subset of emissions

Value

magpie object

Author(s)

David Klein, Julian Oeser

See Also

calcOutput()

Examples

## Not run: 
a <- calcOutput(type = "MacBaseLandUse")

## End(Not run)

Calculation of CH4 MAC curves of Energy Industry and Landuse

Description

Calculation of the CH4 relative costcurves (subtypes: Energy Industry and Landuse) weighted by the baseline emissions. Sources: CH4 coal losses/leakages, CH4 oil losses/leakages, CH4 natural gas losses/leakages, CH4 Landfills, CH4 Domestic Sewage, CH4 Wetland rice, CH4 Animals, CH4 Animal waste divided in classes 1-201.

Usage

calcMACCsCH4(sector = "all", source = "ImageMacc")

Arguments

sector

"all" or "landuse"; "all" includes energy_industry and landuse

source

"ImageMacc" or "PBL_MACC_2019"

Value

MAgPIE object

Author(s)

Nele Steinmetz, Florian Humpenoeder, Michael Windisch

See Also

calcOutput(), readImageMacc(), convertImageMacc()

Examples

## Not run: 
calcOutput("MACCsCH4")

## End(Not run)

Calculation of N2O MAC curves of Energy Industry and Landuse

Description

Calculation of the N2O relative costcurves (subtypes: Energy Industry and Landuse) weighted by the baseline emissions. Sources: N2O Transport, N2O Adipic acid production, N2O Nitric acid production, N2O Fertilizer, N2O Animal waste, N2O Domestic sewage divided in classes 1-201.

Usage

calcMACCsN2O(sector = "all", source = "ImageMacc")

Arguments

sector

"all" or "landuse"; "all"" includes energy_industry and landuse

source

"ImageMacc" or "PBL_MACC_2019"

Value

MAgPIE object

Author(s)

Nele Steinmetz, Florian Humpenoeder, Michael Windisch

See Also

calcOutput(), readImageMacc(), convertImageMacc()

Examples

## Not run: 
calcOutput("MACCsN2O")

## End(Not run)

calcManureFuelShr

Description

calculates the share of Manure excreted during grazing which is collected for fuel. For the future, we assume that with the development, the fuel share reaches 0.

Usage

calcManureFuelShr(products = "magpie")

Arguments

products

IPCC: IPCC products. MAgPIE: Magpie products

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

See Also

calcExcretion()

Examples

## Not run: 
calcOutput("ManureFuelShr")

## End(Not run)

calcManureRecyclingCroplandPast

Description

calculates manure recycling to cropland based on excretions, animal waste management types (and their shares per country) and emission factors for nitrogenous emissions in livestock confinements

Usage

calcManureRecyclingCroplandPast(
  products = "sum",
  cellular = FALSE,
  cells = "lpjcell"
)

Arguments

products

"sum" (default) or "kli"

cellular

if TRUE value is calculate and returned (set aggregate to FALSE!) on cellular level

cells

Switch between "magpiecell" (59199) and "lpjcell" (67420)

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky, Kristine Karstens

See Also

calcExcretion()

Examples

## Not run: 
calcOutput("calcManureRecyclingCroplandPast")

## End(Not run)

calcNitrogenBNF

Description

calculates fixation from freeliving bacteria and from nitrogen-fixing crops and natural vegetation

Usage

calcNitrogenBNF(cellular = FALSE)

Arguments

cellular

cellular disaggreagation or national values

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

See Also

calcNitrogenFixationPast()

Examples

## Not run: 
calcOutput("NitrogenBNF")

## End(Not run)

calcNitrogenBudgetCropland

Description

Calculates Nitrogen Budgets for Cropland soils on country levels.

Usage

calcNitrogenBudgetCropland(
  cellular = FALSE,
  deposition = "CEDS",
  include_fertilizer = TRUE,
  max_snupe = 0.85
)

Arguments

cellular

disaggregated to 0.5 degree grid

deposition

if FALSE, deposition is not accounted for in the distribution. Use FALSE to avoid circularities in calcNitrogenBudget

include_fertilizer

including fertilizer in budget. Use FALSE to avoid circularities in specific cases

max_snupe

NULL or a numeric value. if numeric, an additional N balanceflow is included that takes care that the soil nitrogen uptake efficiency does not exceed the numeric value in balanceflow.

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

Examples

## Not run: 
calcOutput("NitrogenBudgetCropland")

## End(Not run)

calcNitrogenBudgetNonagland

Description

Calculates Nitrogen Budgets for Non-agricultural land on country levels.

Usage

calcNitrogenBudgetNonagland(
  deposition = "CEDS",
  max_nue = 0.95,
  cellular = FALSE
)

Arguments

deposition

if FALSE, deposition is not accounted for in the distribution. Use FALSE to avoid circularities in calcNitrogenBudget

max_nue

NULL or a numeric value. if numeric, an additional N balanceflow is included that takes care that the nitrogen use efficiency does not exceed the numeric value in balanceflow.

cellular

TRUE returns output on 0.5° grid

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

Examples

## Not run: 
calcOutput("NitrogenBudgetNonagland")

## End(Not run)

calcNitrogenBudgetOcean

Description

Calculates Nitrogen Budgets for Oceans on global level. Values are placed in Antarcica (ATA)

Usage

calcNitrogenBudgetOcean(deposition = "ACCMIP", leaching = "Nsurplus")

Arguments

deposition

Method for calculating Atmospheric deposition: Nsurplus2 and Nsurplus are based on deposition rates based on own emission calculations after 2 or after 1 iteration, respectively.

leaching

Method for calculating leaching: Nsurplus2 and Nsurplus are based on deposition rates based on own emission calculations after 2 or after 1 iteration, respectively.

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

Examples

## Not run: 
calcOutput("NitrogenBudgetOcean")

## End(Not run)

calcNitrogenBudgetPasture

Description

Calculates Nitrogen Budgets for Pasture soils on country levels.

Usage

calcNitrogenBudgetPasture(
  cellular = FALSE,
  include_fertilizer = TRUE,
  deposition = "CEDS",
  max_nue = 0.9
)

Arguments

cellular

cellular disaggreagation or national values

include_fertilizer

including fertilizer in budget. Use FALSE to avoid circularities in specific cases

deposition

if FALSE, deposition is not accounted for in the distribution. Use FALSE to avoid circularities in calcNitrogenBudget

max_nue

NULL or a numeric value. if numeric, an additional N balanceflow is included that takes care that the nitrogen use efficiency does not exceed the numeric value in balanceflow.

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

Examples

## Not run: 
calcOutput("NitrogenBudgetPasture")

## End(Not run)

calcNitrogenFixationPast

Description

calculates fixation from freeliving bacteria and from nitrogen-fixing crops

Usage

calcNitrogenFixationPast(
  fixation_types = "both",
  sum_plantparts = TRUE,
  cellular = FALSE,
  irrigation = FALSE
)

Arguments

fixation_types

either "fixation_crops", "fixation_freeliving", or "both"

sum_plantparts

if false, crop residues, belowground residues and harvested organ are reported separately

cellular

cellular estimates optional

irrigation

if TRUE, distinguishes irrigated and non-irrigated crops

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

See Also

calcNitrogenFixationPast()

Examples

## Not run: 
calcOutput("calcNitrogenFixationPast")

## End(Not run)

calcNitrogenFixationRateNatural

Description

calculates fixation rates from natural ecosystems based on evapostranspiration

Usage

calcNitrogenFixationRateNatural(cells = "lpjcell")

Arguments

cells

"magpiecell" for 59199 cells or "lpjcell" for 67420 cells

Value

List of magpie objects with results on global level, empty weight, unit and description.

Author(s)

Benjamin Leon Bodirsky

See Also

calcNitrogenFixationPast() readHerridge()

Examples

## Not run: 
calcOutput("NitrogenFixationRateNatural")

## End(Not run)

calcNitrogenWithdrawalByCrop

Description

calculates the crop-specific withdrawals of nutrients from soils

Usage

calcNitrogenWithdrawalByCrop(
  indicator = "total",
  cellular = FALSE,
  irrigation = FALSE
)

Arguments

indicator

total: estimates the inputs per total crop production; by_area estimates the inputs per area harvested

cellular

cellular disaggreagation or national values

irrigation

FALSE for the sum of irrigated and rainfed, FALSE for separated categories, 'rainfed' or 'irrigated for single categories

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

See Also

calcNitrogenBudgetCropland()

Examples

## Not run: 
calcOutput("NitrogenWithdrawalByCrop")

## End(Not run)

calcNuePasture

Description

calculates the soil nitrogen uptake efficiency of pastures. # This is the nitrogen taken up from the soil (N in crop biomass minus biological fixation minus seed N) divided by the soil N inputs (fertilizer, manure etc). For the future, NUE scenarios are added.

Usage

calcNuePasture(cellular = FALSE, maccbase = TRUE)

Arguments

cellular

cellular disaggreagation or national values

maccbase

whether future scenarios should be expressed as base efficiency, excluding additional macc improvements (new default)

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

See Also

calcSNUpE() calcNitrogenBudgetPasture()

Examples

## Not run: 
calcOutput("NuePasture")

## End(Not run)

calcNutrientBudgetSewage

Description

Nutrient Budget for Wastewater treatment and sewage

Usage

calcNutrientBudgetSewage(historic = TRUE)

Arguments

historic

when TRUE only for the historic period, otherwise including future scenarios

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

See Also

calcNitrogenBudgetCropland()

Examples

## Not run: 
calcOutput("NutrientBudgetSewage")

## End(Not run)

calcPhysicalInactivity

Description

physical inactivity level estimate based on Hallal, Pedro C, Lars Bo Andersen, Fiona C Bull, Regina Guthold, William Haskell, and Ulf Ekelund. 2012. "Global Physical Activity Levels: Surveillance Progress, Pitfalls, and Prospects." The Lancet 380 (9838):247-57. https://doi.org/10.1016/S0140-6736(12)60646-1.

Usage

calcPhysicalInactivity(update = TRUE)

Arguments

update

WHO estimates from http://apps.who.int/gho/data/view.main.2487?lang=en seem to have updated. TRUE provides the results as they were online on 27.2.2024


calcPlantationCellular

Description

Calculates the cellular plantation area based on carbon densities

Usage

calcPlantationCellular()

Value

List of magpie object with results on cellular level, weight on cellular level, unit and description.

Author(s)

Abhijeet Mishra

Examples

## Not run: 
calcOutput("PlantationCellular")

## End(Not run)

calcPlantEstablishCalib

Description

Calculates the calibration factors for plantation establishment globally

Usage

calcPlantEstablishCalib()

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Abhijeet Mishra

Examples

## Not run: 
calcOutput("PlantEstablishCalib", aggregate = TRUE)

## End(Not run)

calcPriceAgriculture

Description

provides global prices from the IMPACT model projections, World Bank observations, and FAO observations for MAgPIE commodities in $/tDM

Usage

calcPriceAgriculture(datasource = "IMPACT3.2.2World_Price", unit = "US$17/tDM")

Arguments

datasource

Options of the source of data: IMPACT3.2.2World_Price, FAO, FAOp and WBGEM

unit

A string with the unit that should be returned. Options are:

  • "current LCU"

  • "current Int$PPP"

  • "current US$MER"

  • "constant YYYY LCU"

  • "constant YYYY Int$PPP"

  • "constant YYYY US$MER"

Value

List with a magpie object with commodity prices

Author(s)

Mishko Stevanovic, Xiaoxi Wang, Felicitas Beier

See Also

readIMPACT3.2.2World_Price(), calcWBGEM(), readWBGEM()

Examples

## Not run: 
calcOutput("PriceAgriculture", datasource = "IMPACT3.2.2World_Price", aggregate = FALSE)
calcOutput("PriceAgriculture", datasource = "FAO")
calcOutput("PriceAgriculture", datasource = "WBGEM", aggregate = FALSE)

## End(Not run)

Calculate historical distribution of livestock production across different systems based on output of MAgPIE_FEED model

Description

Calculate historical distribution of livestock production across different systems based on output of MAgPIE_FEED model

Usage

calcProdSysRatioPast()

Value

Historical distribution of livestock production across different systems and corresponding weights as a list of two MAgPIE objects

Author(s)

Isabelle Weindl

See Also

calcOutput(), readFeedModel()

Examples

## Not run: 
calcOutput("ProdSysRatioPast")

## End(Not run)

calcProduction

Description

Distributes crop, pasture and livestock production in space to 0.5 degree

Usage

calcProduction(
  products = "kcr",
  cellular = FALSE,
  cells = "lpjcell",
  calibrated = TRUE,
  attributes = "all",
  irrigation = FALSE
)

Arguments

products

setname of products ("kcr", "kli", "pasture")

cellular

if TRUE production is calculate on cellular level

cells

Switch between "magpiecell" (59199) and "lpjcell" (67420)

calibrated

if FALSE, lpj yields will be used uncalibrated, if true, calibrated on FAP production on country level

attributes

"All" for all crop attributes, or specify e.g. DM (dry matter), Nr (nitrogen) for memory reduction

irrigation

if TRUE, additional information on irrigated and rainfed production is provided

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

See Also

calcLanduseInitialisation(), calcCroparea()

Examples

## Not run: 
calcOutput("Production")

## End(Not run)

calcRegressionParameters

Description

Writes down the equation parameters from various data sources

Usage

calcRegressionParameters(regression = "bmi_shr")

Arguments

regression

bmi_shr: Shares of BMI withina population. schofield or FAO_WHO_UNU1985: calculates intake based on anthropometrics

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

Examples

## Not run: 
calcOutput("RegressionParameters")

## End(Not run)

calcResBiomass

Description

Provides MAgPIE-FEED data for aboveground and belowground residues biomass

Usage

calcResBiomass(
  cellular = FALSE,
  cells = "lpjcell",
  plantparts = "both",
  irrigation = FALSE,
  attributes = "all",
  scenario = "default"
)

Arguments

cellular

If TRUE calculation and output on cellular level

cells

Switch between "magpiecell" (59199) and "lpjcell" (67420)

plantparts

both, ag (aboveground) or belowground (bg). Both can have memory problems for cellular outputs

irrigation

if TRUE, distinguishes irrigated and non-irrigated crops

attributes

in dm, wm, ge, nr, p, k

scenario

define scenario switch for sensititvy analysis for historical SOC budget

Value

MAgPIE-FEED data for ProdResAg and corresonding weights as a list of two MAgPIE objects

Author(s)

Lavinia Baumstark, Isabelle Weindl, Benjamin Bodirsky

See Also

calcOutput(), readSource()

Examples

## Not run: 
calcOutput("ResBiomass")

## End(Not run)

calcResDemand

Description

Calculates the demand for Crop Residues

Usage

calcResDemand(cellular = FALSE, scenario = "dafault")

Arguments

cellular

If TRUE calculation and output on cellular level

scenario

define scenario switch for sensititvy analysis for historical SOC budget

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

See Also

calcResBiomass()

Examples

## Not run: 
calcOutput("ResDemand")

## End(Not run)

calcResFieldBalancePast

Description

Calculates data for aboveground and belowground residues production with other usage

Usage

calcResFieldBalancePast(
  cellular = FALSE,
  products = "sum",
  scenario = "default"
)

Arguments

cellular

If TRUE calculation and output on cellular level

products

"sum" (default) or "kres"

scenario

define scenario switch for sensititvy analysis for historical SOC budget

Value

data

Author(s)

Benjamin Bodirsky

See Also

calcOutput(), readSource()

Examples

## Not run: 
calcOutput("ResFieldBalancePast")

## End(Not run)

calcResFor2ndBioengery

Description

Calculates the supply potential of Crop Residues for 2nd generation bioenergy for future and different ssp scenarios

Usage

calcResFor2ndBioengery(products = "all", product_aggr = TRUE, add_off = FALSE)

Arguments

products

categorie (set) that should be reported, switch between "kres", "res_crop" (sum over all "kres"), "res_wood" and "all"

product_aggr

boolean, if product set should be summed up

add_off

add a column with empty supply for no residues available for 2nd gen BE

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Kristine Karstens

See Also

calcResFor2ndBioengery()

Examples

## Not run: 
calcOutput("ResFor2ndBioengery")

## End(Not run)

calcRockNWeathering

Description

calculates amount of yearly N from rock weathering by country or global total, disaggregated by land use type (LUH2v2 6 class, with FAO forest correction)

Usage

calcRockNWeathering()

Value

MAgPIE object of amount of N (Mt)

Author(s)

David M Chen


calcSeed

Description

Calculates Seed demand

Usage

calcSeed(
  cellular = FALSE,
  cells = "lpjcell",
  products = "kall",
  irrigation = FALSE,
  attributes = "all"
)

Arguments

cellular

cellular or regional level

cells

Switch between "magpiecell" (59199) and "lpjcell" (67420)

products

kcr or also kall, which includes seeds for eggs and fish

irrigation

if TRUE, distinguishes irrigated and non-irrigated crops

attributes

in dm, wm, ge, nr, p, k

Value

List of magpie object with results and weight on country or cellular level, unit and description.

Author(s)

Benjamin Leon Bodirsky

Examples

## Not run: 
calcOutput("Seed")

## End(Not run)

calcSNUpE

Description

calculates the soil nitrogen uptake efficiency. This is the nitrogen taken up from the soil (N in crop biomass minus biological fixation minus seed N) divided by the soil N inputs (fertilizer, manure etc). For the future, SNuPE scenarios are added.

Usage

calcSNUpE(max_snupe = 0.85, cellular = FALSE, rev = 0.1, maccbase = TRUE)

Arguments

max_snupe

Maximum realistic SNUPE. All values above will be limited to this value. Only holds for past values; future scneario values can exceed this number.

cellular

disaggregated to 0.5 degree grid

rev

revision number of madrat run

maccbase

whether future scenarios should be expressed as base efficiency, excluding additional macc improvemetns (new default)

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky, Xiaoxi Wang

See Also

calcNitrogenBudgetCropland()

Examples

## Not run: 
calcOutput("SNUpE")

## End(Not run)

calcSOCLossShare

Description

Calculates soil organic carbon loss share on cellular level

Usage

calcSOCLossShare(
  subsystems = FALSE,
  rate = "change",
  factor = "ipccReduced",
  cells = "lpjcell"
)

Arguments

subsystems

if FALSE just generic values will be used per climate zone , if TRUE crop specific values will be reported, if aggregated crop specific factors will be aggregated using crop area

rate

if change, change rates will be reported; if loss, loss rates will be reported

factor

switch for different ipcc versions (ipccReduced, ipccReduced2019)

cells

"magpiecell" for 59199 cells or "lpjcell" for 67420 cells

Value

List of magpie objects with results on cellular level, weight, unit and description.

Author(s)

Kristine Karstens

Examples

## Not run: 
calcOutput("SOCLossShare", aggregate = FALSE)

## End(Not run)

calcSOM

Description

calculates Soil Organic Matter Pool, accounting for the management history. We assume carbon Stocks from LPJml natural vegetation as a starting point. Here we use the upper 30cm soil layer (0-20cm of + 1/3 of 30-50 cm). We then correct carbon pools by lost c-share depending on the climate region, using default factors of IPCC Guidelines 2006 table 5.5. We assume that this IPCC-corrected value is the target long-term equilibrium value for the soil stocks. Because soil decline and build-up slowly, we assume that in every year, the carbon pools move 15% towards this new equilibrium. This assumption is in line with IPCC saying that the process will take 20 years: with our assumption, after 5 years 44% of the carbon pool is gone, after 10 years 80% and after 20 years 96%. We determine a carbon stock for cropland soils and non-cropland soils in every cell. If the cropland area expands, the carbon stock of noncropland is proportionally assigned to the cropland pool and vice versa. The outputs of the function are the soilc stocks for cropland and non-cropland. Relevant for the release of N by SOM loss is also the change in carbon stocks per ha, as this relases or binds N. This is done in delta cropland soilc.

Usage

calcSOM(climatetype = "historical", subtype = "stock", cells = "lpjcell")

Arguments

climatetype

Switch between different climate scenarios (default on "historical")

subtype

"stock" (default) for absoulte values, "density" for per hectar values

cells

"magpiecell" for 59199 cells or "lpjcell" for 67420 cells

Value

List of magpie object with results on country or cellular level, weight on cellular level, unit and description.

Author(s)

Benjamin Leon Bodirsky, Kristine Karstens

Examples

## Not run: 
calcOutput("SOM2")

## End(Not run)

calcSOMlossN

Description

calculates effect on N from Soil Organic Matter loss

Usage

calcSOMlossN(cellular = FALSE, cells = "lpjcell")

Arguments

cellular

if TRUE cellular level is returned

cells

"magpiecell" for 59199 cells or "lpjcell" for 67420 cells

Value

List of magpie object with results on country or cellular level, weight on cellular level, unit and description.

Author(s)

Benjamin Leon Bodirsky,

Examples

## Not run: 
calcOutput("SOMlossN")

## End(Not run)

calcStorage

Description

calculates stock levels of magpie commodities based on FAO data. FAO data only has stock variation so we assume lowest level for each product/country as 0 level USDA data to be potentially included in future second data source

Usage

calcStorage(datasource = "FAO")

Arguments

datasource

Options of the source of data, currently only FAO: FAO.

Value

List with a magpie object with stock level in tonnes

Author(s)

David Chen

Examples

## Not run: 
calcOutput("Storage", datasource = "FAO")

## End(Not run)

calcTemperature

Description

calculates average monthly temperature on different landuse types

Usage

calcTemperature(landusetypes = "all", months = FALSE, convert = TRUE)

Arguments

landusetypes

all or only one (to save computation memory)

months

FALSE for yearly average, TRUE for monthly values

convert

FALSE for raw values of temperature, TRUE add temperature of 15 degrees for countries without observations or land mass.

Value

List of magpie object with results on country level, weight on country level, unit and description.

Author(s)

Benjamin Leon Bodirsky

Examples

## Not run: 
calcOutput("Temperature")

## End(Not run)

calcTimberDemand

Description

Calculates the demand of timber from FAO data (including intermediate products).

Usage

calcTimberDemand()

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Abhijeet Mishra

See Also

calcFAOmassbalance_pre()

Examples

## Not run: 
calcOutput("TimberDemand")

## End(Not run)

calcWBGEM

Description

recover world price of commodity in terms of real 2005 USD per metric ton

Usage

calcWBGEM()

Value

magpie object of time series of world price of commodities

Author(s)

Xiaoxi Wang

See Also

readSource(), readWBGEM()

Examples

## Not run: 
calcOutput("WBGEM")

## End(Not run)

convertACCMIP

Description

function to convert ACCMIP data to isocountry resolution

Usage

convertACCMIP(x)

Arguments

x

MAgPIE object

Value

MAgPIE object

Author(s)

Roman Popov, Felicitas Beier

Examples

## Not run: 
readSource("ACCMIP", subtype = "nhx_1850")

## End(Not run)

convertBodirsky2018

Description

Reads in regression parameters estimated using mrregression, and reads in some scenario based on Bodirsky et al not yet published

Usage

convertBodirsky2018(x, subtype)

Arguments

x

magpie object from read function

subtype

bmi_share, demand_regression, intake_regression or bodyheight_regression for the estimated regression paramters of different regressions. scenarios for scenario projections.

Value

magpie object

See Also

readBodirsky2018()


convertCEDS2021

Description

converts emission data from the CEDS database

Usage

convertCEDS2021(x)

Arguments

x

magpie object from source function

Value

MAgPIE object

Author(s)

Benjamin Leon Bodirsky, David Klein


convertCEDS2024

Description

converts emission data from the CEDS database

Usage

convertCEDS2024(x)

Arguments

x

magpie object from source function

Value

MAgPIE object

Author(s)

Benjamin Leon Bodirsky, David Klein


Convert European Environment Agency (EEA) data

Description

Read-in European Environment Agency (EEA) data on ETS emissions as magclass object

Usage

convertEEA_EuropeanEnvironmentAgency(x, subtype)

Arguments

x

MAgPIE object to be converted

subtype

data subtype. Either "ETS", "historical", "projections", or "projections-detailed"

Value

magpie object of European Environment Agency (EEA) ETS emissions (GtCO2)

Author(s)

Renato Rodrigues, Robin Hasse

See Also

readSource

Examples

## Not run: 
a <- readSource(type = "EEA_EuropeanEnvironmentAgency", subtype = "ETS")

## End(Not run)

Convert EU Reference Scenario

Description

Converts EU Reference Scenario magpie object into appropriate form for the REMIND model

Usage

convertEU_ReferenceScenario(x, subtype)

Arguments

x

EU Reference Scenario magpie object derived from readEU_ReferenceScenario function

subtype

data subtype. Either "techAssump.*", "2016" or "2020"

Value

converted EU Reference Scenario magpie object

Author(s)

Renato Rodrigues, Falk Benke, Robin Hasse

Examples

## Not run: 
test <- readSource("EU_ReferenceScenario", subtype = "2020", convert = TRUE)

## End(Not run)

Read Eurostat historical emissions (env_air_gge)

Description

Read Eurostat historical emissions (env_air_gge)

Usage

convertEurostat(x, subtype)

Arguments

x

MAgPIE object to be converted

subtype

'emissions' for original Eurostat emissions split, 'MACCemi' for MACC historical emissions, or 'sectorEmi' for sector specific emissions, or 'latest' for most up-to-date data

Value

A MAgPIE object containing the Eurostat historical emissions (MtCO2)

Author(s)

Renato Rodrigues

Examples

## Not run: 
a <- convertEurostat(x, subtype = "emissions")

## End(Not run)

convertExpertGuessSSPLivestockProduction

Description

convert the Expert Guesses for future Livestock Production for the SSP Scenarios

Usage

convertExpertGuessSSPLivestockProduction(x)

Arguments

x

MAgPIE-Object contaiing data to convert

Value

magpie object containing converted expert guesses

Author(s)

Stephen Wirth

See Also

readSource()

Examples

## Not run: 
a <- readSource("ExpertGuessSSPLivestockProduction","ssp1")

## End(Not run)

Convert FeedModel data

Description

Convert production system distribution and feed basket data to ISO country level.

Usage

convertFeedModel(x, subtype = "FeedBaskets")

Arguments

x

MAgPIE object containing production system distribution and feed basket data.

subtype

Available subtypes: "ProdSysRatio", "FeedBaskets" and "FeedBasketsDetailed"

Value

Production system distribution and feed basket data as MAgPIE object on ISO country level

Author(s)

Isabelle Weindl, Jan Philipp Dietrich


convertGTAPv8v9

Description

disaggregates country groups from GTAP according to GDP share

Usage

convertGTAPv8v9(x, subtype)

Arguments

x

unconverted magpie object from read-script

subtype

GTAP header that should be read

Value

Data as MAgPIE object with common country list

Author(s)

Debbora Leip, David M. Chen

Examples

## Not run: 
a <- readSource("convertGTAPv8v9", "81:SF01", convert = TRUE)

## End(Not run)

convertHerridge

Description

Converts the Data from Herridge et al. to fit the common country list. Source: Herridge D. F., Peoples M. B., Boddey R. M.: Global inputs of biological nitrogen fixation in agricultural systems

Usage

convertHerridge(x)

Arguments

x

MAgPIE object to be converted

Value

A MAgPIE object containing the share of Nr derived from fixation for each country and each commodity.

Author(s)

Stephen Wirth

Examples

## Not run: 
x <- readSource("Herridge")

## End(Not run)

convertICP2017

Description

converts data of World Bank ICP round, downloaded from here: https://databank.worldbank.org/source/icp-2017 mainly a currency conversion to MER2017. Assume that in the original dataset, 2011 values are in 2011MER and 2017 in 2017MER, given the ICP rounds

Usage

convertICP2017(x, subtype = "per_cap_expMER")

Arguments

x

MAgPIE object containing original values

subtype

data subtype needed. Either "priceLevel", or "per_cap_exp"

Value

magpie object of relative price levels (world = 100) or per capita expenditure (USD17 MER)

Author(s)

David M Chen

Examples

## Not run: 
a <- convertSource("ICP2017", "per_cap_exp")

## End(Not run)

Convert IEA

Description

Convert IEA energy data to data on ISO country level.

Usage

convertIEA(x, subtype)

Arguments

x

MAgPIE object containing IEA values at IEA mixed country-region resolution

subtype

data subtype. Either "EnergyBalances", "EnergyBalances-latest", or "Emissions"

Value

IEA data as MAgPIE object aggregated to country level

Author(s)

Anastasis Giannousakis, Renato Rodrigues, Falk Benke


Convert IEA End Uses and Efficiency Indicators data to data on ISO country level.

Description

Convert IEA End Uses and Efficiency Indicators data to data on ISO country level.

Usage

convertIEA_EEI(x)

Arguments

x

MAgPIE object to be converted

Author(s)

Falk Benke


Convert IFA

Description

Convert IFADavies (2013) data to ISO country level.

Usage

convertIFA(x)

Arguments

x

MAgPIE object containing IFA data region resolution

Value

MAgPIE object of the IFA data disaggregated to country level

Author(s)

Lavinia Baumstark

Examples

## Not run: 
a <- convertIFA(x)

## End(Not run)

Convert subtypes of the ImageMacc data

Description

Convert subtypes from ImageMacc to data on ISO country level. Correct values for N2O of the subtype "baseline_sources" from N to N2O (factor: 44/28).

Usage

convertImageMacc(x, subtype)

Arguments

x

MAgPIE object containing ImageMacc data mixed on region level

subtype

data subtype. Either CH4_Energy_Industry", "CH4_Landuse", "N2O_Energy_Industry", "N2O_Landuse", "HFC_tot", "SF6_tot", "PFC_tot" or "baseline_sources"

Value

ImageMacc data as MAgPIE object for all subtypes aggregated to country level

Author(s)

Nele Steinmetz

See Also

readSource()

Examples

## Not run: 
a <- readSource("ImageMacc", "CH4_Energy_Industry")
a <- readSource("ImageMacc", "CH4_Landuse")
a <- readSource("ImageMacc", "N2O_Energy_Industry")
a <- readSource("ImageMacc", "N2O_Landuse")
a <- readSource("ImageMacc", "HFC_tot")
a <- readSource("ImageMacc", "SF6_tot")
a <- readSource("ImageMacc", "PFC_tot")
a <- readSource("ImageMacc", "baseline_sources")

## End(Not run)

Convert subtypes of the IPCC data

Description

Convert subtypes on ISO country level.

Usage

convertIPCC(x, subtype)

Arguments

x

MAgPIE object containing IPCC data on region level

subtype

data subtype. Either "awmsShr", "awmsEfCh4", "awmsParCh4", "nExcrRate"

Value

IPCC data as MAgPIE object for all subtypes on country level

Author(s)

Nele Steinmetz

See Also

readSource()

Examples

## Not run: 
a <- readSource("IPCC", "awmsShr")
a <- readSource("IPCC", "awmsEfCh4")
a <- readSource("IPCC", "awmsParCh4")
a <- readSource("IPCC", "nExcrRate")

## End(Not run)

convertISIMIP

Description

convert data to ISO country level

Usage

convertISIMIP(x, subtype)

Arguments

x

MAgPIE object on cellular level

subtype

data subtype

Value

MAgPIE object on country level

Author(s)

Jan Philipp Dietrich, Felicitas Beier

See Also

readSource()

Examples

## Not run: 
a <- readSource("ISIMIP", convert = TRUE)

## End(Not run)

Convert JRC IDEES data

Description

Missing data for EU-28 countries is added, by distributing the difference of EU28 and the sum of country-values based on countries share in EU-28 GDP.

Usage

convertJRC_IDEES(x)

Arguments

x

A magpie object returned from readJRC_IDEES().

Value

A magpie object.

Author(s)

Michaja Pehl

See Also

readJRC_IDEES()


convertKoeppen

Description

Convert Koeppen climate zones on iso-country level

Usage

convertKoeppen(x, subtype = "iso")

Arguments

x

magpie object provided by the read function

subtype

Switch between different levels

Value

List of magpie objects with results on country level

Author(s)

Kristine Karstens

Examples

## Not run: 
readSource("Koeppen", subtype = "iso", convert = TRUE)

## End(Not run)

convertLassaletta2014

Description

converts the dataset of Lassaletta, L., G. Billen, B. Grizzetti, J. Angalde, and J. Garnier. 2014. 50 Year Trends in Nitrogen Use Efficiency of World Cropping Systems: The Relationship between Yield and Nitrogen Input to Cropland. Environmental Research Letters. into a dataset including all countries. Replacing Soviet Union by Russia and Yugoslavia by Serbia without detailed disaggregation.

Usage

convertLassaletta2014(x, subtype)

Arguments

x

data object that gets provided by wrapper function readSource

subtype

budget provides the nr cropland budgets, fert_to_cropland the share of inorganic fertilizers being applied to croplands

Value

Magpie object with results on country level.

Author(s)

Benjamin Leon Bodirsky

See Also

readLassaletta2014(), readSource()

Examples

## Not run: 
readSource("Lassaletta2014", convert = TRUE)

## End(Not run)

convertLotzeCampenBiofuel

Description

Converts the Data from Lotze Campen et al. 2014. to fit the common country list. Source: Lotze Campen et al. 2014. "Impacts of increased bioenergy demand on global food markets: an AgMIP economic model intercomparison" Agricultural Economics 45 (103-116). doi:10.1111/agec.12092.

Usage

convertLotzeCampenBiofuel(x)

Arguments

x

MAgPIE object to be converted

Value

A MAgPIE object containing future trends in first generation bioenergy demand in Petajoules as magpie object for each country for biodiesel and ethanol.

Author(s)

Ewerton Araujo

Examples

## Not run: 
x <- readSource("LotzeCampenBiofuel")

## End(Not run)

convertLutz2014

Description

It fills the missing values of the output of readLutz2014 through the weighted average of the values of two countries with similar characteristics to the one that has na values.

Usage

convertLutz2014(x)

Arguments

x

magpie object provided by the read function

See Also

readLutz2014()


Convert MAgPIE data

Description

Convert MAgPIE data to country-level.

Usage

convertMAgPIE(x, subtype)

Arguments

x

input MAgPIE data on region-level

subtype

Either "EmiAirPoll", "macBase", "co2tax", "supplyCurve_magpie_40", "abatparam_co2"

Value

magpie object

Author(s)

David Klein, Felix Schreyer


convertNCDrisc

Description

Converts data from the NCD risc consortium body height: Collaboration (NCD-RisC), NCD Risk Factor. 2016. "A Century of Trends in Adult Human Height." ELife 5 (July):e13410. https://doi.org/10.7554/eLife.13410.

Usage

convertNCDrisc(x, subtype)

Arguments

x

unconverted magpie object from read-script

subtype

"height" for body height data. Missing data is replaced by non-population weighted global average

Value

magpie object with a completed dataset.

See Also

convertNCDrisc()


Convert subtypes of the PBL_MACC_2019 data

Description

Convert subtypes from PBL_MACC_2019 to data on ISO country level.#'

Usage

convertPBL_MACC_2019(x, subtype)

Arguments

x

MAgPIE object containing PBL_MACC_2019 data on region level

subtype

data subtype. "ch4coal","ch4oil","ch4gas","ch4wstl","ch4wsts","ch4rice","ch4animals","ch4anmlwst", "n2otrans","n2oadac","n2onitac","n2ofert","n2oanwst","n2owaste", "HFC_tot", "SF6_tot", "PFC_tot" or "baseline_sources"

Value

PBL_MACC_2019 data as MAgPIE object for all subtypes aggregated to country level

Author(s)

Florian Humpenoeder

See Also

readSource()


Convert subtypes of the PBL_MACC_2022 data

Description

Convert subtypes from PBL_MACC_2022 to data on ISO country level.#'

Usage

convertPBL_MACC_2022(x)

Arguments

x

MAgPIE object containing PBL_MACC_2022 data on region level

Value

PBL_MACC_2022 data as MAgPIE object for all subtypes aggregated to country level

Author(s)

Michael Windisch, Florian Humpenoeder

See Also

readSource()


Convert subtypes of the PBL_MACC_SSP2_2022 data

Description

Convert subtypes from PBL_MACC_SSP2_2022 to data on ISO country level.#'

Usage

convertPBL_MACC_SSP2_2022(x)

Arguments

x

MAgPIE object containing PBL_MACC_SSP2_2022 data on region level

Value

PBL_MACC_SSP2_2022 data as MAgPIE object for all subtypes aggregated to country level

Author(s)

Michael Windisch, Florian Humpenoeder

See Also

readSource()


convertPRIMAPhist

Description

function to convert PRIMAP-hist data to isocountry resolution

Usage

convertPRIMAPhist(x)

Arguments

x

MAgPIE object

Value

MAgPIE object

Author(s)

Roman Popov

Examples

## Not run: 
readSource("PRIMAPhist", subtype = "hist")

## End(Not run)

convertResFor2ndBE

Description

Convert old ReMIND use of residues for 2nd generation bioenergy to country level data

Usage

convertResFor2ndBE(x, subtype = subtype)

Arguments

x

MAgPIE object containing original values

subtype

oldReMIND, newAgriSupply

Value

List of magpie objects with results on country level

Author(s)

Kristine Karstens

See Also

readSource()

Examples

## Not run: 
a <- readSource("ResFor2ndBE", subtype = "oldReMIND", convert = TRUE)

## End(Not run)

convertSoilGrids

Description

Convert SoilGrids content

Usage

convertSoilGrids(x)

Arguments

x

magpie object provided by the read function

Value

List of magpie objects with results on cellular level, weight, unit and description.

Author(s)

Kristine Karstens

See Also

readSoilGrids()

Examples

## Not run: 
readSource("SoilGrids", subtype = "cstock_0_30", convert = TRUE)

## End(Not run)

convertSSPResults

Description

Disagregates from SSP regions to ISO countries

Usage

convertSSPResults(x)

Arguments

x

object coming from read function

Value

MAgPIE object with ISO countries with all indicators for which disaggregation weight was found

Author(s)

Abhijeet Mishra, Benjamin Leon Bodirsky, Florian Humpenoeder

See Also

readSource()

Examples

## Not run: 
readSource("SSPResults", aggregate = TRUE)

## End(Not run)

convertVanDrecht2009

Description

Reads a dataset containing values for sewage

Usage

convertVanDrecht2009(x)

Arguments

x

MAgPIE object containing incomplete country-region resolution

Value

A MAgPIE object containing sewage quantities and losses

Author(s)

Benjamin Leon Bodirksy

Examples

## Not run: 
x <- readSource("VanDerWerf2010")

## End(Not run)

convertWHO

Description

Converts data from the WHO

Usage

convertWHO(x)

Arguments

x

unconverted magpie object from read-script

Value

magpie object with a completed dataset.

See Also

convertWHO()


correctAndrijevic2019

Description

correct Andrijevic governance data

Usage

correctAndrijevic2019(x, subtype)

Arguments

x

magpie object provided by the read function

subtype

data to be returned: "historical" for observed data until 2015 "projected" for projected SSP scenario data from 2015 to 2099

Value

corrected magpie object iso-level

Author(s)

Felicitas Beier

See Also

readAndrijevic2019()


correctEDGARfood

Description

correct Edgar-food data

Usage

correctEDGARfood(x, subtype)

Arguments

x

magpie object provided by the read function

subtype

Type of data that should be read

  • foodSystemEmi: Total food system emissions of different countries

  • foodSystemShare: Share of food system emissions in total emissions

  • foodSystemSector: Food system emissions separated by country, sector and substance

Value

corrected magpie object

Author(s)

David Hoetten

See Also

readEDGARfood


correctFoodSystemsDashboard

Description

Correct FoodSystemsDashboard values that are questionable

Usage

correctFoodSystemsDashboard(x, subtype)

Arguments

x

magpie object provided by the read function

subtype

Switch between different levels

Value

List of magpie objects

Author(s)

David Chen


correctIPCCClimate

Description

Correct IPCC climate classification

Usage

correctIPCCClimate(x)

Arguments

x

magpie object provided by the read function

Value

Magpie object with results on cellular level for 12 IPCC climate zone types

Author(s)

Kristine Karstens

Examples

## Not run: 
readSource("IPCCClimate", convert = "onlycorrect")

## End(Not run)

correctKoeppen

Description

Correct Koeppen climate zones on cellular level

Usage

correctKoeppen(x, subtype = "iso")

Arguments

x

magpie object provided by the read function

subtype

Switch between different levels

Value

List of magpie objects with results on cellular level

Author(s)

Kristine Karstens

Examples

## Not run: 
readSource("Koeppen", subtype = "cellular", convert = "onlycorrect")

## End(Not run)

correctSoilGrids

Description

Correct SoilGrids content

Usage

correctSoilGrids(x)

Arguments

x

magpie object provided by the read function

Value

List of magpie objects with results on cellular level, weight, unit and description.

Author(s)

Kristine Karstens

See Also

readSoilGrids()

Examples

## Not run: 
readSource("SoilGrids", subtype = "cstock_0_30", convert = "onlycorrect")

## End(Not run)

correctTNC2019

Description

correct biome data

Usage

correctTNC2019(x)

Arguments

x

magpie object provided by the read function

Value

magpie object on cellular level

Author(s)

Patrick v. Jeetze

See Also

readTNC2019

Examples

## Not run: 
readSource("TNC2019", convert = "onlycorrect")

## End(Not run)

downloadAndrijevic2019

Description

This function downloads the governance indicator data available at https://github.com/marina-andrijevic/governance2019

Usage

downloadAndrijevic2019(subtype = "governance_obs_project")

Arguments

subtype

file that should be downloaded from governance2019 repository

Author(s)

Felicitas Beier

See Also

readAndrijevic2019()

Examples

## Not run: 
downloadSource("Andrijevic2019", subtype = "governance_obs_project")

## End(Not run)

downloadEDGAR

Description

download EDGAR emission data

Usage

downloadEDGAR6(subtype = "n2o")

Arguments

subtype

type in gas for receiving the newest data. type in specific filename for old version 4.31 data

Value

List of magpie objects with results on cellular level, weight, unit and description.

Author(s)

Benjamin Leon Bodirsky


downloadEDGARfood

Description

download Edgar-food v6 food system emission data

Usage

downloadEDGARfood()

Author(s)

David Hötten


Download Eurostat Livestock Data

Description

Downloads the latest data and meta data form the Eurostat website.

Usage

downloadEurostatLivestock(subtype)

Arguments

subtype

Type of Eurostat Livestock data that should be read.


Download GFED

Description

Download the GFED (Global Fire Emissions Database) dataset for all years not labeled as beta, in addition to the emission factors.

Usage

downloadGFED()

Author(s)

Michael S. Crawford

See Also

downloadSource() readGFED()

Examples

## Not run: 
a <- downloadSource()

## End(Not run)

downloadGGCMICropCalendar

Description

Download ISIMIP GGCMI crop calendar information and harvest area masks

Usage

downloadGGCMICropCalendar()

Author(s)

David M Chen, Edna Molina Bacca


downloadIPCCClimate

Description

Download IPCC climate classification

Usage

downloadIPCCClimate()

Value

Meta information on downloaded data

Author(s)

Kristine Karstens

Examples

## Not run: 
readSource("IPCCClimate", convert="onlycorrect")

## End(Not run)

Download ISIMIP data

Description

Downloads the latest data from ISIMIP.

Usage

downloadISIMIP(subtype)

Arguments

subtype

Type of ISIMIP data that should be read. It consists of variable ("airrww"), model ("cwatm","h08","lpjml","matsiro","mpi-hm","pcr-globwb"), GCM ("ipsl-cm5a-lr","gfdl-esm2m","miroc5","hadgem2-es") and database version ("2a","2b","3a","3b"), separated by ":" (e.g. "airww:LPJmL:gfdl-esm2m:2b"). Similarly for ISIMIP GGCMI phase3b data, with scenarios and CO2 fert setting, downloads for all crops and irrigation settings models ("LPJmL", "EPIC-IIASA", "pDSSAT", "CYGMA1p74"), gcms ("gfdl-esm4", "ipsl-cm6a-lr", "mpi-esm1-2-hr", "mri-esm2-0", "ukesm1-0-ll"), scenarios ("historical", "ssp126", "ssp370", "ssp585"), co2 ("default", "2015co2"), version c("2a","2b","3a","3b"))) Example of yield subtype : "yields:EPIC-IIASA:ukesm1-0-ll:ssp585:default:3b"

Author(s)

Jan Philipp Dietrich


downloadNitrogenBoundariesGridded

Description

Download he grid-level regional nitrogen boundary datasets from Schulte-Uebbing et al. (2022)

Usage

downloadNitrogenBoundariesGridded()

Author(s)

Michael S. Crawford

See Also

downloadSource()

Examples

## Not run: 
 a <- downloadSource("NitrogenBoundariesGridded")

## End(Not run)

downloadSoilGrids

Description

This function downloads the raw SoilGrids data (available at https://files.isric.org/soilgrids/data/recent) or, if available, the preprocessed raster layers.

Usage

downloadSoilGrids(subtype = "cstock_0_30")

Arguments

subtype

Switch between different input. Use predefined ones or any FileName specified in 'SoilGrids/META_GEOTIFF_1B.csv'

Value

magpie object in cellular resolution

Author(s)

Kristine Karstens

See Also

readSoilGrids()

Examples

## Not run: 
downloadSource("SoilGrids", subtype = "carbon0_30")

## End(Not run)

Download UN_PopDiv

Description

Download UN_PopDiv dataset (World Population Prospects)

Usage

downloadUN_PopDiv()

Author(s)

Michael Crawford, Debbora Leip

See Also

downloadSource() readUN_PopDiv()

Examples

## Not run: 
a <- downloadSource()

## End(Not run)

readACCMIP

Description

Read in data from the Atmospheric Chemistry and Climate Model Intercomparison Project

Usage

readACCMIP(subtype = NULL)

Arguments

subtype

data subtype. available subtypes are:

  • nhx_1850

  • noy_1850

  • sox_1850

  • nhx_1980

  • noy_1980

  • sox_1980

  • nhx_2000

  • noy_2000

  • sox_2000

  • nhx_26_2030

  • nhx_45_2030

  • nhx_85_2030

  • noy_26_2030

  • noy_45_2030

  • noy_85_2030

  • sox_26_2030

  • sox_45_2030

  • sox_85_2030

  • nhx_26_2100

  • nhx_45_2100

  • nhx_85_2100

  • noy_26_2100

  • noy_45_2100

  • noy_85_2100

  • sox_26_2100

  • sox_45_2100

  • sox_85_2100

Value

magpie object of the ACCMIP data. Unit is t NO2-N per ha per year, or t NH3-N per ha per year,...

Author(s)

Roman Popov

See Also

readSource()

Examples

## Not run: 
a <- readACCMIP("ACCMIP", "nhx_2000")
a <- readACCMIP("ACCMIP", "sox_26_2030")

## End(Not run)

readAdjustGrassi2021

Description

Read in data from Grassi et al. 2021. Adjustement factors for emission in GtCO2 yr-1.

Usage

readAdjustGrassi2021(subtype)

Arguments

subtype

Either "data" or "weight"

Value

Adjustement factors or weight as MAgPIE object

Author(s)

Michael Windisch, Florian Humpenoeder

Examples

## Not run: 
readSource("AdjustGrassi2021", subtype = "data")

## End(Not run)

readAndrijevic2019

Description

read in governance index data from Andrijevic et al. 2019

Usage

readAndrijevic2019(subtype)

Arguments

subtype

data used from governance2019 repository

Value

governance index data at iso-country level

Author(s)

Felicitas Beier

See Also

readSource()

Examples

## Not run: 
a <- readSource("Andrijevic2019")

## End(Not run)

readBodirsky2018

Description

Reads in regression parameters estimated using mrregression, and reads in some scenario based on Bodirsky et al not yet published

Usage

readBodirsky2018(subtype = "bmi_shr")

Arguments

subtype

bmi_share, demand_regression, intake_regression or bodyheight_regression for the estimated regression paramters of different regressions. scenarios for scenario projections.

Value

magpie object

See Also

readNCDrisc()


readCarbonLTS

Description

Read-in an Long term carbon storage data for historical period.

Usage

readCarbonLTS(subtype)

Arguments

subtype

data subtype.

Value

magpie object of the FRA 2015 data

Author(s)

Abhijeet Mishra

See Also

readSource()

Examples

## Not run: 
a <- readSource("CarbonLTS", "Lauk_et_al")

## End(Not run)

readCEDS2021

Description

reads in emission data from the CEDS database

Usage

readCEDS2021()

Value

MAgPIE object

Author(s)

Benjamin Leon Bodirsky, David Klein


readCEDS2024

Description

reads in emission data from the CEDS database

Usage

readCEDS2024()

Value

MAgPIE object

Author(s)

Pascal Weigmann


Read EDGAR_LU

Description

Read-in EDGAR_LU csv file as magclass object

Usage

readEDGAR_LU(subtype = "CO2")

Arguments

subtype

emission type

Value

magpie object EDGAR_LU data

Author(s)

Florian Humpenoeder

See Also

readSource()

Examples

## Not run: 
a <- readSource(type = "EDGAR_LU")

## End(Not run)

readEDGAR6

Description

download EDGAR 5 and 6 emission data

Usage

readEDGAR6(subtype)

Arguments

subtype

type in gas

Value

List of magpie objects with results on country level, weight, unit and description.

Author(s)

Benjamin Leon Bodirsky, Michael S. Crawford


readEDGARfood

Description

read Edgar-food v6 food system emission data

Usage

readEDGARfood(subtype)

Arguments

subtype

Type of data that should be read

  • foodSystemEmi: Total food system emissions of different countries

  • foodSystemShare: Share of food system emissions in total emissions

  • foodSystemSector: Food system emissions separated by country, sector and substance

Value

A magpie object with foodsystem total emissions, emission shares or sector and substance specific emission, depending on subtype

Author(s)

David Hötten


readEDGAR_GHG

Description

read EDGAR GHG emission data

Usage

readEDGARghg()

Value

magpie objects of EDGAR historical emissions (MtCO2eq)

Author(s)

Pascal Weigmann

See Also

readSource


Read European Environment Agency (EEA) data

Description

Read-in European Environment Agency (EEA) data on ETS emissions as magclass object

Usage

readEEA_EuropeanEnvironmentAgency(subtype)

Arguments

subtype

data subtype. Either "ETS", "ESR", "total", "sectoral", "projections", or "projections-detailed"

Value

magpie object of European Environment Agency (EEA) ETS emissions (GtCO2)

Author(s)

Renato Rodrigues, Falk Benke, Robin Hasse

See Also

readSource

Examples

## Not run: 
a <- readSource(type = "EEA_EuropeanEnvironmentAgency", subtype = "ETS")

## End(Not run)

Read EU Reference Scenario

Description

Read EU Reference Scenario .xlsx file as magpie object

Usage

readEU_ReferenceScenario(subtype)

Arguments

subtype

data subtype. Either "techAssump.*", "2016" or "2020"

Value

magpie object of EU reference scenario data by country. Units follow REMIND report conventions and conversion factor is defined in EU_ReferenceScenario2REMIND.xlsx file.

Author(s)

Renato Rodrigues, Falk Benke, Robin Hasse

Examples

## Not run: 
test <- readSource("EU_ReferenceScenario", subtype = "2020", convert = FALSE)

## End(Not run)

Read Eurostat historical emissions (env_air_gge)

Description

Read-in Eurostat historical emissions csv files as magclass object

Usage

readEurostat(subtype = "emissions")

Arguments

subtype

'emissions' for original Eurostat emissions split, 'MACCemi' for MACC historical emissions, or 'sectorEmi' for sector specific emissions, or 'latest' for most up-to-date data

Value

magpie object of Eurostat historical emissions (MtCO2)

Author(s)

Renato Rodrigues

See Also

readSource

Examples

## Not run: 
a <- readSource(type = "Eurostat", subtype = "emissions")

## End(Not run)

Read EUROSTAT_livestock

Description

Read in EUROSTAT livestock data

Usage

readEurostatLivestock(subtype)

Arguments

subtype

Type of FAO data that should be read. Available types are:

  • EggPopProd : Production of eggs for consumption and number of laying hens

  • LayingHensPop : Laying hens population - annual data

  • PoultryPop : Poultry - annual data

  • PigPop : Pig population - annual data

  • BovinePop : Bovine population - annual data

  • Nuts2Pop : Animal populations by NUTS 2 regions

  • MeatProd : Meat production and foreign trade - head - monthly data

  • MilkNuts2Prod : Production of cow's milk on farms by NUTS 2 regions

  • MilkProd : Production and utilization of milk on the farm - annual data

Value

EUROSTAT livestock data as MAgPIE object

Author(s)

David Hötten

See Also

readSource()

Examples

## Not run: 
a <- readSource("EurostatLivestock", "MeatProd")

## End(Not run)

readExpertGuessSSPLivestockProduction

Description

Read the Expert Guesses for future Livestock Production for the SSP Scenarios

Usage

readExpertGuessSSPLivestockProduction(subtype)

Arguments

subtype

: Available subtypes are: ssp1 to 5 Data for the SSP Scenario

Value

magpie object containing the expert guesses

Author(s)

Stephen Wirth

See Also

readSource()

Examples

## Not run: 
a <- readSource("ExpertGuessSSPLivestockProduction","ssp1")

## End(Not run)

Read in regression coefficients for feed efficiency

Description

Read in csv file containing coefficients of non-linear regression analysis for the calculation of future feed efficiencies of feed baskets dependent on livestock productivity trends

Usage

readFeedEfficiencyReg()

Value

MAgPIE object containing regression coefficients

Author(s)

Isabelle Weindl

See Also

readSource()

Examples

## Not run: 
a <- readSource("FeedEfficiencyReg")

## End(Not run)

Read in data of FeedModel

Description

Read in csv files containing data on production system distribution and system-specific feed baskets from the FeedModel "MAgPIE_FEED"

Usage

readFeedModel(subtype = "FeedBaskets")

Arguments

subtype

Available subtypes: "ProdSysRatio", "FeedBaskets" and "FeedBasketsDetailed"

Value

magpie object of feed basket data

Author(s)

Isabelle Weindl

See Also

readSource()

Examples

## Not run: 
a <- readSource(type = "FeedModel", subtype = "FeedBaskets")

## End(Not run)

Read in regression coefficients for central feed shares

Description

Read in csv file containing coefficients of non-linear regression analysis for the calculation of future central feed shares in feed baskets dependent on livestock productivity trends

Usage

readFeedShareReg()

Value

MAgPIE object containing regression coefficients

Author(s)

Isabelle Weindl

See Also

readSource()

Examples

## Not run: 
a <- readSource("FeedShareReg")

## End(Not run)

readFoodSystemsDashboard

Description

read in Food Systems Dashboard indicators

Usage

readFoodSystemsDashboard(subtype)

Arguments

subtype

Currently either "Processed" for Processed food expenditures per capita or "Industrial Processing Share"

Value

governance index data at iso-country level

Author(s)

David Chen

See Also

readSource()

Examples

## Not run: 
a <- readSource("FoodSystemsDashboard")

## End(Not run)

Read parameters of Froehle equations

Description

Publication Froehle, Andrew W. 2008 "Climate Variables as Predictors of Basal Metabolic Rate: New Equations" American Journal of Human Biology: The Official Journal of the Human Biology Council 20 (5): 510-29. doi: 10.1002/ajhb.20769.

Usage

readFroehle()

Value

MAgPIE object

Author(s)

Benjamin Bodirsky

See Also

readSource()

Examples

## Not run: 
a <- readSource("Froehle")

## End(Not run)

Read GFED

Description

Read the Global Fire Emissions Database over the available years and store them in a MAgPIE object with two sub-dimensions: Species (e.g. DM, CO2, CH4, or N2O), and Partition (e.g. SAVA, BORF, TEMF, DEFO, PEAT, AGRI). Emissions are reported in Mt X. For more information, see: https://globalfiredata.org/pages/data/. Due to runtime considerations, this function only calculates a small sample of the total emissions (CH4, N2O, NOx, NH3) and burning partitions (AGRI), which are currently being used for validation.

Usage

readGFED()

Value

A MAgPIE object with the GFED emissions data and sub-dimensions Partition and Species.

Author(s)

Michael S. Crawford

See Also

readSource()

Examples

## Not run: 
a <- readSource("GFED")

## End(Not run)

readGGCMICropCalendar

Description

Reads in GGCMI fraction of Harvested Area masks for rice 1 and rice 2 (other crops available too, see path in download function), or other variables available in the GGCMI crop calendar.

Usage

readGGCMICropCalendar(subtype = "fraction_of_harvested_area")

Arguments

subtype

variable or vector of variables to read from the crop calendar set. Options: ("planting_day","maturity_day","fraction_of_harvested_area","cal" (which is a combination of planting_day, maturity_day and harvest_day)), wheat areas and rice_areas

Value

MAgPIE object with the requested data

Author(s)

David M Chen, Edna Molina Bacca


readGTAPv8v9

Description

Read in data from GTAP 8.1 baseyears 2007 and 2004. All values in mio. current US$MER.

Usage

readGTAPv8v9(subtype)

Arguments

subtype

GTAP version and header that should be read. Available versions are "81" and "9" Available headers are listed in the contents_xxx.csv in the GTAPv8v9 source folder for each GTAP file (BaseData.har, BaseRate.har, BaseView.har, CO2.har, gsdvole.har, GTAPSam.har, Sets.har, TStrade.har, and Default.prm - file is determined based on the header via a mapping and does not need to be specified).

Value

GTAP data as MAgPIE object

Author(s)

Debbora Leip, David M. Chen

Examples

## Not run: 
readSource("GTAPv8v9", subtype = "81:SF01")

## End(Not run)

readHerridge

Description

Reads a dataset containing values for biological nitrogen fixation in agricultural systems. Source: Herridge D. F., Peoples M. B., Boddey R. M.: Global inputs of biological nitrogen fixation in agricultural systems

Usage

readHerridge(subtype = NULL)

Arguments

subtype

a subtype for the calculation

Details

Availables Subtypes:

  • ndfa: National values for Plant associated fixation

  • freeliving: Global values for free living agents

Value

A MAgPIE object containting the share of Nr derived from

  • ndfa: fixation for each country and each commodity.

  • freeliving: fixation by free living agents

Author(s)

Stephen Wirth, Jan Philipp Dietrich

Examples

## Not run: 
x <- readSource("Herridge", "ndfa")
x <- readSource("Herridge", "freeliving", convert = F)

## End(Not run)

readHHS_USDA

Description

reads calory requirement for a standardized population from HHS & USDA. 2015. "2015-2020 Dietary Guidelines for Americans." 8. Dietary Guidelines for Americans. https://health.gov/dietaryguidelines/2015/resources/2015-2020_Dietary_Guidelines.pdf. Appendix 2

Usage

readHHS_USDA()

Value

Magpie object with results on global level.

Author(s)

Benjamin Leon Bodirsky

See Also

convertLassaletta2014(), readSource()


Read allometric coeffizients for residue to harvest translation

Description

Read-in a file containing the allometric coeffizients of MAgPIE crop types. Values are assembled from various literature sources, and the weighting and allocation is done in the spreadsheet crop_specifications_*.ods for different versions of the file

Usage

readHI()

Value

magpie object with the dimension crops and coeffizients

Author(s)

Benjamin Leon Bodrisky, Kristine Karstens

See Also

readSource()

Examples

## Not run: 
a <- readSource("HI")

## End(Not run)

readHoulton2018

Description

Read Houlton 2018 model on weathering of N from rocks

Usage

readHoulton2018()

Value

magpie object global resolution by landuse types in Mt of N weathered from rocks each year

Author(s)

David M Chen

Examples

## Not run: 
readSource("Houlton2018", convert = FALSE)

## End(Not run)

readICP2017

Description

Reads data of World Bank ICP round, downloaded from here: https://databank.worldbank.org/source/icp-2017

Usage

readICP2017(subtype = "per_cap_expMER")

Arguments

subtype

data subtype to be read in. Available subtypes are:

  • priceLevel Price level index (World = 100)

  • expRatio Expenditure component share of GDP (GDP = 100%)

  • exp_LCU Expenditure (local currency units, billions)

  • exp_MER Expenditure, market exchange rate-based (US$, billions)

  • exp_PPP Expenditure, PPP-based (US$, billions)

  • per_cap_expPPP Expenditure per capita, PPP-based (US$)

  • per_cap_expMER Expenditure per capita, market exchange rate-based (US$)

Value

magpie object of relative price levels (world = 100) or per capita expenditure (USD17 MER)

Author(s)

David M Chen

Examples

## Not run: 
a <- readSource("ICP2017", "per_cap_exp")

## End(Not run)

Read IEA

Description

Read-in an IEA csv file as magpie object

Usage

readIEA(subtype)

Arguments

subtype

data subtype. Either "EnergyBalances", "EnergyBalances-2023", or "Emissions".

  • "EnergyBalances": IEA energy balances until 2020 (incomplete 2021), data updated in Aug 2022, the current default for REMIND input data

  • "EnergyBalances-latest": IEA energy balances until 2022 (2023 incomplete), data updated in Sep 2024, currently used for comparisons only

Value

magpie object of the IEA

Author(s)

Anastasis Giannousakis, Lavinia Baumstark, Renato Rodrigues, Falk Benke

See Also

readSource()

Examples

## Not run: 
a <- readSource(type = "IEA", subtype = "EnergyBalances")

## End(Not run)

Read-in data from IEA End Uses and Efficiency Indicators Database

Description

Read-in data from IEA End Uses and Efficiency Indicators Database

Usage

readIEA_EEI()

Author(s)

Falk Benke


Read IFA

Description

Read-in IFA (International Fertilizer Association) data .xlsx file as magclass object

Usage

readIFA(subtype)

Arguments

subtype

Type of IFA data that should be read. Available types are:

  • consumption: read in fertilizer_consumption.xlsx data

  • production: read in fertilizer_production.xlsx data

Value

magpie object of the IFA data

Author(s)

Lavinia Baumstark

See Also

readSource()

Examples

## Not run: 
a <- readSource(type = "IFA", subtype = "consumption")

## End(Not run)

readIfBB

Description

reads data on historic bioplastic production from csv source: "Biopolymers facts and statistics 2021" page 58, Institute for Bioplastics and Biocomposites (IfBB)

Usage

readIfBB()

Value

data as MAgPIE object

Author(s)

Debbora Leip

Examples

## Not run: 
  readSource("HistBioplasticProd")

## End(Not run)

Read in ImageMacc Costcurves for different subtypes

Description

Read in ImageMacc Costcurves for different subtypes, which are based on a Paper fro Lucas et al 2007 (http://linkinghub.elsevier.com/retrieve/pii/S1462901106001316) Rows are removed, the dataframe is reshaped and numbers are replaced by descriptions.

Usage

readImageMacc(subtype)

Arguments

subtype

data subtype. Options are: "CH4_Energy_Industry", "CH4_Landuse", "N2O_Energy_Industry", "N2O_Landuse", "HFC_tot", "SF6_tot", "PFC_tot" or "baseline_sources"

Value

magpie object of the ImageMacc data

Author(s)

Nele Steinmetz

See Also

readSource()

Examples

## Not run: 
a <- readSource("ImageMacc", "CH4_Energy_Industry")
a <- readSource("ImageMacc", "CH4_Landuse")
a <- readSource("ImageMacc", "N2O_Energy_Industry")
a <- readSource("ImageMacc", "N2O_Landuse")
a <- readSource("ImageMacc", "HFC_tot")
a <- readSource("ImageMacc", "SF6_tot")
a <- readSource("ImageMacc", "PFC_tot")
a <- readSource("ImageMacc", "baseline_sources")

## End(Not run)

Read IMPACT3.2.2World_Price

Description

Read-in world prices data csv file as magclass object

Usage

readIMPACT3.2.2World_Price()

Value

magpie object of the world prices from the IMPACT model for different SSP scenarios

Author(s)

Mishko Stevanovic

See Also

readSource()

Examples

## Not run: 
a <- readSource(type = "IMPACT3.2.2World_Price")

## End(Not run)

Read in IPCC emissions

Description

Read in IPCC data:

  • Read in IPCC emissions from livestock and manure management. Source: IPCC Guidelines for National Greenhouse Gas Inventories (2006); Chapter 10: Emissions from Livestock and Manure Management.

  • Read in IPCC emissions from Lime and urea application. Source: IPCC Guidelines for National Greenhouse Gas Inventories (2006); Chapter 11: N2O Emissions from managed Soils and Co2 Emissions from Lime and Urea Application.

  • Read in IPCC efficiency factors for burning of residue. Source: IPCC Guidelines for Natinal Greenhouse Gas Inventories (2006); Chapter 02: Generic Methodologies applicable to multiple Land-use Categories.

  • Read in soil related stock change factors for carbon and manure parameterization. Source: IPCC Guidelines for National Greenhouse Gas Inventories (2006); Chapter 5: Cropland.

Usage

readIPCC(subtype)

Arguments

subtype

data subtype

Value

magpie object of the IPCC data

Author(s)

Nele Steinmetz, Stephen Wirth, Jan Philipp Dietrich, Kristine Karstens

See Also

readSource()

Examples

## Not run: 
a <- readSource("IPCC", "awmsShr")
a <- readSource("IPCC", "awmsEfCh4")
a <- readSource("IPCC", "awmsParCh4")
a <- readSource("IPCC", "nExcrRate")
a <- readSource("IPCC", "awmsconfef3", convert = FALSE)
a <- readSource("IPCC", "fracgasms", convert = FALSE)
a <- readSource("IPCC", "fraclossms", convert = FALSE)
a <- readSource("IPCC", "emissionfactors", convert = FALSE)
a <- readSource("IPCC", "rescombusteff", convert = FALSE)
a <- readSource("IPCC", "efnsoil", convert = FALSE)

## End(Not run)

readIPCCClimate

Description

Read IPCC climate classification

Usage

readIPCCClimate()

Value

Magpie object with results on cellular level for 12 IPCC climate zone types

Author(s)

Kristine Karstens

Examples

## Not run: 
readSource("IPCCClimate", convert = "onlycorrect")

## End(Not run)

readISIMIP

Description

Reads in ISIMIP data

Usage

readISIMIP(subtype = "airww:LPJmL:gfdl-esm2m:2b")

Arguments

subtype

Type of ISIMIP data that should be read. It consists of variable ("airrww"), model ("cwatm","h08","lpjml","matsiro","mpi-hm","pcr-globwb"), GCM ("ipsl-cm5a-lr","gfdl-esm2m","miroc5","hadgem2-es") and database version ("2a","2b","3a","3b"), separated by ":" (e.g. "airww:LPJmL:gfdl-esm2m:2b") Similaryly for ISIMIP GGCMI phase3b data, with scenarios and CO2 fert setting, downloads for all crops and irrigation settings models ("LPJmL", "EPIC-IIASA", "pDSSAT", "CYGMA1p74"), gcms ("gfdl-esm4", "ipsl-cm6a-lr", "mpi-esm1-2-hr", "mri-esm2-0", "ukesm1-0-ll"), scenarios ("historical", "ssp126", "ssp370", "ssp585"), co2 ("default", "2015co2"), version c("2a","2b","3a","3b"))) Example of yield subtype : "yields:EPIC-IIASA:ukesm1-0-ll:ssp585:default:3b"

Value

MAgPIE object with the requested data

Note

Values for years before 1961 will be ignored to reduce overall object size

Author(s)

Jan Philipp Dietrich, Felicitas Beier, David Chen

Examples

## Not run: 
readSource("ISIMIP", convert = TRUE)

## End(Not run)

Read JRC IDEES

Description

Read the IDEES data base from JRC #nolint

Usage

readJRC_IDEES(subtype)

Arguments

subtype

one of

  • 'Emission': read worksheets from the Emission Balance files

  • 'Energy': read worksheets from the Energy Balance files

  • 'Industry': read worksheets from the Industry files

  • 'Transport': read worksheets from the Transport files

  • 'MBunkers': read worksheets from the Bunkers files

  • 'Residential': read worksheets from the Residential files

  • 'Tertiary': read worksheets from the Tertiary (Services and Agriculture) files

Value

A magpie object.

Author(s)

Michaja Pehl, Falk Benke

See Also

readSource()


readKoeppen

Description

Read Koeppen climate zones on iso-country and cellular level

Usage

readKoeppen(subtype = "iso")

Arguments

subtype

Switch between different levels

Value

List of magpie objects with results on country or cellular level

Author(s)

Kristine Karstens

Examples

## Not run: 
readSource("Koeppen", subtype = "iso")

## End(Not run)

readLassaletta2014

Description

reads nitrogen budgets for a country dataset from Lassaletta, L., G. Billen, B. Grizzetti, J. Angalde, and J. Garnier. 2014. 50 Year Trends in Nitrogen Use Efficiency of World Cropping Systems: The Relationship between Yield and Nitrogen Input to Cropland. Environmental Research Letters.

Usage

readLassaletta2014(subtype = "budget")

Arguments

subtype

budget provides the nr cropland budgets, fert_to_cropland the sahre of inorganic fertilizers being applied to croplands

Value

Magpie object with results on country level.

Author(s)

Benjamin Leon Bodirsky, Felicitas Beier

See Also

convertLassaletta2014(), readSource()

Examples

## Not run: 
readSource("Lassaletta2014", subtype = "budget", convert = FALSE)

## End(Not run)

Read LotzeCampenBiofuel

Description

Read-in Future trends in first generation bioenergy demand from the publication Lotze Campen et al. 2014. "Impacts of increased bioenergy demand on global food markets: an AgMIP economic model intercomparison" Agricultural Economics 45 (103-116). doi:10.1111/agec.12092. from a .csv file to a magclass object

Usage

readLotzeCampenBiofuel()

Value

Future trends in first generation bioenergy demand in ExaJoule as magpie object

Author(s)

Ewerton Araujo

See Also

readSource()

Examples

## Not run: 
a <- readSource("LotzeCampenBiofuel")

## End(Not run)

readLutz2014

Description

It reads and clears the dataset of the global population projections by age, sex and education, available on the Wittgenstein Centre Data Explorer and published by Lutz, Butz and K. C. , 2014. "Population and human capital in the twenty-first century" Oxford University Press. From .csv file to a magclass object

Usage

readLutz2014()

Value

magpie object with the dataset downloaded. It contains missing values and it is possible to replace them with the function convertLutz2014.

See Also

convertLutz2014()


Read MAgPIE data

Description

Read-in MAgPIE data

Usage

readMAgPIE(subtype)

Arguments

subtype

Either "EmiAirPoll", "macBase" or "co2tax"

Value

magpie object

Author(s)

Julian Oeser

See Also

readSource()

Examples

## Not run: 
a <- readSource(type = "MAgPIE", subtype = "EmiAPExo")

## End(Not run)

readNCDrisc

Description

Reads in data from the NCD risc consortium body height: Collaboration (NCD-RisC), NCD Risk Factor. 2016. "A Century of Trends in Adult Human Height." ELife 5 (July):e13410. https://doi.org/10.7554/eLife.13410.

Usage

readNCDrisc(subtype)

Arguments

subtype

"height" for body height data

Value

magpie object with the dataset downloaded. It contains missing values and it is possible to replace them with the function convertNCDrisc

Author(s)

Benjamin Leon Bodirsky

See Also

convertNCDrisc()


readNitrogenBoundariesGridded

Description

Read the grid-level regional nitrogen boundary datasets from Schulte-Uebbing et al. (2022). For the moment, this only uses the critical N surplus in all agricultural land (arable + intensively managed grassland) in view of all thresholds simultaneously, measured in kg N per ha per yr.

Usage

readNitrogenBoundariesGridded()

Value

A MAgPIE object with the critical nitrogen surplus in kg N per ha per yr in 2010

Author(s)

Michael S. Crawford

See Also

readSource()

Examples

## Not run: 
 a <- readSource("NitrogenBoundariesGridded")

## End(Not run)

Read in PBL MAC curves from Harmsen_et_al_2019 for different subtypes

Description

Read in PBL MAC curves from Harmsen_et_al_2019 for different subtypes

Usage

readPBL_MACC_2019(subtype)

Arguments

subtype

data subtype. "ch4coal","ch4oil","ch4gas","ch4wstl","ch4wsts","ch4rice","ch4animals","ch4anmlwst", "n2otrans","n2oadac","n2onitac","n2ofert","n2oanwst","n2owaste", "HFC_tot", "SF6_tot", "PFC_tot" or "baseline_sources"

Value

magpie object of the PBL_MACC_2019 data

Author(s)

Florian Humpenoeder

See Also

readSource()


Read in PBL MAC curves from Harmsen_et_al_2022 for different subtypes and subsets

Description

Read in PBL MAC curves from Harmsen_et_al_2022 for different subtypes and subsets

Usage

readPBL_MACC_2022(subtype, subset)

Arguments

subtype

data subtype. "ch4coal","ch4oil","ch4gas","ch4wstl","ch4wsts","ch4rice","ch4animals","ch4anmlwst", "n2otrans","n2oadac","n2onitac","n2ofert","n2oanwst","n2owaste"

subset

data subset. "Default", "Optimistic", "Pessimistic"

Value

magpie object of the PBL_MACC_2022 data

Author(s)

Michael Windisch, Florian Humpenoeder

See Also

readSource()


Read in PBL MAC curves from Harmsen_et_al_2022 for different subtypes and subsets, using the baseline-dependent IMAGE SSP2 version

Description

Read in PBL MAC curves from Harmsen_et_al_2022 for different subtypes and subsets, using the baseline-dependent IMAGE SSP2 version

Usage

readPBL_MACC_SSP2_2022(subtype, subset)

Arguments

subtype

data subtype. "ch4coal","ch4oil","ch4gas","ch4wstl","ch4wsts","ch4rice","ch4animals","ch4anmlwst", "n2otrans","n2oadac","n2onitac","n2ofert","n2oanwst","n2owaste"

subset

data subset. "Default", "Optimistic", "Pessimistic"

Value

magpie object of the PBL_MACC_SSP2_2022 data

Author(s)

Michael Windisch, Florian Humpenoeder, Gabriel Abrahao

See Also

readSource()


readPRIMAPhist

Description

Read in an PRIMAP-hist data csv file as magclass object.

Usage

readPRIMAPhist(subtype)

Arguments

subtype

data subtype. available subtypes are:

  • hist

  • hist_no_ex

Value

magpie object of the PRIMAP-hist data.

Author(s)

Roman Popov

See Also

readSource()

Examples

## Not run: 
a <- readPRIMAPhist("PRIMAPhist", "hist")

## End(Not run)

readResFor2ndBE

Description

Read in old ReMIND use of residues for 2nd generation bioenergy and newly estimations

Usage

readResFor2ndBE(subtype)

Arguments

subtype

oldReMIND, newAgriSupply

Value

List of magpie objects with results on old ReMIND regions level

Author(s)

Kristine Karstens

See Also

readSource()

Examples

## Not run: 
a <- readSource("ResFor2ndBE", subtype = "oldReMIND")

## End(Not run)

Read parameters of Schofield equations

Description

University, United Nations. 2004. Human Energy Requirements: Report of a Joint FAO/WHO/UNU Expert Consultation: Rome, 17-24 October 2001. Vol. 1. Food & Agriculture Org. http://books.google.com/books?hl=en&lr=&id=8WW7LP5h6usC&oi=fnd&pg=PR3&dq=%22working+groups.+The+work+of+these+groups+preceded+the+expert+consultation+and+served+as%22+%22for+discussions+and+exchange+during+the+meeting.+Thanks+are+also+due+to+Dr+E.%22+&ots=8Fizk–Hr6&sig=ocPdelHKyX2_npUTh41zZRRHf68. #nolint

Usage

readSchofield()

Value

MAgPIE object

Author(s)

Benjamin Bodirsky

See Also

readSource()

Examples

## Not run: 
a <- readSource("Schofield")

## End(Not run)

readSoilGrids

Description

This function reads the raw SoilGrids data (available at https://files.isric.org/soilgrids/data/recent/OCSTHA_M_30cm_250m_ll.tif) or if available the preprocessed raster layers.

Usage

readSoilGrids(subtype)

Arguments

subtype

Switch between different input. Use predefined ones or any FileName specified in 'SoilGrids/META_GEOTIFF_1B.csv'

Value

magpie object in cellular resolution

Author(s)

Kristine Karstens

See Also

downloadSoilGrids()

Examples

## Not run: 
readSource("SoilGrids", subtype = "cstock_0_30")

## End(Not run)

readSSPResults

Description

Reads in a reporting mif file from the SSP scenario results

Usage

readSSPResults()

Value

MAgPIE object with regional aggregation of SSP regions, including all indicators

Author(s)

Abhijeet Mishra, Florian Humpenoeder

See Also

readSource()

Examples

## Not run: 
readSource("SSPresults", aggregate = FALSE)

## End(Not run)

readTNC2019

Description

Reads geospatial data from 'the nature conservancy' on ecoregions, major habitat types (MHT, or biome types) and biogeographic realms.

Usage

readTNC2019()

Value

Returns magpie object with a share of each spatial unit belonging to a biogeographic realm and major habitat type.

Author(s)

Patrick v. Jeetze

Examples

## Not run: 
readSource("TNC2019", convert = "onlycorrect")

## End(Not run)

Read Transport Costs

Description

Read in Transport Costs from GTAP

Usage

readTransportCostsGTAP()

Value

Transport Costs in USD

Author(s)

David Chen

See Also

readSource()

Examples

## Not run: 
a <- readSource(type = "TransportCostsGTAP")

## End(Not run)

readvanDrecht2009

Description

Reads a dataset containing values for sewage

Usage

readVanDrecht2009()

Value

A MAgPIE object containing sewage quantities and losses

Author(s)

Benjamin Leon Bodirksy

Examples

## Not run: 
x <- readSource("VanDerWerf2010")

## End(Not run)

readWBGEM

Description

read raw data of world commodity prices from the dataset of World Bank global economic monitor

Usage

readWBGEM()

Value

magpie object of global price of commodities

Author(s)

Xiaoxi Wang

See Also

readSource()

Examples

## Not run: 
readSource(type = "WBGEM")

## End(Not run)

Read WHO

Description

Read-in WHO (World health organization) data files as magpie object. The files contain information on physical inactivity

Usage

readWHO(subtype)

Arguments

subtype

Type of WHO data that should be read. Includes physical_inactivity_adults and physical_inactivity_underaged

Value

magpie object of the WHO data

Author(s)

Benjamin Bodirsky

See Also

readSource()

Examples

## Not run: 
a <- readSource(type = "WHO", subtype = "physical_activity_adults")

## End(Not run)

Read Nitrogen Use Efficiency Paramerst from Zhang et al 2015

Description

Publication: Zhang, Xin, Eric A. Davidson, Denise L. Mauzerall, Timothy D. Searchinger, Patrice Dumas, and Ye Shen. 2015. "Managing Nitrogen for Sustainable Development". Nature 528 (7580): 51–59. https://doi.org/10.1038/nature15743.

Usage

readZhang2015()

Value

MAgPIE object

Author(s)

Benjamin Leon Bodirsky

See Also

readSource()

Examples

## Not run: 
a <- readSource("Zhang2015", convert = FALSE)

## End(Not run)

toolAWMSScenarioCreation

Description

tool function to calculate the share of manure managed in different animal waste management systems in confinements.

Usage

toolAWMSScenarioCreation(name, startYear, categories, values, out)

Arguments

name

Name of the scenario

startYear

Year were prediction starts

categories

share of manure managed in different animal waste management systems

values

target values

out

contains historical data

Value

List of magpie objects with results on country level, weight on country level, unit and description.

Author(s)

Edna J. Molina Bacca

See Also

calcAWMSconfShr()


toolCalcIEAfromStructureMappingPEFE

Description

mapping IEA reported data to ReMIND-MAgPIE items

Usage

toolCalcIEAfromStructureMappingPEFE(data, structureMapping, subtype = "remind")

Arguments

data

data to map

structureMapping

mapping to use

subtype

remind (default), edge, pfu or magpie

Value

MAgPIE object with completed time dimensionality.

Author(s)

Anastasis Giannousakis, Lavinia Baumstark, Isabelle Weindl


toolPregnant

Description

extra intake kcal/day for pregnant women. The number of pregnant women is computed through the number of 0 year old children each year (Lutz dataset). According to Human energy requirments , Fao (Rome, 2004) , a woman requires an additional food of 845 kcal/day and 675 kcal/day of food on average furing her pregancy and lactation period respectively. According to Naegele?s rule, the mean gestation period is 280 days (40 weeks) and the lactation period 6 month (25 weeks).

Usage

toolPregnant(demo, reproductive)

Arguments

demo

demo is the population divided by sex male (M) , female (F) and both (B) and divided by 8 age classes: 0-4, 5-9, 10-14, 15-19, AG1 (20-29), AG2 (30-59), AG3(60-79), AG4(80+)

reproductive

reproductive age classes (on which the energy requiremetns for newborns are distributed)


Split Biomass into modern and traditional

Description

We assume that below a given GDP/cap level, all biomass is traditional and above a higher limit, all biomass is modern with a linear transition between the limits.

Usage

toolSplitBiomass(
  x,
  gdppop,
  split = "biomass",
  into = c("biotrad", "biomod"),
  dim = 3.1,
  limits = c(12300, 18500)
)

Arguments

x

MagPIE object including biomass data

gdppop

MagPIE object with GDP/cap data

split

character, name of item to split

into

character vector of length two with the names of the split items

dim

dimension of x with the item to split

limits

numeric vector of length two with the corresponding GDP/cap limits. The default values used to be 10k and 15k USD/cap converted from 2005 to 2017 dollars.

Value

MagPIE object including split biomass data

Author(s)

Robin Hasse