report_comment: >
    This report has been generated by the <a href="https://github.com/nf-core/atacseq" target="_blank">nf-core/atacseq</a>
    analysis pipeline. For information about how to interpret these results, please see the
    <a href="https://github.com/nf-core/atacseq/blob/master/docs/output.md" target="_blank">documentation</a>.

data_format: 'yaml'

run_modules:
    - custom_content
    - fastqc
    - cutadapt
    - samtools
    - picard
    - preseq
    - featureCounts
    - deeptools

exclude_modules:
    - 'general_stats'

module_order:
    - fastqc:
        name: 'LIB: FastQC (raw)'
        info: 'This section of the report shows FastQC results before adapter trimming for individual libraries.'
        path_filters:
            - './fastqc/*.zip'
    - cutadapt:
        name: 'LIB: Cutadapt (trimmed)'
        info: 'This section of the report shows the length of trimmed reads by Cutadapt for individual libraries.'
    - fastqc:
        name: 'LIB: FastQC (trimmed)'
        info: 'This section of the report shows FastQC results after adapter trimming for individual libraries.'
        path_filters:
            - './trimgalore/fastqc/*.zip'
    - samtools:
        name: 'LIB: SAMTools'
        info: 'This section of the report shows SAMTools results for individual libraries.'
        path_filters:
            - './alignment/library/*'
    - samtools:
        name: 'MERGED LIB: SAMTools (unfiltered)'
        info: 'This section of the report shows SAMTools results after merging libraries and before filtering.'
        path_filters:
            - './alignment/mergedLibrary/*.mLb.mkD.sorted.bam*'
    - preseq:
        name: 'MERGED LIB: Preseq (unfiltered)'
        info: 'This section of the report shows Preseq results after merging libraries and before filtering.'
    - samtools:
        name: 'MERGED LIB: SAMTools (filtered)'
        info: 'This section of the report shows SAMTools results after merging libraries and after filtering.'
        path_filters:
            - './alignment/mergedLibrary/*.mLb.clN.sorted.bam*'
    - picard:
        name: 'MERGED LIB: Picard'
        info: 'This section of the report shows picard results after merging libraries and after filtering.'
        path_filters:
            - './alignment/mergedLibrary/picard_metrics/*'
    - deeptools:
        name: 'MERGED LIB: deepTools'
        anchor: 'mlib_deeptools'
        info: 'This section of the report shows QC plots generated by deepTools.'
    - featureCounts:
        name: 'MERGED LIB: featureCounts'
        anchor: 'mlib_featurecounts'
        info: 'This section of the report shows featureCounts results for the number of reads assigned to merged library consensus peaks.'
        path_filters:
            - './macs/mergedLibrary/consensus/*.summary'
    - samtools:
        name: 'MERGED REP: SAMTools'
        info: 'This section of the report shows SAMTools results after merging replicates and filtering.'
        path_filters:
            - './alignment/mergedReplicate/*'
    - picard:
        name: 'MERGED REP: Picard'
        anchor: 'mrep_picard'
        info: 'This section of the report shows picard results after merging libraries and before filtering.'
        path_filters:
            - './alignment/mergedReplicate/*'
    - featureCounts:
        name: 'MERGED REP: featureCounts'
        anchor: 'mrep_featurecounts'
        info: 'This section of the report shows featureCounts results for the number of reads assigned to merged replicate consensus peaks.'
        path_filters:
            - './macs/mergedReplicate/consensus/*.summary'

report_section_order:
    mlib_peak_count:
        before: mlib_deeptools
    mlib_frip_score:
        before: mlib_peak_count
    mlib_peak_annotation:
        before: mlib_frip_score
    mlib_featurecounts:
        before: mlib_peak_annotation
    mlib_deseq2_pca:
        before: mlib_featurecounts
    mlib_deseq2_clustering:
        before: mlib_deseq2_pca
    mrep_peak_count:
        before: mrep_picard
    mrep_frip_score:
        before: mrep_peak_count
    mrep_peak_annotation:
        before: mrep_frip_score
    mrep_featurecounts:
        before: mrep_peak_annotation
    mrep_deseq2_pca:
        before: mrep_featurecounts
    mrep_deseq2_clustering:
        before: mrep_deseq2_pca
    software_versions:
        order: -1001
    nf-core-atacseq-summary:
        order: -1002

custom_plot_config:
    picard_insert_size:
        cpswitch_c_active: False
        smooth_points: 1000
    featurecounts:
        cpswitch_c_active: False
    featurecounts-1:
        cpswitch_c_active: False

extra_fn_clean_exts:
    - 'fastq.gz'
    - '_trimmed'
    - '_val'
    - 'sorted.bam'
    - '.Lb'
    - 'mkD'
    - 'clN'
    - 'mLb'
    - 'mRp'
    - '_peaks'

# # Customise the module search patterns to speed up execution time
# #  - Skip module sub-tools that we are not interested in
# #  - Replace file-content searching with filename pattern searching
# #  - Don't add anything that is the same as the MultiQC default
# # See https://multiqc.info/docs/#optimise-file-search-patterns for details
sp:
    cutadapt:
        fn: '*trimming_report.txt'
    preseq:
        fn: '*.ccurve.txt'
    deeptools/plotFingerprintOutRawCounts:
        fn: '*plotFingerprint*'
    deeptools/plotProfile:
        fn: '*plotProfile*'
