ArchR icon indicating copy to clipboard operation
ArchR copied to clipboard

addReproduciblePeakSet error

Open chen-zhan opened this issue 3 years ago • 4 comments

hello, I meet an error when i run addReproduciblePeakSet, and i have not idea to resolve it. Can you get me some suggest?

proj <- addReproduciblePeakSet( ArchRProj = proj, groupBy = "Clusters", pathToMacs2 = "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/chenzhan/software/miniconda3/envs/batcp38/bin/macs2",genomeSize = 122498798 ) Found Gene Seqnames not in GenomeAnnotation chromSizes, Removing : mitochondrion_genome,Unmapped_Scaffold_8_D1580_D1567,rDNA,211000022280328,211000022278279,211000022279681,211000022280494,211000022280703,211000022280481,211000022279188,211000022278436,211000022278449,211000022280347,211000022280341,211000022279392,211000022278760,211000022279165,211000022279264 Found Exon Seqnames not in GenomeAnnotation chromSizes, Removing : mitochondrion_genome,Unmapped_Scaffold_8_D1580_D1567,rDNA,211000022280328,211000022278279,211000022279681,211000022280494,211000022280703,211000022280481,211000022279188,211000022278436,211000022278449,211000022280347,211000022280341,211000022279392,211000022278760,211000022279165,211000022279264 Found TSS Seqnames not in GenomeAnnotation chromSizes, Removing : mitochondrion_genome,Unmapped_Scaffold_8_D1580_D1567,rDNA,211000022280328,211000022278279,211000022279681,211000022280494,211000022280703,211000022280481,211000022279188,211000022278436,211000022278449,211000022280347,211000022280341,211000022279392,211000022278760,211000022279165,211000022279264 ArchR logging to : ArchRLogs/ArchR-addReproduciblePeakSet-191e37032591-Date-2022-10-13_Time-17-16-16.log If there is an issue, please report to github with logFile! 2022-10-13 17:16:49 : Peak Calling Parameters!, 0.542 mins elapsed. Group nCells nCellsUsed nReplicates nMin nMax maxPeaks C1 C1 776 748 3 195 331 150000 C2 C2 41 40 2 26 26 20000 C3 C3 1663 1483 3 483 500 150000 C4 C4 1283 632 3 54 500 150000 C5 C5 510 488 2 110 378 150000 C6 C6 672 672 3 57 338 150000 C7 C7 605 598 3 54 487 150000 C8 C8 210 210 2 49 161 105000 C9 C9 598 540 2 40 500 150000 C10 C10 850 837 3 259 291 150000 C11 C11 422 422 4 61 210 150000 C12 C12 348 348 2 40 308 150000 C13 C13 215 215 2 40 175 107500 C14 C14 727 565 2 65 500 150000 C15 C15 19 19 2 14 15 9500 C16 C16 2261 601 3 50 500 150000 C17 C17 14201 1536 4 215 500 150000 C18 C18 455 455 3 45 356 150000 C19 C19 364 364 2 40 324 150000 C20 C20 278 278 2 40 238 139000 C21 C21 2046 844 3 122 500 150000 C22 C22 1446 566 2 66 500 150000 C23 C23 336 336 2 47 289 150000 C24 C24 11034 1618 4 118 500 150000 C25 C25 283 283 2 65 218 141500 2022-10-13 17:16:49 : Batching Peak Calls!, 0.555 mins elapsed. 2022-10-13 17:16:59 : Batch Execution w/ safelapply!, 0 mins elapsed. 2022-10-13 17:16:59 : Group 1 of 63, Calling Peaks with MACS2!, 0.005 mins elapsed. 2022-10-13 17:16:59 : Group 2 of 63, Calling Peaks with MACS2!, 0.005 mins elapsed. 2022-10-13 17:16:59 : Group 3 of 63, Calling Peaks with MACS2!, 0.006 mins elapsed. 2022-10-13 17:16:59 : Group 4 of 63, Calling Peaks with MACS2!, 0.007 mins elapsed. 2022-10-13 17:19:06 : Group 5 of 63, Calling Peaks with MACS2!, 2.114 mins elapsed. 2022-10-13 17:19:25 : Group 6 of 63, Calling Peaks with MACS2!, 2.433 mins elapsed. 2022-10-13 17:19:40 : Group 7 of 63, Calling Peaks with MACS2!, 2.692 mins elapsed. 2022-10-13 17:19:42 : Group 8 of 63, Calling Peaks with MACS2!, 2.715 mins elapsed. 2022-10-13 17:20:00 : Group 9 of 63, Calling Peaks with MACS2!, 3.022 mins elapsed. 2022-10-13 17:20:40 : Group 10 of 63, Calling Peaks with MACS2!, 3.689 mins elapsed. 2022-10-13 17:21:01 : Group 11 of 63, Calling Peaks with MACS2!, 4.028 mins elapsed. 2022-10-13 17:21:09 : Group 12 of 63, Calling Peaks with MACS2!, 4.171 mins elapsed. 2022-10-13 17:21:18 : Group 13 of 63, Calling Peaks with MACS2!, 4.327 mins elapsed. 2022-10-13 17:21:26 : Group 14 of 63, Calling Peaks with MACS2!, 4.454 mins elapsed. 2022-10-13 17:21:35 : Group 15 of 63, Calling Peaks with MACS2!, 4.598 mins elapsed. 2022-10-13 17:21:45 : Group 16 of 63, Calling Peaks with MACS2!, 4.774 mins elapsed. 2022-10-13 17:21:56 : Group 17 of 63, Calling Peaks with MACS2!, 4.959 mins elapsed. 2022-10-13 17:22:16 : Group 18 of 63, Calling Peaks with MACS2!, 5.278 mins elapsed. 2022-10-13 17:22:19 : Group 19 of 63, Calling Peaks with MACS2!, 5.328 mins elapsed. 2022-10-13 17:22:19 : Group 20 of 63, Calling Peaks with MACS2!, 5.328 mins elapsed. 2022-10-13 17:22:38 : Group 21 of 63, Calling Peaks with MACS2!, 5.658 mins elapsed. 2022-10-13 17:22:39 : Group 22 of 63, Calling Peaks with MACS2!, 5.675 mins elapsed. 2022-10-13 17:22:49 : Group 23 of 63, Calling Peaks with MACS2!, 5.843 mins elapsed. 2022-10-13 17:22:50 : Group 24 of 63, Calling Peaks with MACS2!, 5.846 mins elapsed. 2022-10-13 17:23:12 : Group 25 of 63, Calling Peaks with MACS2!, 6.219 mins elapsed. 2022-10-13 17:23:16 : Group 26 of 63, Calling Peaks with MACS2!, 6.289 mins elapsed. 2022-10-13 17:23:28 : Group 27 of 63, Calling Peaks with MACS2!, 6.48 mins elapsed. 2022-10-13 17:23:56 : Group 28 of 63, Calling Peaks with MACS2!, 6.958 mins elapsed. 2022-10-13 17:24:05 : Group 29 of 63, Calling Peaks with MACS2!, 7.101 mins elapsed. 2022-10-13 17:24:07 : Group 30 of 63, Calling Peaks with MACS2!, 7.13 mins elapsed. 2022-10-13 17:24:19 : Group 31 of 63, Calling Peaks with MACS2!, 7.334 mins elapsed. 2022-10-13 17:24:31 : Group 32 of 63, Calling Peaks with MACS2!, 7.535 mins elapsed. 2022-10-13 17:24:31 : Group 33 of 63, Calling Peaks with MACS2!, 7.544 mins elapsed. 2022-10-13 17:24:35 : Group 34 of 63, Calling Peaks with MACS2!, 7.608 mins elapsed. 2022-10-13 17:24:45 : Group 35 of 63, Calling Peaks with MACS2!, 7.774 mins elapsed. 2022-10-13 17:24:53 : Group 36 of 63, Calling Peaks with MACS2!, 7.903 mins elapsed. 2022-10-13 17:25:03 : Group 37 of 63, Calling Peaks with MACS2!, 8.064 mins elapsed. 2022-10-13 17:25:03 : Group 38 of 63, Calling Peaks with MACS2!, 8.073 mins elapsed. 2022-10-13 17:25:21 : Group 39 of 63, Calling Peaks with MACS2!, 8.364 mins elapsed. 2022-10-13 17:25:29 : Group 40 of 63, Calling Peaks with MACS2!, 8.506 mins elapsed. 2022-10-13 17:25:35 : Group 41 of 63, Calling Peaks with MACS2!, 8.609 mins elapsed. 2022-10-13 17:25:43 : Group 42 of 63, Calling Peaks with MACS2!, 8.735 mins elapsed. 2022-10-13 17:26:07 : Group 43 of 63, Calling Peaks with MACS2!, 9.132 mins elapsed. 2022-10-13 17:26:14 : Group 44 of 63, Calling Peaks with MACS2!, 9.248 mins elapsed. 2022-10-13 17:26:17 : Group 45 of 63, Calling Peaks with MACS2!, 9.301 mins elapsed. 2022-10-13 17:26:34 : Group 46 of 63, Calling Peaks with MACS2!, 9.593 mins elapsed. 2022-10-13 17:26:35 : Group 47 of 63, Calling Peaks with MACS2!, 9.597 mins elapsed. 2022-10-13 17:26:38 : Group 48 of 63, Calling Peaks with MACS2!, 9.65 mins elapsed. 2022-10-13 17:26:53 : Group 49 of 63, Calling Peaks with MACS2!, 9.91 mins elapsed. 2022-10-13 17:26:53 : Group 50 of 63, Calling Peaks with MACS2!, 9.91 mins elapsed. 2022-10-13 17:27:06 : Group 51 of 63, Calling Peaks with MACS2!, 10.125 mins elapsed. 2022-10-13 17:27:09 : Group 52 of 63, Calling Peaks with MACS2!, 10.177 mins elapsed. 2022-10-13 17:27:24 : Group 53 of 63, Calling Peaks with MACS2!, 10.427 mins elapsed. 2022-10-13 17:27:32 : Group 54 of 63, Calling Peaks with MACS2!, 10.547 mins elapsed. 2022-10-13 17:27:48 : Group 55 of 63, Calling Peaks with MACS2!, 10.813 mins elapsed. 2022-10-13 17:27:57 : Group 56 of 63, Calling Peaks with MACS2!, 10.966 mins elapsed. 2022-10-13 17:28:02 : Group 57 of 63, Calling Peaks with MACS2!, 11.056 mins elapsed. 2022-10-13 17:28:11 : Group 58 of 63, Calling Peaks with MACS2!, 11.208 mins elapsed. 2022-10-13 17:28:23 : Group 59 of 63, Calling Peaks with MACS2!, 11.409 mins elapsed. 2022-10-13 17:28:52 : Group 60 of 63, Calling Peaks with MACS2!, 11.88 mins elapsed. 2022-10-13 17:28:59 : Group 61 of 63, Calling Peaks with MACS2!, 11.997 mins elapsed. 2022-10-13 17:29:22 : Group 62 of 63, Calling Peaks with MACS2!, 12.381 mins elapsed. 2022-10-13 17:29:36 : Group 63 of 63, Calling Peaks with MACS2!, 12.611 mins elapsed. 2022-10-13 17:30:28 : Identifying Reproducible Peaks!, 14.192 mins elapsed. [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C12-reproduciblePeaks.gr.rds" [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C1-reproduciblePeaks.gr.rds" [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C11-reproduciblePeaks.gr.rds" [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C10-reproduciblePeaks.gr.rds" [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C13-reproduciblePeaks.gr.rds" [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C14-reproduciblePeaks.gr.rds" [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C16-reproduciblePeaks.gr.rds" [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C17-reproduciblePeaks.gr.rds" [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C19-reproduciblePeaks.gr.rds" [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C18-reproduciblePeaks.gr.rds" [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C2-reproduciblePeaks.gr.rds" [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C20-reproduciblePeaks.gr.rds" [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C22-reproduciblePeaks.gr.rds" [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C21-reproduciblePeaks.gr.rds" [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C23-reproduciblePeaks.gr.rds" [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C24-reproduciblePeaks.gr.rds" [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C25-reproduciblePeaks.gr.rds" [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C4-reproduciblePeaks.gr.rds" [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C3-reproduciblePeaks.gr.rds" [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C5-reproduciblePeaks.gr.rds" [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C6-reproduciblePeaks.gr.rds" [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C7-reproduciblePeaks.gr.rds" [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C9-reproduciblePeaks.gr.rds" [1] "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/project/drosophila/02.scATACseq/04.earlystage/02.project/PeakCalls/C8-reproduciblePeaks.gr.rds" 2022-10-13 17:31:38 : Creating Union Peak Set!, 15.369 mins elapsed. Converged after 0 iterations! Error in h(simpleError(msg, call)) : error in evaluating the argument 'x' in selecting a method for function 'sortSeqlevels': object 'grAll' not found

sessionInfo() R version 4.2.1 (2022-06-23) Platform: x86_64-conda-linux-gnu (64-bit) Running under: CentOS Linux 7 (Core)

Matrix products: default BLAS/LAPACK: /hwfssz5/ST_SUPERCELLS/P21Z10200N0206/chenzhan/software/miniconda3/envs/Rv42/lib/libopenblasp-r0.3.21.so

Random number generation: RNG: L'Ecuyer-CMRG Normal: Inversion Sample: Rejection

locale: [1] LC_CTYPE=en_US.UTF-8 LC_NUMERIC=C [3] LC_TIME=en_US.UTF-8 LC_COLLATE=en_US.UTF-8 [5] LC_MONETARY=en_US.UTF-8 LC_MESSAGES=en_US.UTF-8 [7] LC_PAPER=en_US.UTF-8 LC_NAME=C [9] LC_ADDRESS=C LC_TELEPHONE=C [11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C

attached base packages: [1] parallel stats4 grid stats graphics grDevices utils [8] datasets methods base

other attached packages: [1] BSgenome.Drosophila.BDGP.dm6_1.0.0 BSgenome_1.64.0 [3] rtracklayer_1.56.1 Biostrings_2.64.1 [5] XVector_0.34.0 dplyr_1.0.10 [7] rhdf5_2.38.1 SummarizedExperiment_1.24.0 [9] Biobase_2.56.0 MatrixGenerics_1.8.1 [11] Rcpp_1.0.9 Matrix_1.4-1 [13] GenomicRanges_1.46.1 GenomeInfoDb_1.32.3 [15] IRanges_2.30.1 S4Vectors_0.34.0 [17] BiocGenerics_0.42.0 matrixStats_0.62.0 [19] data.table_1.14.2 stringr_1.4.1 [21] plyr_1.8.7 magrittr_2.0.3 [23] ggplot2_3.3.6 gtable_0.3.1 [25] gtools_3.9.3 gridExtra_2.3 [27] ArchR_1.0.2

loaded via a namespace (and not attached): [1] tidyselect_1.1.2 purrr_0.3.4 lattice_0.20-45 [4] colorspace_2.0-3 vctrs_0.4.1 generics_0.1.3 [7] yaml_2.3.5 utf8_1.2.2 XML_3.99-0.9 [10] rlang_1.0.5 pillar_1.8.1 glue_1.6.2 [13] withr_2.5.0 DBI_1.1.3 BiocParallel_1.28.3 [16] GenomeInfoDbData_1.2.8 lifecycle_1.0.2 zlibbioc_1.42.0 [19] munsell_0.5.0 restfulr_0.0.15 Cairo_1.6-0 [22] fansi_1.0.3 scales_1.2.1 DelayedArray_0.22.0 [25] Rsamtools_2.10.0 rjson_0.2.21 stringi_1.7.8 [28] BiocIO_1.4.0 cli_3.4.0 tools_4.2.1 [31] bitops_1.0-7 rhdf5filters_1.6.0 RCurl_1.98-1.8 [34] tibble_3.1.8 crayon_1.5.1 pkgconfig_2.0.3 [37] assertthat_0.2.1 Rhdf5lib_1.16.0 R6_2.5.1 [40] GenomicAlignments_1.30.0 compiler_4.2.1 ArchR-addReproduciblePeakSet-191e37032591-Date-2022-10-13_Time-17-16-16.log

chen-zhan avatar Oct 13 '22 09:10 chen-zhan

Hi @chen-zhan! Thanks for using ArchR! Please make sure that your post belongs in the Issues section. Only bugs and error reports belong in the Issues section. Usage questions and feature requests should be posted in the Discussions section, not in Issues.
Before we help you, you must respond to the following questions unless your original post already contained this information: 1. If you've encountered an error, have you already searched previous Issues to make sure that this hasn't already been solved? 2. Can you recapitulate your error using the tutorial code and dataset? If so, provide a reproducible example. 3. Did you post your log file? If not, add it now. 4. Remove any screenshots that contain text and instead copy and paste the text using markdown's codeblock syntax (three consecutive backticks). You can do this by editing your original post.

rcorces avatar Oct 13 '22 09:10 rcorces

Presumably something related to your custom genome. I would manually look through each of the -reproduciblePeaks.gr.rds files mentioned in your console output (should be 24 of them) to see if any are empty or otherwise corrupt. Other than that, I've added one additional log message to the dev branch that might give some more insight into what is going on. You could install that branch, re-run addReproduciblePeakSet() and post the updated log file here.

To install:

devtools::install_github("GreenleafLab/ArchR", ref="dev", repos = BiocManager::repositories())
#to unload a package and reload
detach("package:ArchR", unload=TRUE)
library(ArchR)

rcorces avatar Oct 13 '22 15:10 rcorces

Thanks for you kindness. I follow you suggestion, and run again "addReproduciblePeakSet()". here is the error report.

#####error###### 2022-10-14 18:23:24 : Identifying Reproducible Peaks!, 9.907 mins elapsed. Error in .safelapply(seq_along(outSummitList), function(i) { : Error Found Iteration 1 : [1] "Error in [[<-(*tmp*, name, value = integer(0)) : \n 0 elements in value to replace 27301 elements\n" <simpleError in [[<-(*tmp*, name, value = integer(0)): 0 elements in value to replace 27301 elements> Error Found Iteration 2 : [1] "Error in [[<-(*tmp*, name, value = integer(0)) : \n 0 elements in value to replace 22271 elements\n" <simpleError in [[<-(*tmp*, name, value = integer(0)): 0 elements in value to replace 22271 elements> Error Found Iteration 3 : [1] "Error in [[<-(*tmp*, name, value = integer(0)) : \n 0 elements in value to replace 19923 elements\n" <simpleError in [[<-(*tmp*, name, value = integer(0)): 0 elements in value to replace 19923 elements> Error Found Iteration 4 : [1] "Error in [[<-(*tmp*, name, value = integer(0)) : \n 0 elements in value to replace 9515 elements\n" <simpleError in [[<-(*tmp*, name, value = integer(0)): 0 elements in value to replace 9515 elements> Error Fo In addition: Warning message: In mclapply(..., mc.cores = threads, mc.preschedule = preschedule) : 24 function calls resulted in an error

#####traceback########

traceback() 5: stop(errorMsg) 4: .safelapply(seq_along(outSummitList), function(i) { prefix <- sprintf("Rep. Peaks Group (%s of %s) :", i, length(outSummitList)) .logDiffTime(sprintf("%s Creating Reproducible Peaks", prefix), tstart, verbose = FALSE, logFile = logFile) peaks <- suppressMessages(.identifyReproduciblePeaks(summitFiles = outSummitList[[i]], summitNames = summitNamesList[[i]], reproducibility = reproducibility, extendSummits = extendSummits, blacklist = genomeAnnotation$blacklist, prefix = prefix, logFile = logFile)) .logDiffTime(sprintf("%s Annotating and Filtering Peaks", prefix), tstart, verbose = FALSE, logFile = logFile) peaks <- sort(sortSeqlevels(peaks)) peaks <- subsetByOverlaps(peaks, genomeAnnotation$chromSizes, type = "within") peaks <- .fastAnnoPeaks(peaks, BSgenome = BSgenome, geneAnnotation = geneAnnotation, promoterRegion = promoterRegion, logFile = logFile) peaks <- peaks[which(mcols(peaks)$N < 0.001)] peaks <- peaks[order(peaks$groupScoreQuantile, decreasing = TRUE)] peaks <- head(peaks, groupSummary[names(outSummitList)[i], "maxPeaks"]) mcols(peaks)$N <- NULL print(file.path(outDir, paste0(make.names(names(outSummitList)[i]), "-reproduciblePeaks.gr.rds"))) saveRDS(peaks, file.path(outDir, paste0(make.names(names(outSummitList)[i]), "-reproduciblePeaks.gr.rds"))) return(peaks) }, threads = threads) 3: GRangesList(.) 2: .safelapply(seq_along(outSummitList), function(i) { prefix <- sprintf("Rep. Peaks Group (%s of %s) :", i, length(outSummitList)) .logDiffTime(sprintf("%s Creating Reproducible Peaks", prefix), tstart, verbose = FALSE, logFile = logFile) peaks <- suppressMessages(.identifyReproduciblePeaks(summitFiles = outSummitList[[i]], summitNames = summitNamesList[[i]], reproducibility = reproducibility, extendSummits = extendSummits, blacklist = genomeAnnotation$blacklist, prefix = prefix, logFile = logFile)) .logDiffTime(sprintf("%s Annotating and Filtering Peaks", prefix), tstart, verbose = FALSE, logFile = logFile) peaks <- sort(sortSeqlevels(peaks)) peaks <- subsetByOverlaps(peaks, genomeAnnotation$chromSizes, type = "within") peaks <- .fastAnnoPeaks(peaks, BSgenome = BSgenome, geneAnnotation = geneAnnotation, promoterRegion = promoterRegion, logFile = logFile) peaks <- peaks[which(mcols(peaks)$N < 0.001)] peaks <- peaks[order(peaks$groupScoreQuantile, decreasing = TRUE)] peaks <- head(peaks, groupSummary[names(outSummitList)[i], "maxPeaks"]) mcols(peaks)$N <- NULL print(file.path(outDir, paste0(make.names(names(outSummitList)[i]), "-reproduciblePeaks.gr.rds"))) saveRDS(peaks, file.path(outDir, paste0(make.names(names(outSummitList)[i]), "-reproduciblePeaks.gr.rds"))) return(peaks) }, threads = threads) %>% GRangesList() 1: addReproduciblePeakSet(ArchRProj = proj, groupBy = "Clusters", genomeSize = 122498798, pathToMacs2 = "/hwfssz5/ST_SUPERCELLS/P21Z10200N0206/chenzhan/software/miniconda3/envs/batcp38/bin/macs2")

ArchR-addReproduciblePeakSet-4dbe5a4d2da7-Date-2022-10-14_Time-18-13-29.log

chen-zhan avatar Oct 14 '22 11:10 chen-zhan

This is a slightly different error than previously. I cant be sure but this looks like a problem with your genome annotation to me. We dont work with custom genomes and I'm afraid I dont have many suggestions for how to fix it. I would start by looking at the actual summit calls from the individual runs of macs2. These should be stored in a subfolder of the PeakCalls directory called "ReplicateCalls". I would inspect each one manually by loading it into R with readRDS(). Then I would make a list() of those summit files and try to step through some of the code here to see what is causing your error. https://github.com/GreenleafLab/ArchR/blob/fa2a3a865bfd0d9358329e4da60ef849c315fb68/R/ReproduciblePeakSet.R#L234-L262

rcorces avatar Oct 14 '22 13:10 rcorces

closing due to inactivity. if you need further assistance on this issue, please post again here.

rcorces avatar Nov 07 '22 13:11 rcorces