Limma error - undefined columns selected
1
0
Entering edit mode
@gordon-smyth
Last seen 9 minutes ago
WEHI, Melbourne, Australia
Dear Ankit, The error is caused by a bug in the function wtVariables() in limma. Try sourcing this replacement function into your session and see if it fixes the problem. Best wishes Gordon wtVariables <- function(x,fun) # Finds variable names in user-defined functions # Gordon Smyth # 3 Nov 2004. Last modified 2 Jan 2006. { x <- as.character(x) a <- deparse(fun) n <- length(x) ind <- logical(n) for (i in 1:n) { ind[i] <- as.logical(length(grep(protectMetachar(x[i]),a))) } x[ind] } At 10:00 PM 28/12/2005, bioconductor-request at stat.math.ethz.ch wrote: >Date: Tue, 27 Dec 2005 03:44:20 -0800 (PST) >From: Ankit Pal <pal_ankit2000 at="" yahoo.com=""> >Subject: [BioC] Limma error - undefined columns selected >To: bioconductor at stat.math.ethz.ch > > Hi All, > I'm using the latest version of limma to analyse a set of 3 gpr files. > The QC filter I have created is as follows > >myfun <- function(x,threshold=55){ > + okred <- abs(x[,"% > B635+2SD"]) > threshold > + okgreen <- abs(x[,"% > B532+2SD"]) > threshold > + okflag <- abs(x[,"Flags"]) > 0 > + okRGN <- abs(x[,"Rgn R2 (635/532)"] ) > 0.6 > + as.numeric(okgreen || okred || okflag || okRGN) > +} > > Onreading in the gpr files using > > >RG <- read.maimages(targets$FileName, source="genepix",wt.fun=myfun) > I get the following error > > Error in "[.data.frame"(x, , "% > B635+2SD") : > undefined columns selected > > I checked the columns and they are present in my gpr file. > > Why am I getting this error and how do I go about correcting it > > -Ankit
GO limma GO limma • 1.2k views
ADD COMMENT
0
Entering edit mode
@gerhard-thallinger-1552
Last seen 6 weeks ago
Austria
Dear all, I am analyzing an experiment consisting of 4 one-channel hybridizations with two conditions and a technical replicate for each of them. I am using limma 2.4.4 (2005/11/29) under R 2.2.0 on Windows. The design matrix is as follows: 0h 2h 1 1 0 2 1 0 3 0 1 4 0 1 Since there are technical replicates the correlation between them should be taken into account: techrep <- c(1,1,2,2) corfit <- duplicateCorrelation(signal(anaexp), ndups = 1, block = techrep) fit <- lmFit(signal(anaexp), design, block = techrep, cor = corfit$consenus) The fit aborts with the following error: Error in backsolve(cholV, y, transpose = TRUE) : NA/NaN/Inf in foreign function call (arg 1) In addition: Warning messages: 1: NaNs produced in: sqrt(dfitted.values) 2: NaNs produced in: sqrt(dfitted.values) The error is probably a consequence of the warnings from the "corfit <-" step. What value would one expect for the consensus correlation ? Any ideas how to work around these error ? The fit without block and cor works flawlessly. Trying to define contrasts I encountered the following error messages: cont <- makeContrasts("2h-0h", levels = design) Error in parse(file, n, text, prompt) : syntax error in "2h" Obviously a digit as the first character is not allowed. Prepending a "T" before the condition solved this problem. Using a variable for the contrast lead to a different message: ctr <- "T2h-T0h" cont <- makeContrasts(ctr, levels = design) Error in eval(expr, envir, enclos) : object "ctr" not found This could be circumvented by using the following construct: cmd <- paste("cont <- makeContrasts(", ctr, ", levels = design)", sep = '"') eval(parse(text = cmd)) TIA for your help Gerhard
ADD COMMENT
0
Entering edit mode
The problem is that in your design you have no biological replicates. If you use blocks, then you must have blockwise replication. You have no d.f. for testing. --Naomi At 01:29 PM 1/2/2006, Gerhard Thallinger wrote: >Dear all, > > I am analyzing an experiment consisting of 4 one-channel >hybridizations with two conditions and a technical replicate >for each of them. I am using limma 2.4.4 (2005/11/29) under >R 2.2.0 on Windows. The design matrix is as follows: > > 0h 2h >1 1 0 >2 1 0 >3 0 1 >4 0 1 > >Since there are technical replicates the correlation between them >should be taken into account: > > techrep <- c(1,1,2,2) > corfit <- duplicateCorrelation(signal(anaexp), ndups = 1, block = techrep) > fit <- lmFit(signal(anaexp), design, block = techrep, cor = > corfit$consenus) > >The fit aborts with the following error: > Error in backsolve(cholV, y, transpose = TRUE) : > NA/NaN/Inf in foreign function call (arg 1) > In addition: Warning messages: > 1: NaNs produced in: sqrt(dfitted.values) > 2: NaNs produced in: sqrt(dfitted.values) > >The error is probably a consequence of the warnings from the "corfit <-" step. >What value would one expect for the consensus correlation ? >Any ideas how to work around these error ? > >The fit without block and cor works flawlessly. Trying to define contrasts >I encountered the following error messages: > > cont <- makeContrasts("2h-0h", levels = design) > Error in parse(file, n, text, prompt) : syntax error in "2h" > >Obviously a digit as the first character is not allowed. Prepending a "T" >before the condition solved this problem. Using a variable for the contrast >lead to a different message: > > ctr <- "T2h-T0h" > cont <- makeContrasts(ctr, levels = design) > Error in eval(expr, envir, enclos) : object "ctr" not found > >This could be circumvented by using the following construct: > > cmd <- paste("cont <- makeContrasts(", ctr, ", levels = design)", > sep = '"') > eval(parse(text = cmd)) > >TIA for your help > >Gerhard > >_______________________________________________ >Bioconductor mailing list >Bioconductor at stat.math.ethz.ch >https://stat.ethz.ch/mailman/listinfo/bioconductor Naomi S. Altman 814-865-3791 (voice) Associate Professor Dept. of Statistics 814-863-7114 (fax) Penn State University 814-865-1348 (Statistics) University Park, PA 16802-2111
ADD REPLY

Login before adding your answer.

Traffic: 524 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6