Set something in the
data slot of an
String indicating the name of the item to be set.
Value for the item.
An optional indication of the units for the item. This has three possible forms (see “Details”).
Optional character string giving an 'original' name (e.g. as stored in the header of a data file).
A note to be stored in the processing log. If an empty string
(the default) then an entry will be constructed from the function call. If
There are three possibilities for
unit is a named or unnamed
that contains two items.
If the list is named, the names must be
scale. If the list is unnamed, the stated names are assigned
to the items, in the stated order. Either way, the
item must be an
expression that specifies the unit,
scale item must be a string that describes the scale. For
example, modern temperatures have
unit is an
expression giving the unit as above. In this
case, the scale will be set to
unit is a character string that is converted
into an expression with
and the scale set to
1 2 3 4 5 6 7
data(ctd) Tf <- swTFreeze(ctd) ctd <- oceSetData(ctd, "freezing", Tf, list(unit=expression(degree*C), scale="ITS-90")) feet <- swDepth(ctd) / 0.3048 ctd <- oceSetData(ctd, name="depthInFeet", value=feet, expression("feet")) fathoms <- feet / 6 ctd <- oceSetData(ctd, "depthInFathoms", fathoms, "fathoms")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.