constantAmateur / SoupX

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

Unable to knit when running load10X from SoupX #147

Open JasperGattiker opened 6 months ago

JasperGattiker commented 6 months ago

Hello folks, I hammered out a QC process for my data including SoupX (installed from CRAN), and when I run my code in-session everything works perfectly. When I try to knit the R Markdown document to Word, I receive the following error:

Error in full.data[[1]]: ! subscript out of bounds Backtrace:

  1. SoupX::load10X("folder_containing_CellRanger_outs")
  2. Seurat (local) <fn>(data.dir = <chr>) Execution halted

    Running load10X("folder_containing_CellRanger_outs") is quite literally the first thing I do after loading packages, so there is no other code. When I run the chunk by itself, load10X reads the CellRanger outs and makes a soup channel from the raw and filtered feature matrices plus the analysis file. This problem happens both when I start a new session without any cached information, as well as when I do a full and successful run-through of my code in-session before knitting.

Has anyone else had this issue? If so, were you able to fix it, and how? I'd really like to knit to Word for record-keeping.

The full list of packages I load at the top of my document is as follows: SoupX, Seurat, SingleCellExperiment, scDblFinder, glmGamPoi, SingleR, celldex, BiocGenerics, and ggplot2. When I run installed.packages()[names(sessionInfo()$otherPkgs), "Version"] to get versions, this is the output, if it helps. SoupX Seurat SeuratObject "1.6.2" "5.0.1" "5.0.1" sp clustree ggraph "2.1-2" "0.5.1" "2.1.0" glmGamPoi scDblFinder SingleR "1.14.0" "1.16.0" "2.4.0" celldex BiocManager gridExtra "1.12.0" "1.30.22" "2.3" scater scuttle SingleCellExperiment "1.30.1" "1.12.0" "1.24.0" SummarizedExperiment Biobase GenomicRanges "1.32.0" "2.62.0" "1.54.1" GenomeInfoDb IRanges S4Vectors "1.38.1" "2.36.0" "0.40.1" BiocGenerics MatrixGenerics matrixStats "0.46.0" "1.14.0" "1.1.0" ggplot2 "3.4.4"