Re: [R] draw random samples from empirical distribution

2005-03-01 Thread Kjetil Brinchmann Halvorsen
bogdan romocea wrote: Dear useRs, I have an empirical distribution (not normal etc) and I want to draw random samples from it. One solution I can think of is to compute let's say 100 quantiles, then use runif() to draw a random number Q between 1 and 100, and finally run runif() again to pull a

[R] draw random samples from empirical distribution

2005-02-28 Thread bogdan romocea
Dear useRs, I have an empirical distribution (not normal etc) and I want to draw random samples from it. One solution I can think of is to compute let's say 100 quantiles, then use runif() to draw a random number Q between 1 and 100, and finally run runif() again to pull a random value from the