[BioC] Adding annotations to fit2 - still having problems
Sally
sagoldes at shaw.ca
Wed Feb 18 00:57:30 CET 2009
Hello,
I am using Limma for microarray analysis. Ultimately I want to
add/combine/append (not sure what word is correct) a file named MGL.txt
(mastergene list) to fit2 so that when topTable prints it will have the
annotation information for each gene. The first few lines of MGL.txt looks
like this (there are blank cells/missing data). There are 17,328 rows and 6
columns in this file.
well accession bitscore evalue symbol
U179971039 GFP
empty1 Blank Well
empty2 Blank Well
empty3 Blank Well
empty4 Blank Well
empty5 Blank Well
empty6 Blank Well
empty7 Blank Well
empty8 Blank Well
CA054869 UNKNOWN
CB490276 G2/mitotic-specific cyclin-B2 Q60FX9 524.24 3.58E-148 ccnb2
CA769480 Endothelial differentiation-related factor 1 homolog Q6PBY3
214.16 8.45E-55 edf1
MGL.txt was read in with:
MGLnew<-read.table(file="MGL.txt",sep="\t",header=TRUE,na.strings="",fill=TRUE,row.names=1)
When MGLnew is printed on screen it looks like this (first few lines)
accession bitscore evalue symbol
U179971039 <NA> NA NA <NA>
empty1 <NA> NA NA <NA>
empty2 <NA> NA NA <NA>
empty3 <NA> NA NA <NA>
empty4 <NA> NA NA <NA>
empty5 <NA> NA NA <NA>
empty6 <NA> NA NA <NA>
empty7 <NA> NA NA <NA>
empty8 <NA> NA NA <NA>
CA054869 <NA> NA NA <NA>
CB490276 Q60FX9 524.24 3.58e-148 ccnb2
CA769480 Q6PBY3 214.16 8.45e-55 edf1
When I then check the # of rows using nrow(MGLnew) it says there are 3312
rows, even though the original file had 17,328 rows.
Also it doesn't include the column "well" in MGLnew.
Why are these two things happening?
Sally Goldes
----- Original Message -----
From: "john seers (IFR)" <john.seers at bbsrc.ac.uk>
To: "Sally" <sagoldes at shaw.ca>; <bioconductor at stat.math.ethz.ch>
Sent: Tuesday, February 17, 2009 8:35 AM
Subject: RE: [BioC] Adding annotations to fit2
Hi Sally
Is fit2 by any chance the output from limma fitting a linear model? If
not this is not relevant.
If it is so I think you may be able to do something like
fit2$genes<-cbind(fit2$genes, MGLnew)
If that does not work, if you are using topTable a bit later, you can do
something like this:
tt<-topTable(eb, number=ngenes, genelist=cbind(eb$genes, MGLnew))
Regards
John
---
-----Original Message-----
From: bioconductor-bounces at stat.math.ethz.ch
[mailto:bioconductor-bounces at stat.math.ethz.ch] On Behalf Of Sally
Sent: 17 February 2009 03:35
To: bioconductor at stat.math.ethz.ch
Cc: Sally
Subject: [BioC] Adding annotations to fit2
I want merge fit2 with a txt file I'll call MGL (mastergenelist) which
contains gene id information. I am using a custom cDNA array. The
reason is that I want the gene ID information along-side the rownames
(which are the accession IDs). Both have identical row names. MGL has
missing data.
I have tried:
MGLnew<-read.table(file="MGL.txt",sep="\t",header=TRUE,na.strings="",fil
l=TRUE) #WORKS
write.table(MGLnew,file="MGLnew.txt",sep="\t") #WORKS
fit2<-merge(fit2,MGLnew,by="row.names") #NOT WORKING
When I run this I get the following error message:
Error in dim(data) <- dim : attempt to set an attribute on NULL
What does this error message mean? How do I fix the problem?
Sally Goldes
[[alternative HTML version deleted]]
_______________________________________________
Bioconductor mailing list
Bioconductor at stat.math.ethz.ch
https://stat.ethz.ch/mailman/listinfo/bioconductor
Search the archives:
http://news.gmane.org/gmane.science.biology.informatics.conductor
More information about the Bioconductor
mailing list