View source: R/frequency_analysis.R
monthly_frequency_table | R Documentation |
The table will accept daily, discrete, or a both types of data. The median of each
year/month is calculated. Then using that median, monthly stats are calculated.
Percentiles are calculated using the quantile
function with "type=6".
monthly_frequency_table(
gw_level_dv,
gwl_data,
parameter_cd = NA,
date_col = NA,
value_col = NA,
approved_col = NA,
stat_cd = NA,
flip = FALSE
)
gw_level_dv |
data frame, daily groundwater level data. Often obtained
from |
gwl_data |
data frame returned from |
parameter_cd |
If data in gw_level_dv comes from NWIS, the parameter_cd
can be used to define the value_col. If the data doesn't come directly from
NWIS services, this can be set to |
date_col |
the name of the date column. The default is |
value_col |
the name of the value column. The default is |
approved_col |
the name of the column to get provisional/approved status.
The default is |
stat_cd |
If data in gw_level_dv comes from NWIS, the stat_cd can be used to help define the value_col. |
flip |
logical. If |
a data frame of monthly groundwater level statistics including the 5th, 10th, 25th, 75th, 90th, and 95th percentiles; the number of years of data; and the lowest monthly median and the highest monthly median.
# site <- "263819081585801"
p_code_dv <- "62610"
statCd <- "00001"
# gw_level_dv <- dataRetrieval::readNWISdv(site, p_code_dv, statCd = statCd)
gw_level_dv <- L2701_example_data$Daily
monthly_frequency <- monthly_frequency_table(gw_level_dv,
NULL,
parameter_cd = "62610")
head(monthly_frequency)
gwl_data <- L2701_example_data$Discrete
monthly_frequency_combo <- monthly_frequency_table(gw_level_dv,
gwl_data,
parameter_cd = "62610")
head(monthly_frequency_combo)
monthly_flip <- monthly_frequency_table(gw_level_dv,
gwl_data,
parameter_cd = "62610",
flip = TRUE)
head(monthly_flip)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.