multtest Paired T-test error
1
0
Entering edit mode
Ken Termiso ▴ 250
@ken-termiso-1087
Last seen 9.6 years ago
On a Mac G5 with OSX 10.3 (updated) and R 2.0.1 I'm using multtest with good success until I tried to run a paired t-test...the other tests executed fine, but mt.teststat with test="pairt" didn't seem to like my class labels... m <- exprs(m579rma) m.cl <- c(0,0,0,1,1,1) # first 3 cols are control chips, last 3 cols are exp chips. m <- as.numeric(m) dim(m) <- c(22277,6) teststat_pairt_para_rma <- mt.teststat(m,m.cl,test="pairt",nonpara="n") Error in mt.checkclasslabel(classlabel, test) : Some errors in specifying classlabel for the paired t test for the block 1 located at ( 1 2 ) your classlabel= 0 I then tried to see if it didn't like the zeroes in my classlabel... mpairedt.cl = c(1,1,1,2,2,2) teststat_pairt_para_rma <- mt.teststat(m,mpairedt.cl,test="pairt",nonpara="n") Error in mt.checkclasslabel(classlabel, test) : in paired t test, we only handle two groups your classlabel= 1 As per another message in the BioC archives entitled 'Bug Report: mt.teststat with test="pairt"', I rearranged my chips so that the order was con,exp,con,exp,con,exp instead of con,con,con,exp,exp,exp..."m_pairt" is the name of this rearranged matrix of my chips... m_pairt.cl <- c(1,2,1,2,1,2) teststat_pairt_para_rma <- mt.teststat(m_pairt,m_pairt.cl,test="pairt",nonpara="n") Error in mt.checkclasslabel(classlabel, test) : in paired t test, we only handle two groups your classlabel= 1 Should I just take the square root of the F-stat P-values to get the P-values for the paired t-test, or is there a workaround? Thanks in advance, Ken
• 1.1k views
ADD COMMENT
0
Entering edit mode
kpollard ▴ 110
@kpollard-7578
Last seen 8.8 years ago
United States
Ken, For a "pairt" test, you need the labels to be 0's and 1's *and* to be ordered with pairs next to each other. So, this should work: labels<-c(0,1,0,1,0,1) stats<-mt.teststat(m,labels,test="pairt",nonpara="n") Also, be sure to reorder the columns of m accordingly. Best, Katie > ------------------------------ > > Message: 3 > Date: Thu, 27 Jan 2005 18:51:56 +0000 > From: "Ken Termiso" <jerk_alert@hotmail.com> > Subject: [BioC] multtest Paired T-test error > To: bioconductor@stat.math.ethz.ch > Message-ID: <bay101-f399a175aaec5f20717a3aee8780@phx.gbl> > Content-Type: text/plain; format=flowed > > On a Mac G5 with OSX 10.3 (updated) and R 2.0.1 I'm using multtest with good > success until I tried to run a paired t-test...the other tests executed > fine, but mt.teststat with test="pairt" didn't seem to like my class > labels... > > m <- exprs(m579rma) > m.cl <- c(0,0,0,1,1,1) # first 3 cols are control chips, last 3 cols are exp > chips. > m <- as.numeric(m) > dim(m) <- c(22277,6) > teststat_pairt_para_rma <- mt.teststat(m,m.cl,test="pairt",nonpara="n") > > Error in mt.checkclasslabel(classlabel, test) : > Some errors in specifying classlabel for the paired t test for the block 1 > located at ( 1 2 ) > your classlabel= 0 > > > > I then tried to see if it didn't like the zeroes in my classlabel... > > > > mpairedt.cl = c(1,1,1,2,2,2) > teststat_pairt_para_rma <- > mt.teststat(m,mpairedt.cl,test="pairt",nonpara="n") > > Error in mt.checkclasslabel(classlabel, test) : > in paired t test, we only handle two groups > your classlabel= 1 > > > > As per another message in the BioC archives entitled 'Bug Report: > mt.teststat with test="pairt"', I rearranged my chips so that the order was > con,exp,con,exp,con,exp instead of con,con,con,exp,exp,exp..."m_pairt" is > the name of this rearranged matrix of my chips... > > > > m_pairt.cl <- c(1,2,1,2,1,2) > teststat_pairt_para_rma <- > mt.teststat(m_pairt,m_pairt.cl,test="pairt",nonpara="n") > Error in mt.checkclasslabel(classlabel, test) : > in paired t test, we only handle two groups > your classlabel= 1 > > > > Should I just take the square root of the F-stat P-values to get the > P-values for the paired t-test, or is there a workaround? > > Thanks in advance, > Ken
ADD COMMENT

Login before adding your answer.

Traffic: 767 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6