extractunit: Determine which unit in a list a string matches

Description Usage Arguments

Description

Match a string one by one against a list of allowed values. Return the one that matched, or NULL (with warning) if none of them was matched.

Usage

1
extractunit(unitlist, unitstr, type)

Arguments

unitlist

List of allowed units (e.g., the column names of a conversion matrix).

unitstr

The string to match against the allowed units

type

The type of unit we were trying to match (used to create warning messages).


JGCRI/gcamrpt documentation built on June 30, 2019, 8:41 a.m.