[R] IMPORTANT!!!! PLEASE HELP ME

Rolf Turner rolf.turner at xtra.co.nz
Sun Nov 25 21:54:16 CET 2012



PLEASE remember:  This list has a "no homework" policy.  Students
should do their own homework.

     cheers,

         Rolf Turner

On 25/11/12 13:18, Pete Brecknock wrote:
> Jasmin wrote
>> I try to use hansen-hurwitz and horvitz-thompson estimator.So I should
>> generate samples which come from normal distribution (mu=50,sigma=3).
> I have taken the liberty of scaling the problem down to something more
> digestible and have changed lines 5 and 7 in your code
>
> nsamples=10
> sampsize=5
> i=0
> y=matrix(rnorm(nsamples*sampsize,50,3),nrow=nsamples)
> s=matrix(NA,10,5)
> for(i in 1:10){
> s[i,]=sample(y,5,replace=T)
> }




More information about the R-help mailing list