[BioC] create an new AnnotatedDataFrame
GHAVI-HELM Yad
yad.ghavi-helm at cea.fr
Wed Aug 8 14:12:41 CEST 2007
Hi all,
I am trying to make an AnnotatedDataFrame with the Biobase package.
Here is my code:
exprsFile<-"D:/exprsData.txt"
exprs<-read.table(exprsFile,header=TRUE,sep="",as.is=TRUE)
pDataFile<-"D:/pData.txt"
pData<-read.table(pDataFile,header=TRUE, sep="", as.is=TRUE)
metaData<-"D:/mData.txt"
mData<-read.table(metaData,header=TRUE,sep="",as.is=TRUE)
metData<-new("AnnotatedDataFrame",data=exprs2,varMetadata=mData)
At this step I have the following error:
Error in `row.names<-.data.frame`(`*tmp*`, value = c("A", "B")) :
length of 'row.names' incorrect
It seems strangle because "A" and "B" are the colnames of exprsData (or the rownames of pData).
I tried to do :
metData<-new("AnnotatedDataFrame",data=exprs2,varMetadata=mData, row.names=1)
or
rown=rownames(exprs)
metData<-new("AnnotatedDataFrame",data=exprs2,varMetadata=mData, row.names=rown)
but I steel got the same error
hope anyone could help me...
> sessionInfo()
R version 2.5.0 (2007-04-23)
i386-pc-mingw32
locale:
LC_COLLATE=French_France.1252;LC_CTYPE=French_France.1252;LC_MONETARY=French_France.1252;LC_NUMERIC=C;LC_TIME=French_France.1252
attached base packages:
[1] "tcltk" "splines" "tools" "stats" "graphics" "grDevices" "utils" "datasets" "methods" "base"
other attached packages:
YEAST convert marray tkWidgets DynDoc widgetTools arrayMagic genefilter survival vsn affy affyio limma
"1.16.0" "1.10.0" "1.14.0" "1.14.0" "1.14.0" "1.12.0" "1.14.0" "1.14.1" "2.31" "2.2.0" "1.14.2" "1.4.1" "2.10.5"
Biobase
"1.14.1"
Yad.
More information about the Bioconductor
mailing list