Search code examples
pythonworkflowintegrationsnakemake

multiqc on RSeQC clipping_profiles


The following snakemake code fails to produce multiqc output although it does for orther RSeQC tools including geneBody_coverage, junction_saturation, and read_distribution (removed here for clarity)

rule rseqc_cliping_profile:
    """
    Run RSeQC on merged bam files
    """
    input:
        bam = "results/mappings/{smp}_mappings.bam"
    output:
        pdf3 = "results/rseqc2/{smp}.clipping_profile.R1.pdf",
        pdf4 = "results/rseqc2/{smp}.clipping_profile.R2.pdf",
        xls = "results/rseqc2/{smp}.clipping_profile.xls"
    shell: """
        mkdir -p intermediate/rseqc2
        # Run clipping_profile.py
        clipping_profile.py -i {input.bam} \
        -q 30 \
        -s PE \
        -o intermediate/rseqc2/{wildcards.smp} \
        && cp -f intermediate/rseqc2/{wildcards.smp}.clipping_profile.R1.pdf {output.pdf3} \
        && cp -f intermediate/rseqc2/{wildcards.smp}.clipping_profile.R2.pdf {output.pdf4} \
        && cp -f intermediate/rseqc2/{wildcards.smp}.clipping_profile.xls {output.xls}
        """

Any idea about what I am doing wrong?

the results in intermediate/rseqc2 are of the kind (S12 only here):

S12.clipping_profile.r
S12.clipping_profile.R1.pdf
S12.clipping_profile.R2.pdf
S12.clipping_profile.xls

multiqc -f -i "RSeQC" -o intermediate/multiqc_rseqc2 -n multiqc_rseqc2 intermediate/rseqc2

[INFO   ]         multiqc : This is MultiQC v1.6
[INFO   ]         multiqc : Template    : default
[INFO   ]         multiqc : Report title: RSeQC
[INFO   ]         multiqc : Searching 'intermediate/rseqc2'
[WARNING]         multiqc : No analysis results found. Cleaning up..
[INFO   ]         multiqc : MultiQC complete

It is not a snakemake issue!

Although clipping_profile is in my multiqc config yaml, it seems not fit to find the clipping_profile data for plotting.

The xls file are in fact tsv files in disguise; renaming them .txt or .tsv does not improve the odds.


Solution

  • The MultiQC documentation on RSeQC support shows that MultiQC does not support that particular tool (clipping_profile), but it does support the others you mentioned.