R/rmult.R

Defines functions `rmult`

`rmult` <-
function(n=1, sspace, prob){
	prob <- prob/sum(prob)
	r <- runif(1)
	sspace[length(sspace)-sum(r < cumsum(prob))+1]
}

Try the RankAggreg package in your browser

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

RankAggreg documentation built on July 8, 2020, 6:20 p.m.