Using Anova for microarray data
1
0
Entering edit mode
chawla ▴ 190
@chawla-4416
Last seen 10.3 years ago
Hi I need help for using two way anova for microarray data. In the 18 data files, have two time points and 3 treatments,and three replicates. Design looks like this Timepoint 4 5 4 5 4 5 treatment control 1 4 7 10 13 16 Mock 2 5 8 11 14 17 infected 3 6 9 12 15 18 Can you suggest how can I do two way ANOVA , time with control and mock and 2) time with control and infected Thanks Konika [[alternative HTML version deleted]]
Microarray Microarray • 2.7k views
ADD COMMENT
0
Entering edit mode
@sean-davis-490
Last seen 4 months ago
United States
Take a look at the limma package. On Mar 23, 2012 8:31 AM, "konika chawla" <chawla@bio.ntnu.no> wrote: > Hi > I need help for using two way anova for microarray data. > > In the 18 data files, have two time points and 3 treatments,and three > replicates. > Design looks like this > > Timepoint 4 5 4 5 4 5 > treatment > > > > > > control 1 4 7 10 13 16 > Mock 2 5 8 11 14 17 > infected 3 6 9 12 15 18 > > > Can you suggest how can I do two way ANOVA , time with control and mock > and > 2) time with control and infected > > Thanks > Konika > > [[alternative HTML version deleted]] > > _______________________________________________ > Bioconductor mailing list > Bioconductor@r-project.org > https://stat.ethz.ch/mailman/listinfo/bioconductor > Search the archives: > http://news.gmane.org/gmane.science.biology.informatics.conductor > [[alternative HTML version deleted]]
ADD COMMENT
0
Entering edit mode
Hi I tried using the code below for the data design I have aof <- function(x) { m<-data.frame(time, treatmentA, treatmentB, x); anova(aov(x ~ time + treatmentA + treatmentB + time * treatmentA * treatmentB, m)) } time <- factor(c(1,1,1,2,2,2,1,1,1,2,2,2,1,1,1,2,2,2)) treatmentA<-factor(c(1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0)) #control treatmentB<-factor(c(0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1)) #infected anovaresults <- apply(val, 1, aof) could you check if it is the correct way to put factors , based on the design mentioned previously. Also, It gives a huge file for each gene and the Fvalues and Pvalues. Wondering how to write the result in order to get P values for effect of treatmentB , or for checking if treatment A and B are same of different. Could you help Thanks Konika On 03/23/2012 01:55 PM, Sean Davis wrote: > > Take a look at the limma package. > > On Mar 23, 2012 8:31 AM, "konika chawla" <chawla@bio.ntnu.no> <mailto:chawla@bio.ntnu.no>> wrote: > > Hi > I need help for using two way anova for microarray data. > > In the 18 data files, have two time points and 3 treatments,and three > replicates. > Design looks like this > > Timepoint 4 5 4 5 4 5 > treatment > > > > > > control 1 4 7 10 13 16 > Mock 2 5 8 11 14 17 > infected 3 6 9 12 15 18 > > > Can you suggest how can I do two way ANOVA , time with control and > mock > and > 2) time with control and infected > > Thanks > Konika > > [[alternative HTML version deleted]] > > _______________________________________________ > Bioconductor mailing list > Bioconductor@r-project.org <mailto:bioconductor@r-project.org> > https://stat.ethz.ch/mailman/listinfo/bioconductor > Search the archives: > http://news.gmane.org/gmane.science.biology.informatics.conductor > [[alternative HTML version deleted]]
ADD REPLY
0
Entering edit mode
Hi Konika, As Sean already mentioned, you might want to look at the limma package. It seems you have not done so, in which case I will also advise you to to do so. In particular, you should look at the limma User's Guide. Best, Jim On 3/23/2012 10:15 AM, konika chawla wrote: > Hi > I tried using the code below for the data design I have > aof<- function(x) { > m<-data.frame(time, treatmentA, treatmentB, x); > anova(aov(x ~ time + treatmentA + treatmentB + time * treatmentA * > treatmentB, m)) > } > time<- factor(c(1,1,1,2,2,2,1,1,1,2,2,2,1,1,1,2,2,2)) > treatmentA<-factor(c(1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0)) #control > treatmentB<-factor(c(0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1)) #infected > anovaresults<- apply(val, 1, aof) > > could you check if it is the correct way to put factors , based on the > design mentioned previously. > Also, It gives a huge file for each gene and the Fvalues and Pvalues. > Wondering how to write the result in order to get P values for effect of > treatmentB , or for checking if treatment A and B are same of different. > Could you help > Thanks > Konika > > On 03/23/2012 01:55 PM, Sean Davis wrote: >> Take a look at the limma package. >> >> On Mar 23, 2012 8:31 AM, "konika chawla"<chawla at="" bio.ntnu.no="">> <mailto:chawla at="" bio.ntnu.no="">> wrote: >> >> Hi >> I need help for using two way anova for microarray data. >> >> In the 18 data files, have two time points and 3 treatments,and three >> replicates. >> Design looks like this >> >> Timepoint 4 5 4 5 4 5 >> treatment >> >> >> >> >> >> control 1 4 7 10 13 16 >> Mock 2 5 8 11 14 17 >> infected 3 6 9 12 15 18 >> >> >> Can you suggest how can I do two way ANOVA , time with control and >> mock >> and >> 2) time with control and infected >> >> Thanks >> Konika >> >> [[alternative HTML version deleted]] >> >> _______________________________________________ >> Bioconductor mailing list >> Bioconductor at r-project.org<mailto:bioconductor at="" r-project.org=""> >> https://stat.ethz.ch/mailman/listinfo/bioconductor >> Search the archives: >> http://news.gmane.org/gmane.science.biology.informatics.conductor >> > > [[alternative HTML version deleted]] > > _______________________________________________ > Bioconductor mailing list > Bioconductor at r-project.org > https://stat.ethz.ch/mailman/listinfo/bioconductor > Search the archives: http://news.gmane.org/gmane.science.biology.informatics.conductor -- James W. MacDonald, M.S. Biostatistician University of Washington Environmental and Occupational Health Sciences 4225 Roosevelt Way NE, # 100 Seattle WA 98105-6099
ADD REPLY
0
Entering edit mode
Hi Sorry but if you mean http://bioconductor.org/packages/2.6/bioc/vignettes/limma/inst/doc/use rsguide.pdf <http: bioconductor.org="" packages="" 2.6="" bioc="" vignettes="" limma="" inst="" doc="" us="" ersguide.pdf=""> There is nothing about using anova in this document. Could you please point me to another document, which explains ANOVA? Thanks Konika On 03/26/2012 03:57 PM, James W. MacDonald wrote: > Hi Konika, > > As Sean already mentioned, you might want to look at the limma > package. It seems you have not done so, in which case I will also > advise you to to do so. > > In particular, you should look at the limma User's Guide. > > Best, > > Jim > > On 3/23/2012 10:15 AM, konika chawla wrote: >> Hi >> I tried using the code below for the data design I have >> aof<- function(x) { >> m<-data.frame(time, treatmentA, treatmentB, x); >> anova(aov(x ~ time + treatmentA + treatmentB + time * treatmentA * >> treatmentB, m)) >> } >> time<- factor(c(1,1,1,2,2,2,1,1,1,2,2,2,1,1,1,2,2,2)) >> treatmentA<-factor(c(1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0)) #control >> treatmentB<-factor(c(0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1)) #infected >> anovaresults<- apply(val, 1, aof) >> >> could you check if it is the correct way to put factors , based on the >> design mentioned previously. >> Also, It gives a huge file for each gene and the Fvalues and Pvalues. >> Wondering how to write the result in order to get P values for effect of >> treatmentB , or for checking if treatment A and B are same of different. >> Could you help >> Thanks >> Konika >> [[alternative HTML version deleted]]
ADD REPLY
0
Entering edit mode
Hi Konika, I opened up the URL you provided, hit Ctrl-F ('Find'), and typed in 'ANOVA'. Two hits, one of which (on page 45) lands you directly onto the section that you ought to read, namely, 'Factorial Designs', whereupon you will note that there is an example of... two-way ANOVA (with contrasts and extensive discussion of why one might want to formulate them in a specific fashion). From pages 45 through 47 there is an extremely thorough discussion of this. Gordon Smyth and the limma developers put an awful lot of time into writing that documentation, the least people could do is read a few pages of it. Analysis of variance (ANOVA) assumes that a linear model with a Gaussian error term can have the overall variance (goodness or lack of fit) partitioned into differences that the model (with one or more factors) captures, and differences that it doesn't. If the proportion of the variance in a data set that is captured by a factor of the model is a large multiple of that which remains unexplained, then the factor is judged to show significant differences between the groups it defines. Hence, the underlying assumption is that a linear model is adequate to model variation in the data, connecting this to 'limma', or... *LI*near *M*odels for *M*icro*A*rray data If this doesn't make sense to you, please heed Vincent Carey's advice and consult a statistician. Statistics isn't a black box, but there are subtle bits. Once you are comfortable with linear models and 'limma' (the documentation of which is very well written), you will be better equipped to answer much harder questions about sequencing data, isoform usage, technical artifacts, dependent or correlated data, and other topics of contemporary interest. Hope this helps, --t On Mon, Mar 26, 2012 at 7:54 AM, konika chawla <chawla@bio.ntnu.no> wrote: > Hi > Sorry but if you mean > > http://bioconductor.org/packages/2.6/bioc/vignettes/limma/inst/doc/u sersguide.pdf > < > http://bioconductor.org/packages/2.6/bioc/vignettes/limma/inst/doc/u sersguide.pdf > > > There is nothing about using anova in this document. > Could you please point me to another document, which explains ANOVA? > Thanks > Konika > > > On 03/26/2012 03:57 PM, James W. MacDonald wrote: > > Hi Konika, > > > > As Sean already mentioned, you might want to look at the limma > > package. It seems you have not done so, in which case I will also > > advise you to to do so. > > > > In particular, you should look at the limma User's Guide. > > > > Best, > > > > Jim > > > > On 3/23/2012 10:15 AM, konika chawla wrote: > >> Hi > >> I tried using the code below for the data design I have > >> aof<- function(x) { > >> m<-data.frame(time, treatmentA, treatmentB, x); > >> anova(aov(x ~ time + treatmentA + treatmentB + time * treatmentA * > >> treatmentB, m)) > >> } > >> time<- factor(c(1,1,1,2,2,2,1,1,1,2,2,2,1,1,1,2,2,2)) > >> treatmentA<-factor(c(1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0)) #control > >> treatmentB<-factor(c(0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1)) #infected > >> anovaresults<- apply(val, 1, aof) > >> > >> could you check if it is the correct way to put factors , based on the > >> design mentioned previously. > >> Also, It gives a huge file for each gene and the Fvalues and Pvalues. > >> Wondering how to write the result in order to get P values for effect of > >> treatmentB , or for checking if treatment A and B are same of different. > >> Could you help > >> Thanks > >> Konika > >> > > > [[alternative HTML version deleted]] > > _______________________________________________ > Bioconductor mailing list > Bioconductor@r-project.org > https://stat.ethz.ch/mailman/listinfo/bioconductor > Search the archives: > http://news.gmane.org/gmane.science.biology.informatics.conductor > -- *A model is a lie that helps you see the truth.* * * Howard Skipper<http: cancerres.aacrjournals.org="" content="" 31="" 9="" 1173.full.pdf=""> [[alternative HTML version deleted]]
ADD REPLY
0
Entering edit mode
Hi Thank you all for suggestions, I will try to figure out the problem. I regret the inconvenience caused. Thanks again, Konika [[alternative HTML version deleted]]
ADD REPLY
0
Entering edit mode
On Mon, Mar 26, 2012 at 10:54 AM, konika chawla <chawla at="" bio.ntnu.no=""> wrote: > Hi > Sorry but if you mean > http://bioconductor.org/packages/2.6/bioc/vignettes/limma/inst/doc/u sersguide.pdf > <http: bioconductor.org="" packages="" 2.6="" bioc="" vignettes="" limma="" inst="" doc="" usersguide.pdf=""> > There is nothing about using anova in this document. > Could you please point me to another document, which explains ANOVA? > Thanks > Konika Hi, Konika. Limma uses the concept of a linear model. ANOVA is a subset of this class of models. If you use limma on single-channel or common-reference two-color data, the limma approach is conceptually equivalent to ANOVA on each gene. In using limma, you also get the benefit of pooled variance estimates, important for relatively small sample sizes typical of microarrays. Sean > > On 03/26/2012 03:57 PM, James W. MacDonald wrote: >> Hi Konika, >> >> As Sean already mentioned, you might want to look at the limma >> package. It seems you have not done so, in which case I will also >> advise you to to do so. >> >> In particular, you should look at the limma User's Guide. >> >> Best, >> >> Jim >> >> On 3/23/2012 10:15 AM, konika chawla wrote: >>> Hi >>> I tried using the code below for the data design I have >>> aof<- function(x) { >>> ? ? m<-data.frame(time, treatmentA, treatmentB, x); >>> ? ? anova(aov(x ~ time + treatmentA + treatmentB + time * treatmentA * >>> treatmentB, m)) >>> } >>> time<- factor(c(1,1,1,2,2,2,1,1,1,2,2,2,1,1,1,2,2,2)) >>> ? ?treatmentA<-factor(c(1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0)) #control >>> treatmentB<-factor(c(0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1)) #infected >>> anovaresults<- apply(val, 1, aof) >>> >>> could you check if it is the correct way to put factors , based on the >>> design mentioned previously. >>> Also, It gives a huge file for each gene and the Fvalues and Pvalues. >>> Wondering how to write the result in order to get P values for effect of >>> treatmentB , or for checking if treatment A and B are same of different. >>> Could you help >>> Thanks >>> Konika >>> > > > ? ? ? ?[[alternative HTML version deleted]] > > _______________________________________________ > Bioconductor mailing list > Bioconductor at r-project.org > https://stat.ethz.ch/mailman/listinfo/bioconductor > Search the archives: http://news.gmane.org/gmane.science.biology.informatics.conductor
ADD REPLY
0
Entering edit mode
There are multiple mentions of ANOVA and "two way" in the document you mention, for example section 8.8. I strongly suggest you speak to a statistician to review this document with you and give you pointers to other suitable materials. On Mon, Mar 26, 2012 at 10:54 AM, konika chawla <chawla@bio.ntnu.no> wrote: > Hi > Sorry but if you mean > > http://bioconductor.org/packages/2.6/bioc/vignettes/limma/inst/doc/u sersguide.pdf > < > http://bioconductor.org/packages/2.6/bioc/vignettes/limma/inst/doc/u sersguide.pdf > > > There is nothing about using anova in this document. > Could you please point me to another document, which explains ANOVA? > Thanks > Konika > > > On 03/26/2012 03:57 PM, James W. MacDonald wrote: > > Hi Konika, > > > > As Sean already mentioned, you might want to look at the limma > > package. It seems you have not done so, in which case I will also > > advise you to to do so. > > > > In particular, you should look at the limma User's Guide. > > > > Best, > > > > Jim > > > > On 3/23/2012 10:15 AM, konika chawla wrote: > >> Hi > >> I tried using the code below for the data design I have > >> aof<- function(x) { > >> m<-data.frame(time, treatmentA, treatmentB, x); > >> anova(aov(x ~ time + treatmentA + treatmentB + time * treatmentA * > >> treatmentB, m)) > >> } > >> time<- factor(c(1,1,1,2,2,2,1,1,1,2,2,2,1,1,1,2,2,2)) > >> treatmentA<-factor(c(1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0)) #control > >> treatmentB<-factor(c(0,0,1,0,0,1,0,0,1,0,0,1,0,0,1,0,0,1)) #infected > >> anovaresults<- apply(val, 1, aof) > >> > >> could you check if it is the correct way to put factors , based on the > >> design mentioned previously. > >> Also, It gives a huge file for each gene and the Fvalues and Pvalues. > >> Wondering how to write the result in order to get P values for effect of > >> treatmentB , or for checking if treatment A and B are same of different. > >> Could you help > >> Thanks > >> Konika > >> > > > [[alternative HTML version deleted]] > > _______________________________________________ > Bioconductor mailing list > Bioconductor@r-project.org > https://stat.ethz.ch/mailman/listinfo/bioconductor > Search the archives: > http://news.gmane.org/gmane.science.biology.informatics.conductor > [[alternative HTML version deleted]]
ADD REPLY

Login before adding your answer.

Traffic: 576 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