Dear all,
I am running a code I wrote 1 year ago that worked perfectly. However, now it seems that the combineTwoExpressionSet function from a4Base is not working properly. It seems it does the job because the line is run with no errors, but when I try tu run the next line (quantileNorm function) it gives an error (see below). And I realize that the problem is that the combineTwoExpressionSet function is not combining properly the expression sets as there are no features in the combined Eset (see below) while there are in the separate Esets.
I will really appreciate if someone could provide some help on what could be happening and how to fix it!
Thank you!
GEO84<-getGEOSuppFiles("GSE84113")
GEO66<-getGEOSuppFiles("GSE66926")
untar("GSE84113/GSE84113_RAW.tar", exdir = getwd())
untar("GSE66926/GSE66926_RAW.tar", exdir = getwd())
# reading cel files
GEOFS84 <- read.celfiles(filenames = c("GSM2227385_25374.CEL.gz","GSM2227386_25375.CEL.gz",
"GSM2227387_25376.CEL.gz","GSM2227388_25377.CEL.gz","GSM2227389_25378.CEL.gz"))
GEOFS66 <- read.celfiles(filenames = c("GSM1634433_23164.CEL.gz", "GSM1634434_23165.CEL.gz"))
# renaming samples
sampleNames(GEOFS84)<-gsub("GSM2227","",sampleNames(GEOFS84))
sampleNames(GEOFS84)<-gsub(".CEL.gz","",sampleNames(GEOFS84))
sampleNames(GEOFS66)<-gsub("GSM16344","",sampleNames(GEOFS66))
sampleNames(GEOFS66)<-gsub(".CEL.gz","",sampleNames(GEOFS66))
# normalization
GEOFS84.rma<-rma(GEOFS84,target="core")
GEOFS66.rma<-rma(GEOFS66,target="core")
# problematic code with corresponding output
# Sample combination and quantile normalization
GEOS_microglia<-combineTwoExpressionSet(GEOFS84.rma,GEOFS66.rma)
GEOS_microglia_quant = quantileNorm(GEOS_microglia)
> GEOS_microglia_quant = quantileNorm(GEOS_microglia)
Error in sort.int(x, na.last = na.last, decreasing = decreasing, ...) :
'x' must be atomic
> GEOS_microglia
ExpressionSet (storageMode: environment)
assayData: 0 features, 2 samples
element names: exprs
protocolData
rowNames: 385_25374 386_25375 ... 400_25389 (10 total)
varLabels: exprs dates
varMetadata: labelDescription channel
phenoData
rowNames: 385_25374 386_25375 ... 37_23168 (14 total)
varLabels: index
varMetadata: labelDescription channel
featureData: none
experimentData: use 'experimentData(object)'
Annotation: pd.mogene.1.0.st.v1
sessionInfo( )
R version 4.0.3 (2020-10-10)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows >= 8 x64 (build 9200)
Matrix products: default
Random number generation:
RNG: Mersenne-Twister
Normal: Inversion
Sample: Rounding
locale:
[1] LC_COLLATE=Spanish_Spain.1252 LC_CTYPE=Spanish_Spain.1252 LC_MONETARY=Spanish_Spain.1252
[4] LC_NUMERIC=C LC_TIME=Spanish_Spain.1252
attached base packages:
[1] stats4 parallel stats graphics grDevices utils datasets methods base
other attached packages:
[1] pd.mogene.1.0.st.v1_3.14.1 DBI_1.1.1
[3] RSQLite_2.2.1 topGO_2.42.0
[5] SparseM_1.78 GO.db_3.12.1
[7] graph_1.68.0 sva_3.38.0
[9] BiocParallel_1.24.1 genefilter_1.72.1
[11] mgcv_1.8-33 nlme_3.1-151
[13] a4Base_1.38.0 a4Core_1.38.0
[15] a4Preproc_1.38.0 ReactomePA_1.34.0
[17] oligo_1.54.1 Biostrings_2.58.0
[19] XVector_0.30.0 oligoClasses_1.52.0
[21] ff_4.0.4 bit_4.0.4
[23] mogene10sttranscriptcluster.db_8.7.0 org.Mm.eg.db_3.12.0
[25] annotate_1.68.0 XML_3.99-0.5
[27] AnnotationDbi_1.52.0 GEOquery_2.58.0
[29] rlang_0.4.10 limma_3.46.0
[31] gplots_3.1.1 scatterplot3d_0.3-41
[33] affyQCReport_1.68.0 lattice_0.20-41
[35] affyPLM_1.66.0 preprocessCore_1.52.0
[37] gcrma_2.62.0 affy_1.68.0
[39] forcats_0.5.1 stringr_1.4.0
[41] purrr_0.3.4 readr_1.4.0
[43] tidyr_1.1.2 tibble_3.0.4
[45] tidyverse_1.3.0 data.table_1.13.4
[47] ggplot2_3.3.3 calibrate_1.7.7
[49] MASS_7.3-53 TimeSeriesExperiment_1.8.0
[51] SummarizedExperiment_1.20.0 MatrixGenerics_1.2.1
[53] matrixStats_0.58.0 clusterProfiler_3.18.0
[55] DOSE_3.16.0 casper_2.24.2
[57] GenomicRanges_1.42.0 GenomeInfoDb_1.26.2
[59] IRanges_2.24.0 S4Vectors_0.28.0
[61] Biobase_2.50.0 BiocGenerics_0.36.0
[63] dplyr_1.0.4
loaded via a namespace (and not attached):
[1] rappdirs_0.3.3 rtracklayer_1.49.5 coda_0.19-4 bit64_4.0.5
[5] knitr_1.31 DelayedArray_0.16.1 RCurl_1.98-1.2 generics_0.1.0
[9] GenomicFeatures_1.42.1 cowplot_1.1.1 shadowtext_0.0.7 VGAM_1.1-5
[13] proxy_0.4-24 chron_2.3-56 enrichplot_1.10.2 xml2_1.3.2
[17] lubridate_1.7.9.2 assertthat_0.2.1 viridis_0.5.1 xfun_0.20
[21] hms_1.0.0 progress_1.2.2 caTools_1.18.1 dbplyr_2.1.0
[25] readxl_1.3.1 igraph_1.2.6 geneplotter_1.68.0 ellipsis_0.3.1
[29] backports_1.2.0 permute_0.9-5 biomaRt_2.46.3 vctrs_0.3.5
[33] cachem_1.0.1 withr_2.4.1 ggforce_0.3.2 checkmate_2.0.0
[37] vegan_2.5-7 GenomicAlignments_1.26.0 prettyunits_1.1.1 cluster_2.1.0
[41] crayon_1.4.1 glmnet_4.1 edgeR_3.32.1 pkgconfig_2.0.3
[45] tweenr_1.0.1 lifecycle_1.0.0 downloader_0.4 affyio_1.60.0
[49] BiocFileCache_1.14.0 modelr_0.1.8 cellranger_1.1.0 polyclip_1.10-0
[53] Matrix_1.2-18 reprex_1.0.0 viridisLite_0.3.0 bitops_1.0-6
[57] KernSmooth_2.23-18 blob_1.2.1 shape_1.4.5 simpleaffy_2.66.0
[61] qvalue_2.22.0 reactome.db_1.74.0 scales_1.1.1 memoise_2.0.0
[65] graphite_1.36.0 magrittr_2.0.1 plyr_1.8.6 zlibbioc_1.36.0
[69] compiler_4.0.3 scatterpie_0.1.5 RColorBrewer_1.1-2 DESeq2_1.30.0
[73] Rsamtools_2.6.0 cli_2.3.1 gaga_2.36.0 tidyselect_1.1.0
[77] stringi_1.5.3 yaml_2.2.1 GOSemSim_2.16.1 askpass_1.1
[81] locfit_1.5-9.4 ggrepel_0.9.1 grid_4.0.3 fastmatch_1.1-0
[85] tools_4.0.3 rstudioapi_0.13 foreach_1.5.1 gridExtra_2.3
[89] farver_2.0.3 ggraph_2.0.4 digest_0.6.27 rvcheck_0.1.8
[93] BiocManager_1.30.10 proto_1.0.0 Rcpp_1.0.5 broom_0.7.5
[97] httr_1.4.2 mpm_1.0-22 colorspace_2.0-0 rvest_0.3.6
[101] fs_1.5.0 splines_4.0.3 graphlayouts_0.7.1 multtest_2.46.0
[105] EBarrays_2.54.0 annaffy_1.62.0 xtable_1.8-4 jsonlite_1.7.2
[109] dynamicTreeCut_1.63-1 tidygraph_1.2.0 R6_2.5.0 gsubfn_0.7
[113] pillar_1.5.0 htmltools_0.5.1.1 affxparser_1.62.0 glue_1.4.2
[117] fastmap_1.1.0 codetools_0.2-18 fgsea_1.16.0 sqldf_0.4-11
[121] curl_4.3 gtools_3.8.2 openssl_1.4.3 survival_3.2-7
[125] munsell_0.5.0 DO.db_2.9 GenomeInfoDbData_1.2.4 iterators_1.0.13
[129] haven_2.3.1 reshape2_1.4.4 gtable_0.3.0
I ran across this bug as well- the issue is related to the code failing to reorder the ExpressionSet rows prior to merging. A workaround for now would be:
That said, this is a particularly dangerous bug because it fails cryptically and silently; the source code should be updated to BioC standards.