Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

huePosition

Munsell Hue Position for Soil Color Description


Description

Munsell hues are typically arranged from 5R to 5PB in Munsell soil color books. This function matches a vector of Munsell hues to the position in this arrangement of 29 hues.

Usage

huePosition(x, returnHues = FALSE)

Arguments

x

character vector of hues, e.g. '10YR'

returnHues

logical, should the unique set of Munsell hues used for ordering be returned? See details.

Details

This function is fully vectorized.

Value

A vector of integer hue positions is typically returned, of the same length and order as x. If returnHues is TRUE, then the hue names and ordering is returned and x is ignored.

Author(s)

D.E. Beaudette

References

https://www.nrcs.usda.gov/wps/portal/nrcs/detail/soils/ref/?cid=nrcs142p2_053569

See Also

Examples

# get hue ordering for setting levels of a factor
huePosition(x=NULL, returnHues=TRUE)

# get position of the '10YR' hue (7)
huePosition(x='10YR')

aqp

Algorithms for Quantitative Pedology

v1.29
GPL (>= 3)
Authors
Dylan Beaudette [aut, cre], Pierre Roudier [aut, ctb], Andrew Brown [aut, ctb]
Initial release
2021-04-05

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.