[BioC] subset eset by row broken
Kimpel, Mark William
mkimpel at iupui.edu
Sat May 13 18:33:17 CEST 2006
Martin, you were correct. I had performed an operation that corrupted the se.exprs slot. Since I never use this, I had forgotten about it.
Thanks,
Mark
Mark W. Kimpel MD
(317) 490-5129 Home, Work, & Mobile
1-(317)-536-2730 FAX
-----Original Message-----
From: Martin Morgan [mailto:mtmorgan at fhcrc.org]
Sent: Saturday, May 13, 2006 10:24 AM
To: Kimpel, Mark William
Cc: Bioconductor Newsgroup
Subject: Re: [BioC] subset eset by row broken
Hi Mark --
The basic functionality works in Biobase
> sessionInfo()
Version 2.3.0 Patched (2006-04-24 r37913)
x86_64-unknown-linux-gnu
attached base packages:
[1] "tools" "methods" "stats" "graphics" "grDevices" "utils"
[7] "datasets" "base"
other attached packages:
Biobase
"1.10.0"
> data(sample.exprSet)
> sample.exprSet[1:5,]
Expression Set (exprSet) with
5 genes
26 samples
phenoData object with 3 variables and 26 cases
varLabels
sex: Female/Male
type: Case/Control
score: Testing Score
so the problem is a little deeper. Other elements of your exprSet may
be malformed. The following should both work:
se.exprs(sample.exprSet)[1:5,]
reporterInfo(sample.exprSet)[1:5,]
My guess is that it's the se.exprs that is causing problems. If these
measures are unimportant, then, in your case,
se.exprs(eset) <- matrix(nrow=0,ncol=59)
will replace what you currently have with a matrix that indicates to
exprSet that it has no information. If the se.exprs *are* important,
then we'll need more information about how the exprSet was created, to
figure out where the malformed entry is coming from.
Hope that helps.
Martin
--
Bioconductor
"Kimpel, Mark William" <mkimpel at iupui.edu> writes:
> Tonight one of my functions suddenly stopped working and I have
> traced the problem to not being able to subset esets by row as I
> previously could. Thus, eset[1:5,] yields an error "subscript out of
> bounds", whereas, eset[,1:5] does not. See below for a concrete
> example with output and sessionInfo(). Thanks, Mark
>
>> eset
> Expression Set (exprSet) with
> 119 genes
> 59 samples
> phenoData object with 4 variables and 59 cases
> varLabels
> sampleNames: read from file
> Strain: read from file
> Region: read from file
> Animal: read from file
>> eset[1:5,]
> Error in eset[1:5, ] : subscript out of bounds
>> eset[,1:5]
> Expression Set (exprSet) with
> 119 genes
> 5 samples
> phenoData object with 4 variables and 5 cases
> varLabels
> sampleNames: read from file
> Strain: read from file
> Region: read from file
> Animal: read from file
>> exprs(eset)[1:5, 1:5]
> WS02R111.CEL WS02R112.CEL WS02R113.CEL WS02R114.CEL WS02R115.CEL
> L07074_at 10.218309 10.270285 10.502409 10.735885 10.374594
> U53873cds_at 6.589952 6.720901 6.503514 6.347453 6.507239
> M85193_at 9.341253 9.159996 9.116925 9.184803 9.170827
> U72349_at 8.169101 7.628983 8.136620 7.878559 8.049834
> rc_AA800265_at 6.603026 6.621253 5.902590 6.437841 6.394334
>> sessionInfo()
> Version 2.3.0 (2006-04-24)
> i386-pc-mingw32
>
> attached base packages:
> [1] "splines" "tools" "methods" "stats" "graphics" "grDevices" "utils" "datasets" "base"
>
> other attached packages:
> genefilter rgu34a multtest survival affy affyio Biobase RWinEdt
> "1.10.1" "1.12.0" "1.9.5" "2.24" "1.10.0" "1.0.0" "1.10.0" "1.7-4"
> Mark W. Kimpel MD
>
>
> Official Business Address:
>
> Department of Psychiatry
> Indiana University School of Medicine
> Biotechnology, Research, & Training Center
> 1345 W. 16th Street
> Indianapolis, IN 46202
>
> Preferred Mailing Address:
>
> 15032 Hunter Court
> Westfield, IN 46074
>
> (317) 490-5129 Home, Work, & Mobile
> 1-(317)-536-2730 FAX
>
> _______________________________________________
> 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