nc.get.variable.list {ncdf4.helpers} | R Documentation |
Get a list of names of data variables
Description
Get a list of names of data variables.
Usage
nc.get.variable.list(f, min.dims = 1)
Arguments
f |
The file (an object of class |
min.dims |
The minimum number of dimensions a variable must have to be included. |
Details
This function returns the names of any data variables found in the file – that is, variables which are NOT dimension variables, dimension bounds variables, climatology bounds variables, coordinate variables, or grid mapping variables.
Optionally, one may require that the variables have a minimum number of dimensions; this can eliminate unwanted variables left in files.
Value
A character vector naming all of the data variables found.
Examples
## Get dimension axes from file by inferring them from dimension names
## Not run:
f <- nc_open("pr.nc")
var.list <- nc.get.variable.list(f)
nc_close(f)
## End(Not run)
[Package ncdf4.helpers version 0.3-6 Index]