NCEPLIBS-ncio
1.0.0
|
writing requires a template file. More...
Functions/Subroutines | |
subroutine, public | close_dataset (dset, errcode) |
Close a netcdf file, deallocate members of dataset object. More... | |
type(dataset) function, public | create_dataset (filename, dsetin, copy_vardata, paropen, nocompress, mpicomm, errcode) |
Create new dataset, using an existing dataset object to define. More... | |
type(dimension) function, public | get_dim (dset, dimname) |
Get Dimension object given name. More... | |
integer function, dimension(6), public | get_idate_from_time_units (dset) |
return integer array with year,month,day,hour,minute,second parsed from time units attribute. More... | |
integer function, public | get_ndim (dset, dimname) |
Get Dimension index given name. More... | |
integer function, public | get_nvar (dset, varname) |
Get Variable index given name. More... | |
character(len=nf90_max_name) function, public | get_time_units_from_idate (idate, time_measure) |
create time units attribute of form 'hours since YYYY-MM-DD HH:MM:SS' from integer array with year,month,day,hour,minute,second optional argument 'time_measure' can be used to change 'hours' to 'days', 'minutes', 'seconds' etc. More... | |
type(variable) function, public | get_var (dset, varname) |
Get Variable object given name. More... | |
logical function, public | has_attr (dset, attname, varname) |
logical function, public | has_var (dset, varname) |
type(dataset) function, public | open_dataset (filename, errcode, paropen, mpicomm) |
Open existing dataset, create dataset object for reading netcdf file. More... | |
writing requires a template file.
Handles 32 and 64 bit real variables, 8, 16 and 32 bit integer variables and char variables. Variables can have up to 5 dimensions.
subroutine, public module_ncio::close_dataset | ( | type(dataset), intent(inout) | dset, |
integer, intent(out), optional | errcode | ||
) |
Close a netcdf file, deallocate members of dataset object.
if optional error return code errcode is not specified, program will stop if a nonzero error code returned by the netcdf lib.
filename | filename for netCDF Dataset. |
errcode | optional error return code. If not specified the program will stop if a nonzero error code returned by the |
Definition at line 845 of file module_ncio.f90.
type(dataset) function, public module_ncio::create_dataset | ( | character(len=*), intent(in) | filename, |
type(dataset), intent(in) | dsetin, | ||
logical, intent(in), optional | copy_vardata, | ||
logical, intent(in), optional | paropen, | ||
logical, intent(in), optional | nocompress, | ||
integer, intent(in), optional | mpicomm, | ||
integer, intent(out), optional | errcode | ||
) |
Create new dataset, using an existing dataset object to define.
Variables, dimensions and attributes.
filename | filename for netCDF Dataset. |
dsetin | dataset object to use as a template. |
copyvardata | optional flag to control whether all variable data is copied (Default is .false., only coordinate variable data is copied). |
errcode | optional error return code. If not specified the program will stop if a nonzero error code returned by the netcdf lib. |
paropen | optional flag to indicate whether to open dataset for parallel access (Default .false.) |
nocompress | optional flag to disable compression even if input dataset is compressed (Default .false.). |
mpicomm | optional MPI communicator to use (Default MPI_COMM_WORLD) ignored if paropen=F |
Definition at line 506 of file module_ncio.f90.
type(dimension) function, public module_ncio::get_dim | ( | type(dataset) | dset, |
character(len=*), intent(in) | dimname | ||
) |
Get Dimension object given name.
dset | the dataset |
dimname | the dimension name |
Definition at line 189 of file module_ncio.f90.
integer function, dimension(6), public module_ncio::get_idate_from_time_units | ( | type(dataset), intent(in) | dset | ) |
return integer array with year,month,day,hour,minute,second parsed from time units attribute.
Definition at line 1346 of file module_ncio.f90.
integer function, public module_ncio::get_ndim | ( | type(dataset), intent(in) | dset, |
character(len=*), intent(in) | dimname | ||
) |
Get Dimension index given name.
Dimension object can then be accessed via Datasetdimensions(nvar)
dset | the dataset |
dimname | the dimension name |
Definition at line 205 of file module_ncio.f90.
integer function, public module_ncio::get_nvar | ( | type(dataset), intent(in) | dset, |
character(len=*), intent(in) | varname | ||
) |
Get Variable index given name.
dset | the dataset |
varname | the variable name |
Definition at line 288 of file module_ncio.f90.
character(len=nf90_max_name) function, public module_ncio::get_time_units_from_idate | ( | integer, dimension(6), intent(in) | idate, |
character(len=*), intent(in), optional | time_measure | ||
) |
create time units attribute of form 'hours since YYYY-MM-DD HH:MM:SS' from integer array with year,month,day,hour,minute,second optional argument 'time_measure' can be used to change 'hours' to 'days', 'minutes', 'seconds' etc.
Definition at line 1373 of file module_ncio.f90.
type(variable) function, public module_ncio::get_var | ( | type(dataset) | dset, |
character(len=*) | varname | ||
) |
Get Variable object given name.
dset | the dataset |
varname | the variable name |
Definition at line 224 of file module_ncio.f90.
logical function, public module_ncio::has_attr | ( | type(dataset) | dset, |
character(len=*) | attname, | ||
character(len=*), optional | varname | ||
) |
dset | |
attname | the attribute name |
varname | the variable name |
Definition at line 258 of file module_ncio.f90.
logical function, public module_ncio::has_var | ( | type(dataset) | dset, |
character(len=*) | varname | ||
) |
dset | the dataset |
varname | the variable name |
Definition at line 238 of file module_ncio.f90.
type(dataset) function, public module_ncio::open_dataset | ( | character(len=*), intent(in) | filename, |
integer, intent(out), optional | errcode, | ||
logical, intent(in), optional | paropen, | ||
integer, intent(in), optional | mpicomm | ||
) |
Open existing dataset, create dataset object for reading netcdf file.
filename | filename of netCDF Dataset. |
errcode | optional error return code. If not specified the program will stop if a nonzero error code returned by the netcdf lib. |
paropen | optional flag to indicate whether to open dataset for parallel access (Default .false.) |
mpicomm | optional MPI communicator to use (Default MPI_COMM_WORLD) ignored if paropen=F |
Definition at line 358 of file module_ncio.f90.