Hello,
You need to include cc: to list in your replies.
Does this work for you?
dat1<-list()
for(i in 1:100){
?dat1[[i]]<-list()
?seed<-.Random.seed
?dat1[[i]]<-matrix(sample(c(0.23,0.56,0.45,0.85,0.7),2500,replace=TRUE),ncol=50)
?}
?dat1[[1]][1]
#[1] 0.56
?dat1[[2]][1]
#[1] 0.85
?dat1[[3]][1]
#[1] 0.23
A.K.
From: nooshin bahar <bahar.612000 at gmail.com>
To: R. Michael Weylandt <michael.weylandt at gmail.com>; smartpink111 at yahoo.com
Sent: Tuesday, August 14, 2012 5:48 AM
Subject: Re: [R] one problem
To: R. Michael Weylandt <michael.weylandt at gmail.com>; smartpink111 at yahoo.com
Sent: Tuesday, August 14, 2012 5:48 AM
Subject: Re: [R] one problem
Hello guys I have 5 number ((0.23, 0.56, 0.45, 0.85, 0.7) that I want to generate these numbers?in a rectangular 50*50. But I want to have different realization. dat1<-matrix(sample(c(0.23,0.56,0.45,0.85,0.7),2500,replace=TRUE),ncol=50) This does work. But I want to have alot of ?different generation with these datas. ?I have to change seed? to have different generation and have different frequency. Then compare between them. best wishes Nosohin? On Tue, Aug 14, 2012 at 7:13 AM, R. Michael Weylandt <michael.weylandt at gmail.com> wrote: Hi Nooshin, > >It's a common enough request, but it's simply not a well defined >problem so unless you specify further, we can't help you. (I.e., the >information you give doesn't uniquely parameterize a multivariate >distribution) > >With that said, you may want to look at ?sample for basic resampling. > >Cheers, >Michael > > >On Mon, Aug 13, 2012 at 11:29 AM, nooshin bahar <bahar.612000 at gmail.com> wrote: >> Dear Mr/Mrs >> I need to generate a random data only with (0.23, 0.56, 0.45, 0.85, 0.7) >> with known mean, SD, correlation length, in a matrix 50*50. I know R coeds >> but in this case, >> ?I could not find to generate only with finite numbers that I have. Please >> guide me . >> Best Regards >> ? Nooshin >> > >> ? ? ? ? [[alternative HTML version deleted]] >> >> ______________________________________________ >> R-help at r-project.org mailing list >> https://stat.ethz.ch/mailman/listinfo/r-help >> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html >> and provide commented, minimal, self-contained, reproducible code. >?????