read_fmi_cum | R Documentation |
Read one or more cumulated daily spectral irradiance file as output by Anders
Lindors' model based on libRadTrans. Dates are read from the file header and
parsed with the function suplied as date.f
.
read_fmi_cum(
file,
date = NULL,
geocode = NULL,
label = NULL,
tz = "UTC",
locale = readr::default_locale(),
.skip = 3,
.n_max = -1,
.date.f = lubridate::ymd
)
read_m_fmi_cum(
files,
date = NULL,
geocode = NULL,
label = NULL,
tz = "UTC",
.skip = 3,
.n_max = -1,
.date.f = lubridate::ymd
)
file |
Either a path to a file, a connection, or literal data (either a single string or a raw vector). |
date |
a |
geocode |
A data frame with columns |
label |
character string, but if |
tz |
character Time zone used for interpreting times saved in the file header. |
locale |
The locale controls defaults that vary from place to place. The
default locale is US-centric (like R), but you can use
|
.skip |
Number of lines to skip before reading data—i.e. the number of rows in the header. |
.n_max |
Maximum number of records to read. |
.date.f |
A function for extracting a date-time from the file header
passed as charecter sring to its first argument and which returns a
|
files |
list or vector of paths each one with the same requirements as
described for argument |
read_fmi_cum()
returns a source_spct
object with
time.unit
attribute set to "day"
and when.measured
attribute set to the date-time extracted from the header at the top of
the read file.
read_m_fmi_cum
returns a source_mspct
containing one
source_spct
object for each one of the multiple files read.
See read_table
for details of acceptable values
for file
.
file.name <- system.file("extdata", "2014-08-21_cum.hel",
package = "photobiologyInOut", mustWork = TRUE)
fmi.spct <- read_fmi_cum(file = file.name)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.