Re: [R] Help Help with sampling

2008-10-15 Thread Alex99
Thanks again Jorge, but when I type in lapply(res,function(x) rbind(rowMeans(x)) it's like it's waiting for something else, it doesnt run. I tried "help(lapply)" to learn more about lappy but didnt give me any result. could you tell me why it doesnt run and what is lapply for? Thanks a lot for a

Re: [R] Help Help with sampling

2008-10-15 Thread Jorge Ivan Velez
Dear Alex, Is this what you want? my=read.table(textConnection(" X8 X9 X10 X102 X110 X177 X283 X284 X286 X292 X297 X306 X308 X314 0 1 000100000000 0 0 001000000010 0 1 0000000

Re: [R] Help Help with sampling

2008-10-15 Thread Alex99
Thanks for the reply Jorge, that works BUT the reason I didn't use it, is because I need to calculate the mean and Standard deviation for S1,S2,S3 and S4 in each sample. which means I'll have 5 means for S1, and 5 means for S2 and 5 means for S3 and 5 means for S4 (and at the end I have to get th

Re: [R] Help Help with sampling

2008-10-15 Thread Alex99
Thanks for the reply Peter, that works BUT the reason I didn't use it, is because I need to calculate the mean and Standard deviation for S1,S2,S3 and S4 in each sample. which means I'll have 5 means for S1, and 5 means for S2 and 5 means for S3 and 5 means for S4 (and at the end I have to get t

Re: [R] Help Help with sampling

2008-10-15 Thread Jorge Ivan Velez
Dear Alex, Is this what you want? # Data set my=read.table(textConnection(" X8 X9 X10 X102 X110 X177 X283 X284 X286 X292 X297 X306 X308 X314 0 1 000100000000 0 0 001000000010 0 1 00000

Re: [R] Help Help with sampling

2008-10-15 Thread Peter Dalgaard
Alex99 wrote: > Hi everyone, > > I have a dataset(named "Mydata") which includes 4 different variables named; > s1,s2,s3,s4 .Each variable(symptom) has 14 patients. > I need to use random sampling to make, 5 different samples from my data with > 5 patients in each sample. i.e. using all 4 variables

[R] Help Help with sampling

2008-10-15 Thread Alex99
Hi everyone, I have a dataset(named "Mydata") which includes 4 different variables named; s1,s2,s3,s4 .Each variable(symptom) has 14 patients. I need to use random sampling to make, 5 different samples from my data with 5 patients in each sample. i.e. using all 4 variables I need to make 5 differ