CropareaDiversityIndex: CropareaDiversityIndex

View source: R/CropareaDiversityIndex.R

CropareaDiversityIndexR Documentation

CropareaDiversityIndex

Description

calculates an index that measures the croparea diversity

Usage

CropareaDiversityIndex(
  gdx,
  index = "shannon",
  level = "reg",
  measurelevel = "cell",
  groupdiv = "agg1",
  dir = "."
)

Arguments

gdx

GDX file

index

can be "shannon", "gini" or "invsimpson" for different types of diversitiy indices

level

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

measurelevel

level at which diversity is measured. "cell" means diversity

groupdiv

should crop groups be split up into several individual items or not? Choose either FALSE or different (dis)aggregation methods "agg1", "agg2"

dir

for gridded outputs: magpie output directory which contains a mapping file (rds) for disaggregation is measured at cellular level, even if lateron average diversity is aggregated to regional level.

Value

MAgPIE object (unit depends on attributes)

Author(s)

Benjamin Leon Bodirsky

See Also

CropareaDiversityIndex

Examples

## Not run: 
x <- CropareaDiversityIndex(gdx)

## End(Not run)


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