module NumRu::GPhys::NetCDF_Convention_Users_Guide

(To be written.)

module NumRu::GPhys::NetCDF_IO

a NetCDF read/write helper by automatically interpreting conventions

Module functions

is_a_NetCDF?(filename)

test whether the file is a NetCDF file.

ARGUMENTS

RETURN VALUE

open(files, varname)

a GPhys constructor from a NetCDF file (or multiple NetCDF files).

ARGUMENTS

RETURN VALUE

EXAMPLES

write(file, gphys, name=nil)

Write a GPhys into a NetCDF file. The whole data under the GPhys (such as coordinate vars) are written self-descriptively.

ARGUMENTS

RETURN VALUE

write_grid(file, grid_or_gphys)

Same as write but for writing only the contents of the grid. (Used in write.)

ARGUMENTS

RETURN VALUE

each_along_dims_write(gphyses, files, *loopdims){...} # a block is expected

Iterator to process GPhys objects too big to read on memory at once. Makes a loop (loops) by dividing the GPhys object(s) (gphyses) with the dimension(s) specified by loopdims, and the results (which is the return value of the block) are written in files.

ARGUMENTS

RETURN VALUE

ERRORS

The following raise exceptions (in adition to errors in arguments).

USAGE

set_convention(convention)

Set a NetCDF convention to be interpreted.

ARGUMENTS

RETURN VALUE

convention

Returns the current NetCDF convention to be interpreted.

RETURN VALUE

var_names(file)

ARGUMENTS

RETURN VALUE

var_names_except_coordinate(file)

ARGUMENTS

RETURN VALUE