ResidueUsage: ResidueUsage

View source: R/ResidueUsage.R

ResidueUsageR Documentation

ResidueUsage

Description

reads Crop Residue Usage out of a MAgPIE gdx file

Usage

ResidueUsage(
  gdx,
  level = "reg",
  dir = ".",
  products = "kcr",
  product_aggr = FALSE,
  attributes = "dm",
  water_aggr = TRUE,
  spamfiledirectory = ""
)

Arguments

gdx

GDX file

level

Level of regional aggregation; "reg" (regional), "glo" (global), "regglo" (regional and global) or any other aggregation level defined in superAggregate

dir

for gridded outputs: magpie output directory which contains a mapping file (rds) for disaggregation

products

Selection of products (either by naming products, e.g. "tece", or naming a set,e.g."kcr")

product_aggr

aggregate over products or not. Usually boolean, but here also the value "kres" is allowed, which provides kcr aggregated to kres

attributes

dry matter: Mt ("dm"), gross energy: PJ ("ge"), reactive nitrogen: Mt ("nr"), phosphor: Mt ("p"), potash: Mt ("k"), wet matter: Mt ("wm"). Can also be a vector.

water_aggr

aggregate irrigated and non-irriagted production or not (boolean).

spamfiledirectory

deprecated. please use dir instead

Value

production as MAgPIE object (unit depends on attributes)

Author(s)

Kristine Karstens, Michael Crawford

See Also

ResidueBiomass

Examples


  ## Not run: 
    x <- ResidueUsage(gdx)
  
## End(Not run)


pik-piam/magpie4 documentation built on May 7, 2024, 11:13 p.m.