Skip to content

Commit b75f69a

Browse files
author
Stephanie Owen
committed
replace 'statistic' with 'statistics' param from EDAB_Utilites in 'create_spatial_indicator.R'
1 parent b3d7c51 commit b75f69a

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

R/create_spatial_indicator.R

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
#' shp.file = Shape file you wish to crop each input file to
1111
#' var.name = Variable name you wish to extract.
1212
#' area.names = Names of shape file areas you want to summarize.
13-
#' statistic = Which statistic to calculate = 'mean'
13+
#' statistics = Which statistic(s) to calculate = 'mean'
1414
#' agg.time = Time scale to calculate over (days, doy, months, season, or years)
1515
#' tz = Time zone to convert. No correction if NA
1616
#' touches = If TRUE, all cells touched by lines or polygons will be masked, not just those on the line render path, or whose center point is within the polygon
@@ -39,7 +39,7 @@ create_spatial_indicator <- function(indicator_name, units, agg.time, ...) {
3939
YEAR = ls.id,
4040
DATA_VALUE = value,
4141
AREA = area,
42-
STATISTIC = statistic
42+
STATISTIC = statistics
4343
) |>
4444
dplyr::mutate(INDICATOR_NAME = indicator_name, INDICATOR_UNITS = units)
4545
output <- output %>%
@@ -59,7 +59,7 @@ create_spatial_indicator <- function(indicator_name, units, agg.time, ...) {
5959
INDICATOR_NAME = indicator_name,
6060
INDICATOR_UNITS = units
6161
) %>%
62-
dplyr::rename(DATA_VALUE = value, AREA = area, STATISTIC = statistic) %>%
62+
dplyr::rename(DATA_VALUE = value, AREA = area, STATISTIC = statistics) %>%
6363
purrr::discard(~ all(is.na(.)))
6464
}
6565

0 commit comments

Comments
 (0)