Visualizing pre- and post-normalization for single-colour arrays
1
0
Entering edit mode
@mrjmorriucalgaryca-4873
Last seen 9.6 years ago
Hello, My name is Matthew Morris, I'm a second year Master's student at the University of Calgary, and I am fairly new to the world of microarrays! My project involves single-colour arrays, for which helpful documents seem to be rather limited. As such, I have some questions. I'll ask the questions first, and then show you the code. If you can only answer one of the three, some info is better than none! 1. How do I visualize my data pre- and post-normalization? What will I be looking for? 2. I am using code from someone else to flag nonuniform and feature population outliers. It certainly alters my results, but I'm not sure how to check if it is working correctly. 3. How can I incorporate things like sex and length into my model? (to clarify, I am looking at four populations of fish called Cran, Hog, OL and LCM respectively, raised at 7 or 23 degrees, and I would like to eliminate the effects of sex, tank and length) Thank you very much, Matthew Morris Code is as follows: library(limma) #read Targets file (make sure to set directory first through File) targets<-readTargets("targets.txt") #checks that file was read correctly targets$FileName #weight OL wtAgilent.mRGOLFilter <- function(qta) {mapply(min,1-qta[,"gIsFeatNonUnifOL"],1-qta[,"gIsFeatNonUnifOL"],1-qt a[,"gIsFeatPopnOL"],1-qta[,"gIsFeatPopnOL"])} #read data from array ouput files into E E<-read.maimages(targets$FileName, source="agilent.median",path="actualall", wt.fun=wtAgilent.mRGOLFilter, columns=list(E="gProcessedSignal"), other.columns=list(saturated="gIsSaturated", nonuniform="gIsFeatNonUnifOL", popnoutlier="gIsFeatPopnOL", flag="IsManualFlag", wellabovebg="gIsWellAboveBG")) #to see that everything looks fine E #normalizing between arrays: normalize<-normalizeBetweenArrays(E, method="quantile") #remove control spots dat1<-normalize[normalize$genes$ControlType==0,] #average values for identical probes within an array Eavg<-avereps(dat1, ID=dat1$genes$ProbeName) #analyze factorial design: first identify the factors in template TS <- paste(targets$Population, targets$Temperature, sep=".") #check to see it worked TS #set up design TS <- factor(TS, levels=c("Hog.7","Cran.7","LCM.7","OL.7", "Hog.23", "Cran.23", "OL.23", "LCM.23", "Hog.15")) design <- model.matrix(~0+TS) colnames(design) <- levels(TS) fit <- lmFit(Eavg, design) cont.matrix <- makeContrasts(Hog.7vs23=Hog.23-Hog.7, Cran.7vs23=Cran.23-Cran.7, LCM.7vs23=LCM.23-LCM.7, OL.7vs23=OL.23-OL.7, levels=design) fit2 <- contrasts.fit(fit, cont.matrix) fit2 <- eBayes(fit2) #check results topTable(fit2, coef=1, adjust="BH") results <- decideTests(fit2) vennCounts(results) vennDiagram(results) write.table (fit2, file="fit2.txt")
• 1.0k views
ADD COMMENT
0
Entering edit mode
@wolfgang-huber-3550
Last seen 10 days ago
EMBL European Molecular Biology Laborat…
Sep/21/11 4:12 AM, mrjmorri at ucalgary.ca scripsit:: > Hello, > > My name is Matthew Morris, I'm a second year Master's student at the > University of Calgary, and I am fairly new to the world of microarrays! > My project involves single-colour arrays, for which helpful documents seem > to be rather limited. Dear Matthew, there is in fact substantial documentation that has already been helpful to others. I suggest you have a look at some of it. Then I am sure your questions and their context will become clearer. In particular - the limma user's guide which comes with the package that you are using - the book http://www.bioconductor.org/help/publications/books/bioconductor-case- studies/ If this seems like a lot of work, don't despair, and type library("fortunes") fortune(122) Best wishes Wolfgang > > As such, I have some questions. I'll ask the questions first, and then > show you the code. If you can only answer one of the three, some info is > better than none! > > 1. How do I visualize my data pre- and post-normalization? What will I be > looking for? > > 2. I am using code from someone else to flag nonuniform and feature > population outliers. It certainly alters my results, but I'm not sure how > to check if it is working correctly. > > 3. How can I incorporate things like sex and length into my model? (to > clarify, I am looking at four populations of fish called Cran, Hog, OL and > LCM respectively, raised at 7 or 23 degrees, and I would like to eliminate > the effects of sex, tank and length) > > > Thank you very much, > Matthew Morris > > Code is as follows: > > library(limma) > > #read Targets file (make sure to set directory first through File) > targets<-readTargets("targets.txt") > > #checks that file was read correctly > targets$FileName > > #weight OL > > wtAgilent.mRGOLFilter<- function(qta) > {mapply(min,1-qta[,"gIsFeatNonUnifOL"],1-qta[,"gIsFeatNonUnifOL"],1- qta[,"gIsFeatPopnOL"],1-qta[,"gIsFeatPopnOL"])} > > #read data from array ouput files into E > E<-read.maimages(targets$FileName, > source="agilent.median",path="actualall", wt.fun=wtAgilent.mRGOLFilter, > columns=list(E="gProcessedSignal"), > other.columns=list(saturated="gIsSaturated", > nonuniform="gIsFeatNonUnifOL", popnoutlier="gIsFeatPopnOL", > flag="IsManualFlag", wellabovebg="gIsWellAboveBG")) > > #to see that everything looks fine > E > > #normalizing between arrays: > normalize<-normalizeBetweenArrays(E, method="quantile") > > > #remove control spots > dat1<-normalize[normalize$genes$ControlType==0,] > > #average values for identical probes within an array > Eavg<-avereps(dat1, ID=dat1$genes$ProbeName) > > > #analyze factorial design: first identify the factors in template > TS<- paste(targets$Population, targets$Temperature, sep=".") > > #check to see it worked > TS > > #set up design > TS<- factor(TS, levels=c("Hog.7","Cran.7","LCM.7","OL.7", "Hog.23", > "Cran.23", "OL.23", "LCM.23", "Hog.15")) > design<- model.matrix(~0+TS) > colnames(design)<- levels(TS) > fit<- lmFit(Eavg, design) > cont.matrix<- makeContrasts(Hog.7vs23=Hog.23-Hog.7, > Cran.7vs23=Cran.23-Cran.7, LCM.7vs23=LCM.23-LCM.7, OL.7vs23=OL.23-OL.7, > levels=design) > fit2<- contrasts.fit(fit, cont.matrix) > fit2<- eBayes(fit2) > > #check results > > topTable(fit2, coef=1, adjust="BH") > results<- decideTests(fit2) > vennCounts(results) > vennDiagram(results) > > write.table (fit2, file="fit2.txt") > > _______________________________________________ > 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 -- Wolfgang Huber EMBL http://www.embl.de/research/units/genome_biology/huber
ADD COMMENT

Login before adding your answer.

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