get_events_file | R Documentation |
Given a file path it reads a data frame (time series) of stage
measurements and calls get_events()
.
The resulting events can be optionally written to a single file or to
separate files for each gauging station ID (ID
) and Event_Type
.
Files which produce errors return NULL
.
get_events_file( Q_file, inputsep = ";", inputdec = ".", save = FALSE, split = TRUE, outdir = file.path(tempdir(), "Events"), mc.cores = 2L, return = TRUE, ... )
Q_file |
A character string containing the name of the file which the data
are to be read from with |
inputsep |
Field separator character string for input data. |
inputdec |
Character string for decimal points in input data. |
save |
A logical. If |
split |
A logical. If |
outdir |
A character string naming a directory where the output file(s) should be written to. |
mc.cores |
Number of cores to use with
|
return |
A logical. If |
... |
Arguments to be passed to |
A data frame which contains for every increase or decrease event in a
given time series all metrics (all_metrics()
),
gauging station ID, event type, and starting time of an event.
Included metrics are amp()
, mafr()
,
mefr()
, dur()
, ratio()
.
The returned data frame is not split. Returns NULL
, if argument
return
is set to FALSE
.
Q_file <- system.file("extdata", "Q.csv", package = "hydropeak") # save to tempdir() events <- get_events_file(Q_file, inputsep = ",", inputdec = ".", save = TRUE, split = TRUE, return = TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.