discretedistribution {lestat} | R Documentation |
Create Object Representing a Discrete Distribution
Description
An object representing a discrete distribution is created, based on explicitly given possible values and probabilities for these.
Usage
discretedistribution(vals, probs = rep(1, length(vals)))
Arguments
vals |
A vector listing the possible values of the discrete distribution. |
probs |
If given, |
Value
A discrete probability distribution.
Author(s)
Petter Mostad <mostad@chalmers.se>
Examples
dist <- discretedistribution(1:10)
expectation(dist)
variance(dist)
[Package lestat version 1.9 Index]