search for: generdm

Displaying 1 result from an estimated 1 matches for "generdm".

Did you mean: general
2008 Oct 30
3
why does sample(x, n) give the same n items in every separate runs?
...lagre group with same levels for small group. But I got the same set of genes when I run the code in every other runs in Linux. This gives me a doubt in my result. smallvec<-c(8,12,9,6,13,20,16,11,8,5) ## the No. of genes in levels 1 to 10 largevec<-c(400,300,550,600,210,420,380,600,450,500) generdm<-c() ## a random set of genes for( i in 1:length(smallvec)){ generdm<-c(generdm,sample(rownames(largedf)[sum(largevec[0:(i-1)],1):sum(largevec[0:i])],smallvec[i])) ## rownames(largedf) gives gene names ordered by levels in large group } Could you please help me out? Thanks a lot!! Josh