ComBat crash/problem
1
2
Entering edit mode
@peter-langfelder-4469
Last seen 28 days ago
United States
Dear Evan, I encountered what seems to be a bug in ComBat. Running the following code cb = ComBat(data.problem, batch = batch.problem, mod = model.matrix(~1, data = data.frame(batch.problem))) using data contained in the attached RData file (I assume the RData file will get stripped out of Bioconductor but you should receive it directly), I get the following output: Found 2 batches Found 0 categorical covariate(s) Standardizing Data across genes Fitting L/S model and finding priors Finding parametric adjustments Error in while (change > conv) { : missing value where TRUE/FALSE needed Looking at the source code it seems the problem happens in the it.sol function where in the very first iteration the entire g.new is filled with missing data, causing change to be NA, which generates the problem in the second iteration. Neither the input data nor the batch variable contain any missing entries. This happens with sva_3.10.0 downloaded freshly from bioconductor.org. Thanks for your help, Peter > sessionInfo() R version 3.0.2 Patched (2013-10-08 r64039) Platform: x86_64-unknown-linux-gnu (64-bit) locale: [1] LC_CTYPE=en_US.utf8 LC_NUMERIC=C LC_TIME=en_US.utf8 LC_COLLATE=en_US.utf8 [5] LC_MONETARY=en_US.utf8 LC_MESSAGES=en_US.utf8 LC_PAPER=en_US.utf8 LC_NAME=C [9] LC_ADDRESS=C LC_TELEPHONE=C LC_MEASUREMENT=en_US.utf8 LC_IDENTIFICATION=C attached base packages: [1] tcltk parallel splines grid stats graphics grDevices utils datasets methods base other attached packages: [1] org.Mm.eg.db_2.10.1 DESeq2_1.2.10 RcppArmadillo_0.4.200.0 Rcpp_0.11.1 [5] GenomicRanges_1.14.4 XVector_0.2.0 IRanges_1.20.7 JamsPlenTFun_0.70 [9] GO.db_2.10.1 AnnotationDbi_1.24.0 Biobase_2.22.0 BiocGenerics_0.8.0 [13] WGCNA_1.40 flashClust_1.01-2 dynamicTreeCut_1.62 preprocessCore_1.24.0 [17] sqldf_0.4-7.1 RSQLite.extfuns_0.0.1 RSQLite_0.11.4 DBI_0.2-7 [21] gsubfn_0.6-5 proto_0.3-10 matrixStats_0.8.14 doParallel_1.0.8 [25] iterators_1.0.6 foreach_1.4.1 reshape_0.8.4 plyr_1.8.1 [29] Hmisc_3.14-3 Formula_1.1-1 survival_2.37-7 lattice_0.20-29 [33] impute_1.36.0 cluster_1.15.2 class_7.3-10 MASS_7.3-31 [37] sva_3.10.0 mgcv_1.7-29 nlme_3.1-117 corpcor_1.6.6 loaded via a namespace (and not attached): [1] annotate_1.40.1 chron_2.3-45 codetools_0.2-8 genefilter_1.44.0 latticeExtra_0.6-26 [6] locfit_1.5-9.1 Matrix_1.1-3 R.methodsS3_1.6.1 RColorBrewer_1.0-5 stats4_3.0.2 [11] XML_3.98-1.1 xtable_1.7-3
GO GO • 1.4k views
ADD COMMENT
1
Entering edit mode
yousefj ▴ 10
@yousefj-7221
Last seen 9.9 years ago
Australia

Hi;

I got the same error when I ran ComBat and I do not know how to solve it, I noticed that there are 2 posts, posted while ago, with the same problems, but no one offered a solution, and the problem is still there? I wonder what is wrong with our data that we are trying to analyse?

this is what I did:

.
.
.
> M.Sw <- getM(Mset.Sw)[valid_probes.noNA,]
> pd <- pData(RGset)
> batch <- pd$Slide
> M.Sw.ComBat.noCovs <- ComBat(dat=M.Sw, batch=batch, mod=NULL, par.prior=TRUE, prior.plots=FALSE)

par.prior=TRUE, prior.plots=FALSE)
Found 451 batches
Found 0  categorical covariate(s)
Standardizing Data across genes
Fitting L/S model and finding priors
Finding parametric adjustments

but when it reaches to the last step, I got the following error:

Error in while (change > conv) { : missing value where TRUE/FALSE needed
Calls: ComBat -> it.sol
Execution halted

Thanks

ADD COMMENT

Login before adding your answer.

Traffic: 606 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