| Contents | Index |
varids = netcdf.inqVarIDs(ncid)
varids = netcdf.inqVarIDs(ncid) returns IDs of the all the variables in the group specified by ncid.
ncid |
Identifier of NetCDF file, returned by netcdf.create or netcdf.open, or of a NetCDF group, returned by netcdf.defGrp. |
varids |
Array containing identifiers of variables in a NetCDF file or group. |
This example opens the NetCDF sample file and gets the IDs of all the variables in a group.
ncid = netcdf.open('example.nc','NOWRITE');
gid = netcdf.inqNcid(ncid,'grid1');
varids = netcdf.inqVarIDs(gid);
netcdf.close(ncid);
This function corresponds to the nc_inq_varids function in the NetCDF library C API.
For copyright information, read the netcdfcopyright.txt and mexnccopyright.txt files.
netcdf | netcdf.inqDimIDs | netcdf.inqVarID

Explore how to use MATLAB to make advancements in engineering and science.
| © 1984-2012- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |