oce2ncdf() works by determining the class of its first argument, and then dispatching to an internal function, as appropriate.

oce2ncdf(x, varTable = NULL, ncfile = NULL, force_v4 = TRUE, debug = 0)

Arguments

x

an oce-class object. The subclass of this object determines which lower-level function oce2ncdf() calls, e.g. if x is of ctd class, then ctd2ncdf() is called.

varTable

character value indicating the variable-naming scheme to be used, which is passed to read.varTable() to set up variable names, units, etc.

ncfile

character value naming the output file. Use NULL for a file name to be created automatically (e.g. ctd.nc for a CTD object).

force_v4

logical value which controls the NetCDF file version during the nc_create step. The default here is TRUE, whereas the ncdf4-package defaults to FALSE (ensuring that the NetCDF file is compatible with NetCDF v3). Some features, including large data sizes, may require v4.

debug

integer, 0 (the default) for quiet action apart from messages and warnings, or any larger value to see more output that describes the processing steps.

Author

Dan Kelley and Clark Richards