<br />
#对野生型和处理组的每个探针进行t检验<br />
##测试<br />
test<-dat[c(1:6),]<br />
##重新写函数<br />
myfun1<-function(i) return(t.test(test[i, 9:12], test[i, 13:15])$p.value)<br />
test$P<-sapply(1:nrow(test), myfun1)</p>
<p>##正式应用<br />
myfun<-function(i) return(t.test(dat[i, 9:12], dat[i, 13:15])$p.value)<br />
dat$P<-sapply(1:nrow(dat), myfun) </p>
<p>
</p>