CSIimport_unit | R Documentation |
Read in unit value salinity file.
CSIimport_unit(file, mindays = 15)
file |
character The unit-value file to import. Must have Year, Month, Day, and Time columns, or single Timestamp = 'YYYY-MM-DD HH:mm:ss', and columns of salinty values by site. |
mindays |
integer the minimum number of daily values (any number of values per day) needed to produce a mean value for a given month (default 15). Months with fewer data values than this will be asigned mean NA. |
A salinity object data.frame for calculating CSI values; has Year and Month timestamp columns, with (optionally multiple) individual columns of site salinity values.
# Data file with Year, Month, Day, and Time columns
data_path <- system.file("extdata", "Unitvalue_North_Inlet_ymdt.csv.zip", package="CSI")
unzip(data_path, exdir = getwd())
sal <- CSIimport_unit("Unitvalue_North_Inlet_ymdt.csv")
# Data file with single Timestamp column
data_path <- system.file("extdata", "Unitvalue_North_Inlet.csv.zip", package="CSI")
unzip(data_path, exdir = getwd())
sal <- CSIimport_unit("Unitvalue_North_Inlet.csv")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.