| antecedent_precip | R Documentation | 
Computes antecedent precipitation as a rolling sum. Time series must be continuous at hourly intervals
antecedent_precip(x, period = 48, delay = 0, fun = sum,
  value.name = "Precip", datetime.name = "Datetime")
x | 
 Dataframe of hourly precipitation values  | 
period | 
 Duration of antecedent period as hours (default=48)  | 
delay | 
 Shift in the antecedent period as hours (default=0)  | 
fun | 
 Function applied to each period (e.g. sum, max)  | 
value.name | 
 Name of precipitation column  | 
datetime.name | 
 Name of date/time column  | 
numeric vector of antecedent precipitation for given period, delay, and fun
filepath <- system.file("extdata", "LoganPrecip.xlsx", package = "myrwaR")
pcp <- load_precip_from_xls(filepath, as.type='dataframe')
pcp$Precip.48 <- antecedent_precip(pcp, period=48, delay=0,
                                   datetime.name="Datetime",
                                   value.name="Precip")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.