Learn R Programming

RelValAnalysis (version 1.0)

capdist: Captial-distribution Objects

Description

The function capdist is used to create capital-distribution objects.

Usage

capdist(x)

Arguments

Value

A capdist object.

Details

The function capdist is used to create capital-distribution objects. These are vectors with class "capdist" which represents the distribution of capital in a market at a single moment. When the function is called, it is checked whether the sum of weights is equal to 1 up to 0.1%. If not, a warning message will be displayed. Capital distribution objects can be plotted. See plot.capdist for details.

References

Fernholz, E. R. (2002) Stochastic portfolio theory. Springer.

See Also

plot.capdist

Examples

Run this code
# Create a random distribution
x <- runif(100)
x <- x/sum(x)
x <- capdist(x)
plot(x)

Run the code above in your browser using DataLab