as.unit {oce} | R Documentation

## Convert a String to a Unit

### Description

Convert a String to a Unit

### Usage

    as.unit(u, default = list(unit = expression(), scale = ""))

### Arguments

`u` | A character string indicating a variable name. The following names are recognized: `"DBAR"`, `"IPTS-68"`, `"ITS-90"`, `"PSS-78"`, and `"UMOL/KG"`. All other names yield a return value equal to the value of the `default` argument.
`default` | A default to be used for the return value, if `u` is not a recognized string.

### Details

This function is not presently used by any `oce` functions, and is provided as a convenience function for users.

### Value

A list with elements `unit`, an `expression`, and `scale`, a string.

[Package oce version 0.9-22 Index]