View source: R/mars_rainfall_functions.R
marsDetectEvents | R Documentation |
Return a dataset of rainfall event IDs for a time period
marsDetectEvents(dtime_est, rainfall_in, iet_hr = 6, mindepth_in = 0.1)
dtime_est |
vector, POSIXct date times |
rainfall_in |
vector, num, of rainfall depths corresponding to |
iet_hr |
num, Interevent time, in hours. The default is 6 hours. |
mindepth_in |
num, minimum depth of a given event, in inches. The default is 0.10 inches. |
Function should be used inside mutate
to add output to the corresponding table.
Output will be a vector of integers corresponding to dtime_est
and representing
the event ID for each time step.
gage_temp <- dplyr::mutate(marsSampleRain,
event_id = marsDetectEvents(dtime_est = marsSampleRain$dtime_est,
rainfall_in = marsSampleRain$rainfall_in,
iet_hr = 6, mindepth_in = 0.10))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.