This archive contains answers to questions sent to Unidata support through mid-2025. Note that the archive is no longer being updated. We provide the archive for reference; many of the answers presented here remain technically correct, even if somewhat outdated. For the most up-to-date information on the use of NSF Unidata software and data services, please consult the Software Documentation first.
------- Forwarded Message Date: Thu, 01 Nov 2001 14:26:10 -0700 From: Russ Rew <address@hidden> To: "Glenn Rutledge" <address@hidden> Subject: Re: 20011031: Make Install err w/ netCDF >To: Russ Rew <address@hidden> >From: "Glenn Rutledge" <address@hidden> >Subject: Make Install err w/ netCDF >Organization: NCDC >Keywords: 200110312009.f9VK9k117932, Fortran90, module files Glenn, > I want to extract a certain variable form the model and write it out in > ascii. Can > this be done in the standard issue netCDF package or must I have NCO. (it > looks > like NCO is nice however). Yes, you can use ncdump, which is a utility that is part of the netCDF package. To extract the variable "var" and see its values in ascii, from the netcdf file "foo.nc": ncdump -v var foo.nc You can also get annotated values that include comments specifying the indices for the values using the ncdump options -b or -f (for brief or full annotations). If you just want the "header" information, try ncdump -h foo.nc which will give you all the declarations but none of the data. If you want that plus the coordinate variable values, use ncdump -c foo.nc --Russ ------- End of Forwarded Message