ncatt_put_all: Put several attributes to a ncdf object

View source: R/nctools-auxiliar.R

ncatt_put_allR Documentation

Put several attributes to a ncdf object

Description

Put several attributes to a ncdf object

Usage

ncatt_put_all(
  nc,
  varid,
  attname,
  attval,
  prec = NA,
  verbose = FALSE,
  definemode = FALSE
)

Arguments

nc

An open connection to a netCDF file as in nc_open(file).

varid

The variable whose attribute is to be written. Can be a character string with the variable's name, an object of class ncvar4, or an id contained in the "id" field of a ncvar object. As a special case, if varid==0, then a global attribute is written instead of a variable's attribute.

attname

The names of the attributes.

attval

The values of the attributes.

prec

Precision to write the attribute.

verbose

Can be set to TRUE if additional information is desired while the attribute is being created.

definemode

See 'definemode' in ncatt_put for details.


roliveros-ramos/nctools documentation built on Aug. 13, 2022, midnight