[[.CFDataset | R Documentation |
This method can be used to retrieve a variable or axis from the data set by name.
## S3 method for class 'CFDataset'
x[[i]]
x |
An |
i |
The name of a variable or axis in |
If the data set has groups, the name i
of the variable or axis should be
fully qualified with the path to the group where the object is located. This
fully qualified name can be retrieved with the names()
and dimnames()
functions, respectively.
An instance of CFVariable
or an CFAxis
descendant class, or
NULL
if the name is not found.
fn <- system.file("extdata", "ERA5land_Rwanda_20160101.nc", package = "ncdfCF")
ds <- open_ncdf(fn)
v1 <- names(ds)[1]
var <- ds[[v1]]
var
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.