Neil, I apologize. This is actually in the v2.2 documentation: http://www.bioconductor.org/packages/2.2/bioc/vignettes/Biobase/inst/doc/ExpressionSetIntroduction.pdf which is where Google search takes you. I will edit my question and update the link.
EDIT 2011-06-19: Apparently I was looking at an old version (2.2) of the document "An Introduction to Bioconductor's ExpressionSet Class". Apparently the new documentation does not have this feature, which is unfortunate. I still wonder if this is a regression (bug) or intended.
Original question: I have followed the document "An Introduction to Bioconductor's ExpressionSet Class", and everything meshed until I got to using the phenotypic data and metadata to create an AnnotatedDataFrame, at the end of Section 4.2 Phenotypic Data. The document has this R code:
> phenoData <- new("AnnotatedDataFrame", data = pData,
+ varMetadata = metadata)
> phenoData
An object of class "AnnotatedDataFrame"
rowNames: A, B, ..., Z (26 total)
varLabels and varMetadata description:
gender: Patient gender
type: Case/control status
score: Tumor progress on XYZ scale
But I get this:
> phenoData
An object of class "AnnotatedDataFrame"
rowNames: A B ... Z (26 total)
varLabels: gender type score
varMetadata: labelDescription
That is, the label descriptors are not printed with the labels.
Is there a change/regression in the AnnotatedDataFrame since this document was last edited in 2007, or is this particular to my platform? I'm using R 2.12.1 on Ubuntu 11.04 32-bit, Biobase version 2.10.0 (installed today, 2011-06-17).
1 answer
I'm a little confused by this question since in the PDF document, I cannot see the text from your first example but I can see the second example. Searching the PDF for "varLabels", I don't see the line "varLabels and varMetadata description".
My answer is that no, there is nothing particular to your platform and the second example is the "expected" behaviour for recent versions of Bioconductor. I tried this on my machine:
library(Biobase)
data(sample.ExpressionSet)
phenoData(sample.ExpressionSet)
# An object of class "AnnotatedDataFrame"
# sampleNames: A B ... Z (26 total)
# varLabels: sex type score
# varMetadata: labelDescription
To see the labels and descriptions together:
varMetadata(phenoData(sample.ExpressionSet))
# labelDescription
# sex Female/Male
# type Case/Control
# score Testing Score
Log in to answer this question.