[R] How to generate random number from grouped data?
ximing wu
xiwu at uoguelph.ca
Wed Dec 15 06:07:04 CET 2004
Hi there, I need help on the following problem. Any suggestions will be
much appreciated.
Let x be an i.i.d. random sample of a continuous variable. For some fixed
numbers a1<a2<a3<...<ak, we don't observe x, but some grouped information:
1) the frequency of x falls in each interval (a1, a2], (a2, a3], (a3, a4],...
2) the conditional mean of x within each interval, mu1, mu2, mu3,...
Is there a way to generate a random sample based on the grouped information
on frequency and mean of each interval?
Thanks for the help.
Ximing
More information about the R-help
mailing list