simplifyGtypes {sarp.snowprofile} | R Documentation |
Simplify detailed grain types to parent classes
Description
The IACS records grain types in major and minor classes, e.g. precipitation particles PP can be subclassified into stellar dendrites PPsd. Some of these subclasses are not supported in this R package and so this function simplifies the unsupported gran type subclasses into their supported main classes. If a given grain type cannot be simplified, a NA value is returned for it.
Usage
simplifyGtypes(gtypes, supported_gtypes = grainDict$gtype)
Arguments
gtypes |
an array of character grain types following IACS standards |
supported_gtypes |
an array of supported grain types that will determine the simplification |
Value
the modified input array
Author(s)
fherla
Examples
## create an array of gtypes
gtypes <- c('FCxr', 'RGxf', 'PPsd', 'PP', 'IFrc', "KKfx")
## sinplify gtypes to supported_gtypes:
simplifyGtypes(gtypes)
[Package sarp.snowprofile version 1.3.2 Index]