geoMeanCalc: Geometric Mean

View source: R/agg.R

geoMeanCalcR Documentation

Geometric Mean

Description

Calculate the geometric mean of a vector of forecasts. We handle 0s by replacing them with the qth quantile of the non-zero forecasts.

Usage

geoMeanCalc(x, q = 0.05)

Arguments

x

Vector of forecasts in 0 to 100 range (%)

q

The quantile to use for replacing 0s (between 0 and 1)

Value

(numeric) The geometric mean of the vector

Note

agg(a) + agg(not a) does not sum to 1 for this aggregation method.


aggutils documentation built on Aug. 23, 2023, 1:09 a.m.