hobo2nc_convert: Hobo Temperature Logger to netCDF conversion

View source: R/hobo2nc_convert.R

hobo2nc_convertR Documentation

Hobo Temperature Logger to netCDF conversion

Description

Hobo Temperature Logger to netCDF conversion

Usage

hobo2nc_convert(
  file,
  atm_corr_file = NA,
  latitude,
  longitude,
  deployment,
  destination = c("R:/Science/CESD/CESD_DataManagement/data_out/HOBO", "."),
  project_lead = "",
  project = "",
  cf_title = "Maritime Ecosystem and Ocean Science Hobo temperature logger data",
  cf_institute = c("BIO", "SABS"),
  cf_source =
    "Hobo temperature logger data collected as part of Fisheries and Oceans Canada (DFO) science activities in the Maritime region of Canada",
  cf_history = "",
  cf_references = "",
  cf_comment = "",
  cf_author = "Peter Kraska, CESD Divisional data Manager <Peter.Kraska@DFO-MPO.gc.ca>",
  cf_conventions = "CF-1.8",
  cf_calendar = "standard",
  creation_date = format(x = Sys.time(), tz = "GMT", format = "%FT%H:%M%SZ")
)

Arguments

file

A character string path to a Hobo temperatuer and pressure logger csv output file

atm_corr_file

(optional) if an atmospheric pressure correction Hobo temperature and pressure logger was deployed, list the character string path to the file here

latitude

(required to compute depth using the TEOS-10 algorithm, https://www.teos-10.org/pubs/gsw/html/gsw_z_from_p.html) Latitude of the Hobo Temperature and Presseure Logger

longitude

longitude in WGS84

deployment

Character string, how the temperature was deployed (e.g. "affixed to floating dock, 1m below water level.")

destination

an existing folder to save netCDF files to

project_lead

an optional field to add the project lead's name to the file global attributes

project

Character string indicating the funding source and or overarching project this data was collected as part of

cf_title

an optional field to add to the generated NetCDF file's global attributes (required for CF compliant NetCDF file creation). A succinct description of what is in the dataset.

cf_institute

an optional field to add to the generated NetCDF file's global attributes (required for CF compliant NetCDF file creation). Specifies where the original data was produced.

cf_source

an optional field to add to the generated NetCDF file's global attributes (required for CF compliant NetCDF file creation). The method of production of the original data. If it was model-generated, source should name the model and its version, as specifically as could be useful. If it is observational, source should characterize it (e.g., "surface observation" or "radiosonde").

cf_history

an optional field to add to the generated NetCDF file's global attributes (required for CF compliant NetCDF file creation). Provides an audit trail for modifications to the original data. Well-behaved generic netCDF filters will automatically append their name and the parameters with which they were invoked to the global history attribute of an input netCDF file. We recommend that each line begin with a timestamp indicating the date and time of day that the program was executed.

cf_references

an optional field to add to the generated NetCDF file's global attributes (required for CF compliant NetCDF file creation). Published or web-based references that describe the data or methods used to produce it.

cf_comment

an optional field to add to the generated NetCDF file's global attributes (required for CF compliant NetCDF file creation). Miscellaneous information about the data or methods used to produce it.

cf_author

an optional field to add to the generated NetCDF file's global attributes (required for CF compliant NetCDF file creation)

cf_conventions

an optional field to add to the generated NetCDF file's global attributes (required for CF compliant NetCDF file creation)

cf_calendar

an optional field to add to the generated NetCDF file's global attributes (required for CF compliant NetCDF file creation). Specifies the calendar used for time dimensions. (http://cfconventions.org/Data/cf-conventions/cf-conventions-1.10/cf-conventions.html#calendar)

creation_date

creation date to append to the global attributes of the NetCDF file

Value

hobo2nc_convert() creates netCDF files from castaway CTD CSV files

Examples

hobo2nc_convert("data/")


pkraska/CESD documentation built on Aug. 26, 2024, 5:37 a.m.