[BioC] error retrieving normalized probe values from "pm" array
Lana Schaffer
schaffer at scripps.edu
Mon Jun 30 19:45:25 CEST 2008
Greetings,
R version 2.7.0 (2008-04-22)
i386-pc-mingw32
I am retrieving the probe indexes using the indexProbes function
for each of the gene names.
nbatch <- normalize.AffyBatch.quantiles(abatch,type="pmonly")
gn <- geneNames(nbatch)
gene_indexes <- indexProbes(nbatch, which="pm", genenames=gn)
I found that I need to cast the indexes as.character to retrieve
the normalized pm values.
log2(pm(nbatch)[as.character(gene_indexes[[i]]),])
Actually I am using an lapply function:
LG <- function(x, ma) {
return(log2(ma[as.character(x),])) }
LIGC <- lapply(Rpm , LG, ma=pm(nbatch))
This worked until I ran into an error at index=100000 because it was
converted to "1e+05" and
log2(pm(nbatch)[as.character(gene_indexes[[374]]),])
Error: subscript out of bounds
> as.character(gene_indexes[[374]])
[1] "24439" "3897" "1e+05" "29082" "53595" "53100" "65653"
"13262"
[9] "45563" "29747" "29735" "105476" "46438" "83596" "23127"
"36490"
[17] "105458" "16956" "98869" "74954" "23587"
Can someone suggest something get me thru this problem?
Thanks,
Lana Schaffer
Biostatistics/Informatics
The Scripps Research Institute
DNA Array Core Facility
La Jolla, CA 92037
(858) 784-2263
(858) 784-2994
schaffer at scripps.edu
More information about the Bioconductor
mailing list