constantAmateur / SoupX

R package to quantify and remove cell free mRNAs from droplet based scRNA-seq data
248 stars 34 forks source link

autoEstCont() error in SoupX with CellRanger Data #116

Closed CTChameleon closed 2 years ago

CTChameleon commented 2 years ago

Hello,

I have created a SoupChannel object with sc=load10x('path/to/outs'), which runs just fine, but when I run sc = autoEstCont(sc), the following error is displayed:

Error in autoEstCont(sc) : Clustering information must be supplied, run setClusters first.

The data in my outs folder is from CellRanger and it does contain the Analysis folder with clustering information.

As an alternative to the automated method, I have done the processing in Seurat- up through clustering - but when I run sc = setClusters(sc,Hypo.subset@active.ident) I get another error:

Error in setClusters(sc, Hypo.subset@active.ident) : Invalid cluster specification. See help.

Below is some code that might be informative for this issue:

Hypo.subset@active.ident AATCACGAGCATTGAA-1 AATCACGAGCGACATG-1 AATCACGAGGCGTTAG-1 AATCACGAGGTTGGAC-1 AATCACGAGTAATTGG-1 Neuron Oligodendrocytes Oligodendrocytes Ast Neuron AATCACGAGTGGCCTC-1 AATCACGAGTGTGTTC-1 AATCACGCAATCAAGA-1 AATCACGCACAGAGAC-1 AATCACGCACATGAAA-1 Neuron Neuron Neuron Ast Neuron AATCACGCACTACACA-1 AATCACGCAGGTTCAT-1 AATCACGCATCAGTGT-1 AATCACGCATGAAGCG-1 AATCACGCATGAAGGC-1 Neuron Oligodendrocytes Neuron Oligodendrocytes Oligodendrocytes AATCACGCATGTTCGA-1 AATCACGGTAATGCTC-1 AATCACGGTACTGAGG-1 AATCACGGTATGAGCG-1 AATCACGGTCAAGCGA-1 Oligodendrocytes Neuron Oligodendrocytes Ast Neuron AATCACGGTCACGCTG-1 AATCACGGTCACTCGG-1 AATCACGGTCCACACG-1 AATCACGGTCGAATGG-1 AATCACGGTCTAGGTT-1 Oligodendrocytes Oligodendrocytes Oligodendrocytes Microglia/Macrophage Neuron ....

length(Hypo.subset@active.ident) [1] 1448

length(sc$metaData) [1] 1

When I run head(sc$metaData) nUMIs AATCACGAGCAATTAG-1 823 AATCACGAGCATTGAA-1 3997 AATCACGAGCGACATG-1 1276 AATCACGAGGCGTTAG-1 1114 AATCACGAGGCTCAAG-1 26658 AATCACGAGGTTGCCC-1 12465

Below is my SessionInfo()

R version 4.2.0 (2022-04-22 ucrt) Platform: x86_64-w64-mingw32/x64 (64-bit) Running under: Windows 10 x64 (build 22000)

Matrix products: default

locale: [1] LC_COLLATE=English_United States.utf8 LC_CTYPE=English_United States.utf8 LC_MONETARY=English_United States.utf8 [4] LC_NUMERIC=C LC_TIME=English_United States.utf8

attached base packages: [1] stats graphics grDevices utils datasets methods base

other attached packages: [1] SoupX_1.6.1 BiocManager_1.30.18 sctransform_0.3.3 RCurl_1.98-1.7 cowplot_1.1.1
[6] scales_1.2.0 Matrix_1.4-1 forcats_0.5.1 stringr_1.4.0 purrr_0.3.4
[11] readr_2.1.2 tidyr_1.2.0 tibble_3.1.7 tidyverse_1.3.1 ggplot2_3.3.6
[16] patchwork_1.1.1 sp_1.5-0 SeuratObject_4.1.0 Seurat_4.1.1 dplyr_1.0.9

loaded via a namespace (and not attached): [1] readxl_1.4.0 backports_1.4.1 plyr_1.8.7 igraph_1.3.2 lazyeval_0.2.2
[6] splines_4.2.0 listenv_0.8.0 scattermore_0.8 digest_0.6.29 htmltools_0.5.2
[11] fansi_1.0.3 magrittr_2.0.3 tensor_1.5 cluster_2.1.3 ROCR_1.0-11
[16] tzdb_0.3.0 globals_0.15.0 modelr_0.1.8 matrixStats_0.62.0 spatstat.sparse_2.1-1 [21] colorspace_2.0-3 rvest_1.0.2 ggrepel_0.9.1 haven_2.5.0 xfun_0.31
[26] crayon_1.5.1 jsonlite_1.8.0 progressr_0.10.1 spatstat.data_2.2-0 survival_3.3-1
[31] zoo_1.8-10 glue_1.6.2 polyclip_1.10-0 gtable_0.3.0 leiden_0.4.2
[36] future.apply_1.9.0 abind_1.4-5 DBI_1.1.3 spatstat.random_2.2-0 miniUI_0.1.1.1
[41] Rcpp_1.0.8.3 viridisLite_0.4.0 xtable_1.8-4 reticulate_1.25 spatstat.core_2.4-4
[46] htmlwidgets_1.5.4 httr_1.4.3 RColorBrewer_1.1-3 ellipsis_0.3.2 ica_1.0-2
[51] farver_2.1.0 pkgconfig_2.0.3 uwot_0.1.11 dbplyr_2.2.0 deldir_1.0-6
[56] utf8_1.2.2 tidyselect_1.1.2 labeling_0.4.2 rlang_1.0.2 reshape2_1.4.4
[61] later_1.3.0 munsell_0.5.0 cellranger_1.1.0 tools_4.2.0 cli_3.3.0
[66] generics_0.1.2 broom_0.8.0 ggridges_0.5.3 evaluate_0.15 fastmap_1.1.0
[71] yaml_2.3.5 goftest_1.2-3 knitr_1.39 fs_1.5.2 fitdistrplus_1.1-8
[76] RANN_2.6.1 pbapply_1.5-0 future_1.26.1 nlme_3.1-157 mime_0.12
[81] xml2_1.3.3 compiler_4.2.0 rstudioapi_0.13 plotly_4.10.0 png_0.1-7
[86] spatstat.utils_2.3-1 reprex_2.0.1 stringi_1.7.6 RSpectra_0.16-1 rgeos_0.5-9
[91] lattice_0.20-45 vctrs_0.4.1 pillar_1.7.0 lifecycle_1.0.1 spatstat.geom_2.4-0
[96] lmtest_0.9-40 RcppAnnoy_0.0.19 data.table_1.14.2 bitops_1.0-7 irlba_2.3.5
[101] httpuv_1.6.5 R6_2.5.1 promises_1.2.0.1 KernSmooth_2.23-20 gridExtra_2.3
[106] parallelly_1.32.0 codetools_0.2-18 MASS_7.3-56 assertthat_0.2.1 withr_2.5.0
[111] mgcv_1.8-40 parallel_4.2.0 hms_1.1.1 grid_4.2.0 rpart_4.1.16
[116] rmarkdown_2.14 Rtsne_0.16 shiny_1.7.1 lubridate_1.8.0

CTChameleon commented 2 years ago

@constantAmateur Will you please help? Thank you!

CTChameleon commented 2 years ago

I just looked closely at the documents within my outs/analysis folder and found that every file began with the prefix geneexpression. After removing this prefix, the program ran as normal.