inst/examples/ex_dist_approximate.R

# Approximate distributions with different tolerance
p <- c(0.12345, 0.23456, 1.0 - 0.12345 - 0.23456)
d <- approximate(p, tol = 0.1)
dump(d)

d <- approximate(p, tol = 0.001)
dump(d)

d <- approximate(p, tol = 0.00001)
dump(d)

Try the rinform package in your browser

Any scripts or data that you put into this service are public.

rinform documentation built on April 1, 2018, 12:12 p.m.