Description Usage Arguments Details Value References See Also Examples
The function GeometricMean
computes the geometric mean of non-negative numbers with a given weight.
1 | GeometricMean(x, weight = rep(1/length(x), length(x)))
|
x |
a numeric vector with non-negative entries. |
weight |
a numeric probability vector. The default value is the vector with equal weights. |
The geometric mean is used in stochastic portfolio theory as the generating function of the constant-weighted portfolio. See Example 3.1.6 of Fernholz (2002).
A number.
Fernholz, E. R. (2002) Stochastic portfolio theory. Springer.
1 2 3 | x <- c(0.3, 0.7)
weight <- c(0.6, 0.4)
GeometricMean(x, weight)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.