[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: 970107: how to change data in a variable

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.


  • Subject: Re: 970107: how to change data in a variable
  • Date: Tue, 07 Jan 1997 12:58:27 -0700

> From: "R. Bauer" <address@hidden>
> To: address@hidden
> Subject: Re: 970107: how to change data in a variable

Hi,

> Is it possible to delete a parameter like an attribute?

No, netCDF attributes may be deleted, but variables and dimensions can't.

The reasons for this difference include:

 - attributes are in-memory structures (after a file is opened)
   typically much smaller than variables in the file, so garbage
   collection is not necessary when an attribute is deleted;

 - attributes are referred to by name rather than by ID, but deleting a
   variable or dimension would require that subsequent IDs change (by
   subtracting 1)

 - attributes have no associated dimensions or attributes, so deleting
   one doesn't affect other netCDF objects.

More detailed descriptions of the netCDF data model and the differences
between variables and attributes are available in the netCDF User's
Guide, and on-line at:

  http://www.unidata.ucar.edu/packages/netcdf/guide_toc.html

Please send netCDF questions to the address@hidden email
address.  That way your questions will be answered even if I happen to
be away from my email.  Thanks!

--Russ

_____________________________________________________________________

Russ Rew                                         UCAR Unidata Program
address@hidden                     http://www.unidata.ucar.edu