View source: R/unit.conversions.R
validDim | R Documentation |
Determine whether a 1D dimension string is known and of the expected dimension type
validDim(dimstr, dim.type = c("ANY", "volume", "time", "mass", "count",
"area"))
dimstr |
A string representing one units dimension (just one at a time, please). For example: kg, d, or m^3, but not kg/d or d^-1 |
dim.type |
One or more acceptable dimension types |
loadflex:::validDim('kg') # TRUE
loadflex:::validDim('kg', 'mass') # TRUE
loadflex:::validDim('kg', 'volume') # FALSE
loadflex:::validDim('whoknows') # FALSE
loadflex:::validDim('whoknows', 'time') # FALSE
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.