yields: yields

View source: R/yields.R

yieldsR Documentation

yields

Description

Calculates crop yields based on a MAgPIE gdx file

Usage

yields(
  gdx,
  file = NULL,
  level = "reg",
  products = "kcr",
  product_aggr = F,
  attributes = "dm",
  water_aggr = T
)

Arguments

gdx

GDX file

file

a file name the output should be written to using write.magpie

level

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

products

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

product_aggr

aggregate over products or not (boolean)

attributes

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

water_aggr

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

Value

crop yield as MAgPIE object (unit depends on attributes)

Author(s)

Florian Humpenoeder

See Also

reportYields

Examples


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


pik-piam/magpie4 documentation built on Dec. 20, 2024, 1:59 p.m.