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.
>To: address@hidden >cc: address@hidden >From: address@hidden (Carrie Gonzalez) >Subject: CDL files >Organization: Southwest Research Institute >Keywords: 199704232023.OAA12420 > > I have what may be a naive question concerning the use of netCDF. Are > CDL files needed? I am coming off a task whereby we used CDF and with > that software, we were advised it would be advantageous to create the > ASCII skeleton files, complete with attributes but no data, then create > the binary CDF file from that, and then simply fill in the data values. > > I see you have CDL files, which are ASCII, and the two utility functions > to go between the ASCII and the binary. Does the approach used for CDF > hold true for netCDF? Or is it simply enough to use the C functions > to create and fill the netCDF binary file as we process? CDL files are not necessary; you can just use C functions to create netCDF files. CDL files can be convenient. For example, the ncgen utility with a "-c" option generates the C necessary to create a netCDF file with structure specified by CDL. _____________________________________________________________________ Russ Rew UCAR Unidata Program address@hidden http://www.unidata.ucar.edu