R/rbstick.R

"rbstick" <-
    function(n)
{
    stick <- runif(n-1)
    stick <- c(0,sort(stick),1)
    broke <- stick[-1] - stick[-(n+1)]
    broke <- rev(sort(broke))
    broke
}

Try the hubbell package in your browser

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

hubbell documentation built on May 2, 2019, 5:40 p.m.