[BioC] Does old workspace work?
Loren Engrav
engrav at u.washington.edu
Fri Oct 31 19:51:03 CET 2008
Actually exprs(obj) does show, indented, sorry
Thank you, got it
exprs(obj) is missing from the output but shows in ?ExpressionSet and puts
up the data so I can see it
And now perhaps one final question to understanding this old data and
progress
Long long ago I did
AA_ReadAffy <- ReadAffy()
ABeset_gcrma < gcrma (AA_ReadAffy)
Now I do
AA_ReadAffy081031 <- ReadAffy() #on the same .cel files
ABeset_gcrma081031 <- gcrma (AA_ReadAffy081031)
Then I do
Show(ABeset_gcrma) and exprs(ABeset_gcrma081031)
And they do not match, for example
Probe set Ssc.10026.1.A1_at
ABeset_gcrma is 4.124689
ABeset_gcrma081031 is 3.344443
ReadAffy changed?
gcrma changed?
> From: Martin Morgan <mtmorgan at fhcrc.org>
> Organization: Fred Hutchinson Cancer Research Center
> Date: Fri, 31 Oct 2008 11:08:06 -0700
> To: Loren Engrav <engrav at u.washington.edu>
> Cc: "bioconductor at stat.math.ethz.ch" <bioconductor at stat.math.ethz.ch>
> Subject: Re: [BioC] Does old workspace work?
>
> Loren Engrav wrote:
>> Got it, thank you
>> So the new ExpressionSets are Ok, cool
>> But one thing as I am still exploring the old data and the new
>> If I do show(obj) with the old exprSet I can see the data in the file
>> If I do show(obj) with the new ExpressionSet I just get a summary
>> How do I show(obj) and see the data in the new ExpressionSet
>> I checked ?show and google but could not find the answer
>
>> library(Biobase)
>> data(sample.ExpressionSet)
>> obj <- sample.ExpressionSet # easier to type#
>> obj
> ExpressionSet (storageMode: lockedEnvironment)
> assayData: 500 features, 26 samples
> element names: exprs, se.exprs
> phenoData
> sampleNames: A, B, ..., Z (26 total)
> varLabels and varMetadata description:
> sex: Female/Male
> type: Case/Control
> score: Testing Score
> featureData
> featureNames: AFFX-MurIL2_at, AFFX-MurIL10_at, ..., 31739_at (500 total)
> fvarLabels and fvarMetadata description: none
> experimentData: use 'experimentData(object)'
> Annotation: hgu95av2
>
> The output is meant to suggest how to access elements, e.g.,
>
>> assayData(obj)
> <environment: 0xf00858>
>> assayData(obj)
> <environment: 0xf00858>
>> sampleNames(obj)
> [1] "A" "B" "C" "D" "E" "F" "G" "H" "I" "J" "K" "L" "M" "N" "O" "P"
> "Q" "R" "S"
> [20] "T" "U" "V" "W" "X" "Y" "Z"
>> phenoData(obj)
> An object of class "AnnotatedDataFrame"
> sampleNames: A, B, ..., Z (26 total)
> varLabels and varMetadata description:
> sex: Female/Male
> type: Case/Control
> score: Testing Score
>
> details are on ?ExpressionSet and related classes.
>
> Martin
>
>>> sessionInfo()
>> R version 2.8.0 Patched (2008-10-26 r46783)
>> i386-apple-darwin9.5.0
>>
>> locale:
>> C
>>
>> attached base packages:
>> [1] tools stats graphics grDevices utils datasets methods
>> base
>>
>> other attached packages:
>> [1] Biobase_2.2.0
>>
>>
>>
>>> From: Martin Morgan <mtmorgan at fhcrc.org>
>>> Date: Thu, 30 Oct 2008 15:42:44 -0700
>>> To: Loren Engrav <engrav at u.washington.edu>
>>> Cc: "bioconductor at stat.math.ethz.ch" <bioconductor at stat.math.ethz.ch>
>>> Subject: Re: [BioC] Does old workspace work?
>>>
>>> Loren Engrav wrote:
>>>> Thank you
>>>>
>>>> str(obj) returned
>>>> @ se.exprs : num [0 , 0]
>>>> so I guess there were none
>>>>
>>>> I find on the web se.exprs is/was standard error estimates
>>>>
>>>> The old object came in Jan Feb Mar of 2007 as below
>>>>
>>>> AA_ReadAffy <- ReadAffy() to read 60 Affy .cel files
>>>> ABeset_gcrma <- gcrma (AA_ReadAffy) to gcrma it
>>>>
>>>> After the above I went on and did library (maanova) stuff
>>>>
>>>> Does it matter if the old ABeset_gcrma object had no std error estimates?
>>> Few downstream steps made use of the standard errors, and many upstream
>>> methods (including gcrma) didn't / couldn't produce standard errors.
>>>
>>> Martin
>>>
>>>>> From: Martin Morgan <mtmorgan at fhcrc.org>
>>>>> Date: Thu, 30 Oct 2008 13:33:55 -0700
>>>>> To: Loren Engrav <engrav at u.washington.edu>
>>>>> Cc: "bioconductor at stat.math.ethz.ch" <bioconductor at stat.math.ethz.ch>
>>>>> Subject: Re: [BioC] Does old workspace work?
>>>>>
>>>>> Hi Loren --
>>>>>
>>>>> Loren Engrav <engrav at u.washington.edu> writes:
>>>>>
>>>>>> With the show(obj) function and the write.table function, I can see the
>>>>>> stuff in the old objects so that may solve the immediate problem
>>>>>>
>>>>>> But changing exprSet to ExpressionSet is attractive
>>>>>> And I see it has been discussed before (see below)
>>>>>>
>>>>>> ===========================
>>>>>> [BioC] Error loading, on Bioconductor 1.8, exprSet generated with
>>>>>> bioconductor 1.7
>>>>>> Martin Morgan mtmorgan at fhcrc.org
>>>>>> Thu Jun 8 18:11:14 CEST 2006
>>>>>>
>>>>>> Previous message: [BioC] Error loading, on Bioconductor 1.8,
>>>>>> exprSet generated with bioconductor 1.7
>>>>>> Next message: [BioC] [SPAM] Re: Error loading, on Bioconductor
>>>>>> 1.8,
>>>>>> exprSet generated with bioconductor 1.7
>>>>>> Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
>>>>>>
>>>>>> Hi Raf,
>>>>>>
>>>>>> Thanks for the clarification. It sounds like you've found a good
>>>>>> solution.
>>>>>>
>>>>>> The long-term intention is to move away from exprSet as the basic
>>>>>> building block, and toward a similar 'ExpressionSet' class. With this
>>>>>> in mind, you could also have done (with the current version of
>>>>>> Biobase)
>>>>>>
>>>>>>> obj <- as(tr7.rma, "ExpressionSet")
>>>>>> to obtain an ExpressionSet from your (broken) exprSet. An
>>>>>> ExpressionSet has methods like exprs(), phenoData(), and pData() that
>>>>>> work as exprSet methods, so for many purposes having an ExpressionSet
>>>>>> is a great replacement for exprSet.
>>>>>>
>>>>>> It's important to be able to return to previous versions of objects,
>>>>>> and make them 'current'. To that end, the development version of
>>>>>> Biobase introduces ways of 'versioning' objects (so that it's easy to
>>>>>> figure out when the object was created) and an 'updateObject' method
>>>>>> to bring an object up to date. So in the next release of Biobase
>>>>>> (available to those already using the 'development' branch of R)
>>>>>> you'll be able to
>>>>>>
>>>>>>> obj <- updateObject(tr76.rma)
>>>>>> and stand a reasonable chance of getting an object that satisfies the
>>>>>> current definition of exprSet.
>>>>>> =============================================
>>>>>>
>>>>>> So I try
>>>>>>> ABeset_gcrmaExpressionSet <- as (ABeset_gcrma, "ExpressionSet")
>>>>>> And get
>>>>>>
>>>>>> Loading required package: Biobase
>>>>>> Loading required package: tools
>>>>>>
>>>>>> Welcome to Bioconductor
>>>>>>
>>>>>> Vignettes contain introductory material. To view, type
>>>>>> 'openVignette()'. To cite Bioconductor, see
>>>>>> 'citation("Biobase")' and for packages 'citation(pkgname)'.
>>>>>>
>>>>>> Warning message:
>>>>>> In asMethod(object) :
>>>>>> missing or mis-shaped 'se.exprs' in original object; creating
>>>>>> ExpressionSet without se.exprs
>>>>> At this point I think ABeset_gcrmaExpressionSet is fine; this is a
>>>>> 'warning' message, not an error. The exprSet instance was 'supposed'
>>>>> to contain an se.exprs matrix, but my guess is that ABeset_gcrma did
>>>>> not (many exprSet instances did not). You might have luck with
>>>>>
>>>>>> str(ABeset_gcrma)
>>>>> you might see something like (it's a little hard to recreate this on
>>>>> 2.8.0)
>>>>>
>>>>> Formal class 'exprSet' [package "Biobase"] with 8 slots
>>>>> ..@ exprs : num [1:500, 1:26] 192.7 97.1 45.8
>>>>> .. ..- attr(*, "dimnames")=List of 2
>>>>> .. .. ..$ : chr [1:500] "AFFX-MurIL2_at" "AFFX-MurIL10_at"
>>>>> .. .. ..$ : chr [1:26] "A" "B" "C" "D" ...
>>>>> ..@ se.exprs : num [1:500, 1:26] 2.85 3.24 3.05
>>>>> .. ..- attr(*, "dimnames")=List of 2
>>>>> .. .. ..$ : chr [1:500] "AFFX-MurIL2_at" "AFFX-MurIL10_at"
>>>>> .. .. ..$ : chr [1:26] "A" "B" "C" "D" ...
>>>>>
>>>>> etc if se.exprs has dimensions 0 (instead of 'chr [1:500]' and 'chr
>>>>> [1:26]' in the example above) then the se.exprs was missing or empty
>>>>> and hence its loss not important. If it's not missing, then you can
>>>>> decide how aggressively you want to rehabilitate your data. Likely
>>>>> you'll be able to retrieve the se.exprs with
>>>>>
>>>>>> se <- slot(ABeset_gcrma, "se.exprs")
>>>>> manipulate it to have the same dimenions and dimnames as your
>>>>> ExpressionSet has, and add it, e.g.,
>>>>>
>>>>>> assayData(ABeset_gcrmaExpressionSet)[["se.exprs"]] <- se
>>>>> I think normally you'll not have to go through these steps though, the
>>>>> se.exprs of exprSet will have had no data in it.
>>>>>
>>>>>> Then I try
>>>>>>> ABeset_gcrmaUPDATE <- updateObject(ABeset_gcrma)
>>>>>> And get
>>>>>> Error in updateObjectFromSlots(object, ..., verbose = verbose) :
>>>>>> could not updateObject to class 'phenoData'
>>>>>> consider defining an 'updateObject' method for class 'phenoData'
>>>>> updateObject is meant to update 'within a class', e.g., from an old
>>>>> version of ExpressionSet to a new version of ExpressionSet. Use 'as'
>>>>> and you are probably ok.
>>>>>
>>>>> There may be issues, especially with very old exprSets, so let me know
>>>>> if you have problems.
>>>>>
>>>>> Martin
>>>>>
>>>>>
>>>>>> All with
>>>>>>> sessionInfo()
>>>>>> R version 2.8.0 Patched (2008-10-26 r46783)
>>>>>> i386-apple-darwin9.5.0
>>>>>>
>>>>>> locale:
>>>>>> C
>>>>>>
>>>>>> attached base packages:
>>>>>> [1] tools stats graphics grDevices utils datasets methods
>>>>>> base
>>>>>>
>>>>>> other attached packages:
>>>>>> [1] Biobase_2.2.0
>>>>>>
>>>>>>> .Machine$sizeof.pointer
>>>>>> [1] 8
>>>>>>
>>>>>> Now since I can "see" the data with show and write.table I should
>>>>>> probably
>>>>>> quit, but for the fun of it, are either of these messages a "quick fix"
>>>>>> for
>>>>>> a novice?
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> From: Robert Gentleman <rgentlem at fhcrc.org>
>>>>>>> Date: Tue, 28 Oct 2008 11:57:36 -0700
>>>>>>> To: Loren Engrav <engrav at u.washington.edu>
>>>>>>> Cc: "bioconductor at stat.math.ethz.ch" <bioconductor at stat.math.ethz.ch>
>>>>>>> Subject: Re: [BioC] Does old workspace work?
>>>>>>>
>>>>>>> -----BEGIN PGP SIGNED MESSAGE-----
>>>>>>> Hash: SHA1
>>>>>>>
>>>>>>> Re the quality of the link: You need to ask the owner, not this list
>>>>>>>
>>>>>>> and the answer to your second question is that it depends on what you
>>>>>>> want to catch up on. Ideally packages should have up to date vignettes,
>>>>>>> and they are your main starting point. Contact maintainers if the
>>>>>>> vignettes are incomplete or out of date.
>>>>>>>
>>>>>>> best wishes
>>>>>>> Robert
>>>>>>>
>>>>>>> Loren Engrav wrote:
>>>>>>>> Ok, I can deal with change
>>>>>>>>
>>>>>>>> One more question, to learn about and deal with the deprecated stuff
>>>>>>>>
>>>>>>>> Is the file at the url below current, or out of date?
>>>>>>>>
>>>>>>>>
>>>> http://faculty.ucr.edu/~tgirke/Documents/R_BioCond/R_BioCondManual.html#Bio
>>>> >>
>>>> C
>>>>>>>> primer
>>>>>>>>
>>>>>>>> If it is out of date, is there a better url to catch up fast?
>>>>>>>>
>>>>>>>>> From: Robert Gentleman <rgentlem at fhcrc.org>
>>>>>>>>> Date: Tue, 28 Oct 2008 09:56:31 -0700
>>>>>>>>> To: Loren Engrav <engrav at u.washington.edu>
>>>>>>>>> Cc: "bioconductor at stat.math.ethz.ch" <bioconductor at stat.math.ethz.ch>
>>>>>>>>> Subject: Re: [BioC] Does old workspace work?
>>>>>>>>>
>>>>>>>> Loren Engrav wrote:
>>>>>>>>>>> Ok, I will get my stuff modern
>>>>>>>>>>> One more question
>>>>>>>>>>> Those old saved workspaces and histories might be 32bit from before
>>>>>>>>>>> I
>>>>>>>>>>> went
>>>>>>>>>>> to 64bit
>>>>>>>>>>> If they are 32bit workspaces will they work in 64bit (save for the
>>>>>>>>>>> deprecated stuff)
>>>>>>>> Currently that is the case. But I am not sure how long it will
>>>>>>>> remain
>>>>>>>> so, as it means that R cannot be truly 64bit, so likely in the next
>>>>>>>> year
>>>>>>>> or so some change will be needed. Of course, one will always be able
>>>>>>>> to
>>>>>>>> read 32 bit workspaces in 64bits, but the converse will not likely hold
>>>>>>>> for very much longer
>>>>>>>>
>>>>>>>> Robert
>>>>>>>>
>>>>>>>>
>>>>>>>>>>>> From: Robert Gentleman <rgentlem at fhcrc.org>
>>>>>>>>>>>> Date: Mon, 27 Oct 2008 22:31:21 -0700
>>>>>>>>>>>> To: Loren Engrav <engrav at u.washington.edu>
>>>>>>>>>>>> Cc: "bioconductor at stat.math.ethz.ch"
>>>>>>>>>>>> <bioconductor at stat.math.ethz.ch>
>>>>>>>>>>>> Subject: Re: [BioC] Does old workspace work?
>>>>>>>>>>>>
>>>>>>>>>>>> Hi,
>>>>>>>>>>>>
>>>>>>>>>>>> Loren Engrav wrote:
>>>>>>>>>>>> sessionInfo()
>>>>>>>>>>>> R version 2.8.0 Patched (2008-10-26 r46783)
>>>>>>>>>>>> i386-apple-darwin9.5.0
>>>>>>>>>>>>
>>>>>>>>>>>> locale:
>>>>>>>>>>>> en_US.UTF-8/en_US.UTF-8/C/C/en_US.UTF-8/en_US.UTF-8
>>>>>>>>>>>>
>>>>>>>>>>>> attached base packages:
>>>>>>>>>>>> [1] splines tools stats graphics grDevices utils
>>>>>>>>>>>> datasets
>>>>>>>>>>>> methods base
>>>>>>>>>>>>
>>>>>>>>>>>> other attached packages:
>>>>>>>>>>>> [1] simpleaffy_2.18.0 genefilter_1.22.0 survival_2.34-1
>>>>>>>>>>>> affyio_1.10.0
>>>>>>>>>>>> porcinecdf_2.3.0 gcrma_2.14.0 matchprobes_1.14.0
>>>>>>>>>>>> affy_1.20.0
>>>>>>>>>>>> Biobase_2.2.0
>>>>>>>>>>>>
>>>>>>>>>>>> loaded via a namespace (and not attached):
>>>>>>>>>>>> [1] AnnotationDbi_1.4.0 DBI_0.2-4 RSQLite_0.7-1
>>>>>>>>>>>> annotate_1.20.0 preprocessCore_1.4.0
>>>>>>>>>>>>
>>>>>>>>>>>> ==============
>>>>>>>>>>>> A year or so ago I ran 64bit R on Mac PPC and saved various
>>>>>>>>>>>> workspaces
>>>>>>>>>>>>
>>>>>>>>>>>> Now am running 64bit R on Intel 2x3.2 QuadCore and MacOS 10.5.5
>>>>>>>>>>>>
>>>>>>>>>>>> I load up the old workspaces
>>>>>>>>>>>> and I enter
>>>>>>>>>>>>
>>>>>>>>>>>> write.exprs(ABeset_gcrma, file="ABeset_gcrma081028orig.txt")
>>>>>>>>>>>> Where ABeset_gcrma is an old file
>>>>>>>>>>>>
>>>>>>>>>>>> and I get
>>>>>>>>>>>> Error in function (classes, fdef, mtable) :
>>>>>>>>>>>> unable to find an inherited method for function "write.exprs", for
>>>>>>>>>>>> signature
>>>>>>>>>>>> "exprSet"
>>>>>>>>>>>>
>>>>>>>>>>>> It was probably more than a year ago - the exprSet class was
>>>>>>>>>>>> deprecated and subsequently made defunct.
>>>>>>>>>>>>
>>>>>>>>>>>> You could try to do:
>>>>>>>>>>>> library(Biobase)
>>>>>>>>>>>>
>>>>>>>>>>>> updateObject(ABeset_gcrma)
>>>>>>>>>>>>
>>>>>>>>>>>> failing that, you can try something like
>>>>>>>>>>>> write.table(ABeset_gcrma at exprs,
>>>>>>>>>>>> file="ABeset_gcrma081028orig.txt",uote = FALSE, sep = "\t",
>>>>>>>>>>>> col.names = NA)
>>>>>>>>>>>>
>>>>>>>>>>>> or something like that.
>>>>>>>>>>>>
>>>>>>>>>>>> And I enter
>>>>>>>>>>>> exprs2excel(ABeset_gcrma, file="ABeset_gcrma081028v2.csv")
>>>>>>>>>>>> And I get
>>>>>>>>>>>> Error: could not find function "exprs2excel"
>>>>>>>>>>>> That function has been made defunct.
>>>>>>>>>>>> Am I doing something wrong?
>>>>>>>>>>>> No, you just can't expect that things won't change.
>>>>>>>>>>>>
>>>>>>>>>>>> best wishes
>>>>>>>>>>>> Robert
>>>>>>>>>>>>
>>>>>>>>>>>> Thank you
>>>>>>>>>>>>
>>>>>>>>>>>> _______________________________________________
>>>>>>>>>>>> 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
>>>>>>>>>>>>
>>>>>>>>>>>> --
>>>>>>>>>>>> Robert Gentleman, PhD
>>>>>>>>>>>> Program in Computational Biology
>>>>>>>>>>>> Division of Public Health Sciences
>>>>>>>>>>>> Fred Hutchinson Cancer Research Center
>>>>>>>>>>>> 1100 Fairview Ave. N, M2-B876
>>>>>>>>>>>> PO Box 19024
>>>>>>>>>>>> Seattle, Washington 98109-1024
>>>>>>>>>>>> 206-667-7700
>>>>>>>>>>>> rgentlem at fhcrc.org
>>>>>>>>>>> _______________________________________________
>>>>>>>>>>> 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
>>>>>>>>>>>
>>>>>>>> _______________________________________________
>>>>>>>> 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
>>>>>>> -----BEGIN PGP SIGNATURE-----
>>>>>>> Version: GnuPG v2.0.9 (GNU/Linux)
>>>>>>> Comment: Using GnuPG with SUSE - http://enigmail.mozdev.org
>>>>>>>
>>>>>>> iEYEARECAAYFAkkHYKAACgkQ6fE3kSKck1NjswCfQmXWj+2ny14EFrCB+4eNinxo
>>>>>>> kOkAnRAK5j9/K01A3zHf80OR2akCmL6P
>>>>>>> =NtCJ
>>>>>>> -----END PGP SIGNATURE-----
>>>>>> _______________________________________________
>>>>>> 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
>>>>> --
>>>>> Martin Morgan
>>>>> Computational Biology / Fred Hutchinson Cancer Research Center
>>>>> 1100 Fairview Ave. N.
>>>>> PO Box 19024 Seattle, WA 98109
>>>>>
>>>>> Location: Arnold Building M2 B169
>>>>> Phone: (206) 667-2793
>>>> _______________________________________________
>>>> 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
>>
>> _______________________________________________
>> 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
>
>
> --
> Martin Morgan
> Computational Biology / Fred Hutchinson Cancer Research Center
> 1100 Fairview Ave. N.
> PO Box 19024 Seattle, WA 98109
>
> Location: Arnold Building M2 B169
> Phone: (206) 667-2793
More information about the Bioconductor
mailing list