write2ncdf4.station | R Documentation |
Method to save station data as netCDF, making sure to include the data
structure and meta-data (attributes). The code tries to follow the netCDf
'CF' convention. The method is built on the ncdf4
package.
## S3 method for class 'station'
write2ncdf4(
x,
...,
file = "station.nc",
prec = "short",
offset = 0,
missval = -99,
it = NULL,
stid = NULL,
append = FALSE,
scale = 0.1,
torg = "1899-12-31",
stid_unlim = FALSE,
namelength = 24,
nmin = 30,
verbose = FALSE,
doi = "NA",
namingauthority = "NA",
processinglevel = "NA",
creatortype = "NA",
creatoremail = "NA",
institution = "NA",
publishername = "NA",
publisheremail = "NA",
publisherurl = "NA",
project = "NA",
nspc = 100,
start = "Jan"
)
x |
data object |
... |
additional arguments |
file |
file name |
prec |
Precision: see |
offset |
Sets the attribute 'add_offset' which is added to the values stored (to save space may be represented as 'short'). |
missval |
Missing value: see |
it |
a time index, see |
stid |
station id |
append |
a Boolean; if TRUE append output to existing file - not used currently |
scale |
Sets the attribute 'scale_factor' which is used to scale (multiply) the values stored (to save space may be represented as 'short'). |
torg |
Time origin |
stid_unlim |
a Boolean; if TRUE the stid dimension is unlimited |
namelength |
a numeric specifying the number of characters in dimension and variable names |
nmin |
Only calculate summary statistics for stations with nmin years of data (e.g. 30 years). |
verbose |
TRUE - clutter the screen. |
doi |
- Data ID. All the following arguments are meant to accommodate for the convention described at https://adc.met.no/node/4 |
namingauthority |
The organization that provides the initial id (see above) for the dataset (see https://adc.met.no/node/4). |
processinglevel |
A textual description of the processing (or quality control) level of the data. (see https://adc.met.no/node/4). |
creatortype |
Specifies type of creator with one of the following: 'person', 'group', 'institution', or 'position'. If this attribute is not specified, the creator is assumed to be a person. (see https://adc.met.no/node/4). |
creatoremail |
The email address of the person (or other creator type specified by the creator_type attribute) principally responsible for creating this data. (see https://adc.met.no/node/4). |
institution |
The name of the institution principally responsible for originating this data. (see https://adc.met.no/node/4). |
publishername |
The name of the person (or other entity specified by the publisher_type attribute) responsible for publishing the data file or product to users, with its current metadata and format. (see https://adc.met.no/node/4). |
publisheremail |
The email address of the person (or other entity specified by the publisher_type attribute) responsible for publishing the data file or product to users, with its current metadata and format. (see https://adc.met.no/node/4). |
publisherurl |
The URL of the person (or other entity specified by the publisher_type attribute) responsible for publishing the data file or product to users, with its current metadata and format. (see https://adc.met.no/node/4). |
project |
The name of the project(s) principally responsible for originating this data. (see https://adc.met.no/node/4). |
nspc |
The size of chunks of data processes sequentially in order to limit the need of computer memory. Smaller number requires less memory. |
start |
specifies the start month of the year (default is January) |
To save space, the values are saved as short (16-bit signed integer that can hold values between -32768 and 32767). (see NC_SHORT in https://www.unidata.ucar.edu/software/netcdf/docs/data_type.html).
None
write2ncdf4
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.