| bounds | R Documentation |
CF-compliant netCDF files store time information as a single offset value for
each step along the dimension, typically centered on the valid interval of
the data (e.g. 12-noon for day data). Optionally, the lower and upper values
of the valid interval are stored in a so-called "bounds" variable, as an
array with two rows (lower and higher value) and a column for each offset.
With function bounds()<- those bounds can be set for a CFTime instance.
The bounds can be retrieved with the bounds() function.
bounds(x, format)
bounds(x) <- value
x |
A |
format |
Optional. A single string with format specifiers, see
|
value |
A |
If bounds have been set, an array of bounds values with dimensions
(2, length(offsets)). The first row gives the lower bound, the second row
the upper bound, with each column representing an offset of x. If the
format argument is specified, the bounds values are returned as strings
according to the format. NULL when no bounds have been set.
t <- CFtime("days since 2024-01-01", "standard", seq(0.5, by = 1, length.out = 366))
as_timestamp(t)[1:3]
bounds(t) <- rbind(0:365, 1:366)
bounds(t)[, 1:3]
bounds(t, "%d-%b-%Y")[, 1:3]
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.