View source: R/climatic_extremes.R
climatic_extremes | R Documentation |
climatic_extremes
returns a data table displaying the minimum and/or maximum
values for elements in a given time period. This can be provided by station.
climatic_extremes(
data,
date_time,
elements,
station = NULL,
year = NULL,
month = NULL,
dekad = NULL,
pentad = NULL,
to = c("hourly", "daily", "pentad", "dekadal", "monthly", "annual-within-year",
"annual", "longterm-monthly", "longterm-within-year", "station", "overall"),
by = NULL,
doy = NULL,
doy_first = 1,
doy_last = 366,
max_val = TRUE,
min_val = FALSE,
first_date = FALSE,
n_dates = FALSE,
last_date = FALSE,
na_rm = FALSE,
na_prop = NULL,
na_n = NULL,
na_consec = NULL,
na_n_non = NULL,
names = "{.fn}_{.col}"
)
data |
|
date_time |
|
elements |
|
station |
|
year |
|
month |
|
dekad |
|
pentad |
|
to |
|
by |
|
doy |
|
doy_first |
|
doy_last |
|
max_val |
|
min_val |
|
first_date |
|
n_dates |
|
last_date |
|
na_rm |
|
na_prop |
|
na_n |
|
na_consec |
|
na_n_non |
|
names |
Format of column names. Passed to |
A summary data frame containing minimum/maximum values for element(s).
# Run example for a subset of the data
daily_niger_1 <- daily_niger %>% dplyr::filter(year > 1970)
# create a data frame displaying the min and max values for tmin/tmax for each day and station
climatic_extremes(data = daily_niger_1, date_time = "date", elements = c("tmin", "tmax"),
max_val = TRUE, min_val = TRUE,
station = "station_name", na_rm = TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.