pressure_conversion_station: Daily surface and mean sea level pressure conversion for CDT...

View source: R/cdtClimate_pressure_msl_conversion.R

pressure_conversion_stationR Documentation

Daily surface and mean sea level pressure conversion for CDT station data format.

Description

Function to convert surface and mean sea level pressure in both way.

Usage

pressure_conversion_station(
  convert = "sfc2msl",
  pres.data = list(file = "", sep = ",", na.strings = "-99"),
  temp.from = "minmax",
  tmax.data = list(file = "", sep = ",", na.strings = "-99"),
  tmin.data = list(file = "", sep = ",", na.strings = "-99"),
  tmean.data = list(file = "", sep = ",", na.strings = "-99"),
  elev.from = "netcdfDEM",
  elev.data = list(file = "", varid = "z", ilon = 1, ilat = 2),
  output = list(file = "", sep = ",", na.strings = "-99")
)

Arguments

convert

character, the direction of conversion. Valid options: "sfc2msl" and "msl2sfc".

  • "sfc2msl": conversion from surface to mean sea level pressure.

  • "msl2sfc": conversion from mean sea level to surface pressure.

pres.data

named list, providing the pressure data in CDT station data format. Units: hPa.

  • file: character, full path to the file containing the stations data

  • sep: character, column separator of the data

  • na.strings: character, missing values flag

temp.from

character, source of temperature data. Valid options: "minmax" and "mean".

  • "minmax": the mean temperature is computed from the minimum and maximum temperature.

  • "mean": the temperature data is from a mean temperature data.

tmax.data

named list, if temp.from is equal to "minmax", providing the maximum temperature data in CDT station data format. Units: degree Celsius. See pres.data for the elements of the list.

tmin.data

named list, if temp.from is equal to "minmax", providing the minimum temperature data in CDT station data format. Units: degree Celsius. See pres.data for the elements of the list.

tmean.data

named list, if temp.from is equal to "mean", providing the mean temperature data in CDT station data format. Units: degree Celsius. See pres.data for the elements of the list.

elev.from

character, source of the elevation data. Valid options: "inputPresData", "cdtCrdFile" and "netcdfDEM".

  • "inputPresData": the elevation data is from the pressure data.

  • "cdtCrdFile": the elevation data is from a CDT coordinates file. The ID must be the same as the pressure data.

  • "netcdfDEM": the elevation data is from the pressure data.

Default is "netcdfDEM".

elev.data

named list, if elev.from is equal to "cdtCrdFile", providing the CDT coordinate file containing the elevation data. Units: meters.

  • file: character, full path to the CDT coordinate file

  • sep: character, column separator of the data

  • na.strings: character, missing values flag

If elev.from is equal to "netcdfDEM" set the elements of the list providing the Digital Elevation Model in netCDF format. Units: meters.

  • file: character, full path to the netCDF file containing the elevation data.

  • varid: character, name of the variable to read from the netCDF data.

  • ilon: integer, order for the longitude dimension of the variable.

  • ilat: integer, order for the latitude dimension of the variable.

output

named list, the elements of the list are

  • file: character, full path to the file to save the converted pressure

  • sep: character, column separator of the data

  • na.strings: character, missing values flag


rijaf-iri/CDT documentation built on July 3, 2024, 2:54 a.m.