Question: Error message (probably) from AffyBatch.R when using a modified CDF
0
gravatar for Hugh Shanahan
6.7 years ago by
Hugh Shanahan50 wrote:
We are writing a new R package to construct CDF's with particular subsets of probes removed. We are building the CDF packages using a modification of makecdfenv. Up until recently, everything has been working fine when we update the CDF library name of an expression set, i.e. > raw <- ReadAffy() > raw at cdfName <- "hgu133ag4" > eSet <- rma(raw) Having upgraded to R 2.15.2 and now using the most up to date libraries of bioconductor 2.10 (i.e. doing a clean install on a new (Windows) machine generates an error which has cropped over the years, namely if we try to run a normalisation step (such as above) then we get the following error (the same error occurs with other normalisations such as rma) :- > eSet <- rma(raw) Attaching package: hgu133ag4cdf The following object(s) are masked from package:hgu133acdf: i2xy, xy2i Error in ans[[i]][, i.probes] : incorrect number of dimensions The problem appears to occur in indexProbes which is part of the affy package (AffyBatch.R to be precise), which first gets the environment associated with the expression set, envir <- getCdfInfo(object) genenames <- ls(envir) ans <- mget(genenames, envir, ifnotfound=NA) so that ans should be a list with names of affy id's and each entry is a two column data frame with entries for the pm and mm probe locations. The only possibility when the error is occurring is when the following is called tmp <- as.vector(ans[[i]][, i.probes]) which suggests that ans is not in this format when it gets to this line. The problem is, I can't reproduce the error if I use the source code of AffyBatch.R . Any ideas on how I can check that this hypothesis is correct ? Any ideas how I can fix this ? It looks as if this error has occurred a number of times over the years, but there never seems to be a complete solution... Many thanks
cdf affy makecdfenv • 591 views
ADD COMMENTlink modified 6.7 years ago by James W. MacDonald51k • written 6.7 years ago by Hugh Shanahan50
Answer: Error message (probably) from AffyBatch.R when using a modified CDF
0
gravatar for James W. MacDonald
6.7 years ago by
United States
James W. MacDonald51k wrote:
Hi Hugh, On 1/23/2013 4:06 PM, Hugh Shanahan wrote: > We are writing a new R package to construct CDF's with particular subsets of probes removed. We are building the CDF packages using a modification of makecdfenv. > Up until recently, everything has been working fine when we update the CDF library name of an expression set, i.e. >> raw<- ReadAffy() >> raw at cdfName<- "hgu133ag4" >> eSet<- rma(raw) > Having upgraded to R 2.15.2 and now using the most up to date libraries of bioconductor 2.10 (i.e. doing a clean install on a new (Windows) machine generates an error > which has cropped over the years, namely if we try to run a normalisation step (such as above) then we get the following error (the same error occurs with other normalisations such as rma) :- > >> eSet<- rma(raw) > > Attaching package: hgu133ag4cdf > > The following object(s) are masked from package:hgu133acdf: > > i2xy, xy2i > > Error in ans[[i]][, i.probes] : incorrect number of dimensions > > The problem appears to occur in indexProbes which is part of the affy package (AffyBatch.R to be precise), which first gets the environment associated with the expression set, > > envir<- getCdfInfo(object) > > genenames<- ls(envir) > > ans<- mget(genenames, envir, ifnotfound=NA) > > so that ans should be a list with names of affy id's and each entry is a two column data frame with entries for the pm and mm probe locations. > > The only possibility when the error is occurring is when the following is called > > tmp<- as.vector(ans[[i]][, i.probes]) > > which suggests that ans is not in this format when it gets to this line. The problem is, I can't reproduce the error if I use the source code of AffyBatch.R . > Any ideas on how I can check that this hypothesis is correct ? Any ideas how I can fix this ? It looks as if this error has occurred a number of times over the years, but there never seems to be a complete solution... I don't know what you mean by 'I use the source code of AffyBatch.R'. Anyway, there are at least two things you can do. First, ans <- mget(ls(hgu133ag4cdf), ifnotfound = NA) table(sapply(ans, nrow)) and see if you have any probesets with < 2 rows. Or you can use options(error = recover) and then do whatever will trigger the error. You will then be given a choice of frames to enter. You can enter each one and see what e.g. i.probes, and ans[[i]] look like, which might help figure out what the problem is. Best, Jim > > Many thanks > > _______________________________________________ > Bioconductor mailing list > Bioconductor at r-project.org > https://stat.ethz.ch/mailman/listinfo/bioconductor > Search the archives: http://news.gmane.org/gmane.science.biology.informatics.conductor -- James W. MacDonald, M.S. Biostatistician University of Washington Environmental and Occupational Health Sciences 4225 Roosevelt Way NE, # 100 Seattle WA 98105-6099
ADD COMMENTlink written 6.7 years ago by James W. MacDonald51k
Okay - the problem is fixed now. The trouble was that the filter was occasionally leaving only one probe in the probe set and entry was no longer regarded having the same dimensions as a matrix. Thank you ! Hugh ----- Original Message ----- From: "James W. MacDonald" <jmacdon@uw.edu> To: "Hugh Shanahan" <hugh at="" cs.rhul.ac.uk=""> Cc: bioconductor at r-project.org Sent: Thursday, 24 January, 2013 3:42:51 PM Subject: Re: [BioC] Error message (probably) from AffyBatch.R when using a modified CDF Hi Hugh, On 1/23/2013 4:06 PM, Hugh Shanahan wrote: > We are writing a new R package to construct CDF's with particular subsets of probes removed. We are building the CDF packages using a modification of makecdfenv. > Up until recently, everything has been working fine when we update the CDF library name of an expression set, i.e. >> raw<- ReadAffy() >> raw at cdfName<- "hgu133ag4" >> eSet<- rma(raw) > Having upgraded to R 2.15.2 and now using the most up to date libraries of bioconductor 2.10 (i.e. doing a clean install on a new (Windows) machine generates an error > which has cropped over the years, namely if we try to run a normalisation step (such as above) then we get the following error (the same error occurs with other normalisations such as rma) :- > >> eSet<- rma(raw) > > Attaching package: hgu133ag4cdf > > The following object(s) are masked from package:hgu133acdf: > > i2xy, xy2i > > Error in ans[[i]][, i.probes] : incorrect number of dimensions > > The problem appears to occur in indexProbes which is part of the affy package (AffyBatch.R to be precise), which first gets the environment associated with the expression set, > > envir<- getCdfInfo(object) > > genenames<- ls(envir) > > ans<- mget(genenames, envir, ifnotfound=NA) > > so that ans should be a list with names of affy id's and each entry is a two column data frame with entries for the pm and mm probe locations. > > The only possibility when the error is occurring is when the following is called > > tmp<- as.vector(ans[[i]][, i.probes]) > > which suggests that ans is not in this format when it gets to this line. The problem is, I can't reproduce the error if I use the source code of AffyBatch.R . > Any ideas on how I can check that this hypothesis is correct ? Any ideas how I can fix this ? It looks as if this error has occurred a number of times over the years, but there never seems to be a complete solution... I don't know what you mean by 'I use the source code of AffyBatch.R'. Anyway, there are at least two things you can do. First, ans <- mget(ls(hgu133ag4cdf), ifnotfound = NA) table(sapply(ans, nrow)) and see if you have any probesets with < 2 rows. Or you can use options(error = recover) and then do whatever will trigger the error. You will then be given a choice of frames to enter. You can enter each one and see what e.g. i.probes, and ans[[i]] look like, which might help figure out what the problem is. Best, Jim > > Many thanks > > _______________________________________________ > Bioconductor mailing list > Bioconductor at r-project.org > https://stat.ethz.ch/mailman/listinfo/bioconductor > Search the archives: http://news.gmane.org/gmane.science.biology.informatics.conductor -- James W. MacDonald, M.S. Biostatistician University of Washington Environmental and Occupational Health Sciences 4225 Roosevelt Way NE, # 100 Seattle WA 98105-6099
ADD REPLYlink written 6.7 years ago by Hugh Shanahan50
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 16.09
Traffic: 228 users visited in the last hour