ddf
R/ddf-class.R
probs.Rd
This function returns the probabilities of elements of the support of a given distribution as a numerical vector.
probs(dist) # S4 method for class 'ddf' probs(dist)
A ddf object, the distribution.
Probabilities as a numerical vector.
probs(ddf(1:3)) #> [1] 0.3333333 0.3333333 0.3333333 probs(ddf(1:3, c(1 / 2, 1 / 4, 1 / 4))) #> [1] 0.50 0.25 0.25