FASTQC
run fastqc on fastq, bam or sam file.
URL: https://www.bioinformatics.babraham.ac.uk/projects/fastqc/
Example
This wrapper can be used in the following way:
test/Snakefile not found.
Note that input, output and log file paths can be chosen freely.
When running with
snakemake --use-conda
the software dependencies will be automatically deployed into an isolated environment before execution.
Params
outdir
: outputdir (optional)extras
: extra arguments to fastqc. (optional)
Code
# fastqc wrapper
__author__ = "yangqun"
import sys
import os
from snakemake.shell import shell
# arguments
assert "data" in snakemake.input.keys()
input_data = snakemake.input['data']
fastqc = snakemake.input.get('fastqc', 'fastqc')
java = snakemake.input.get('java', '')
outdir = snakemake.params.get('outdir', '')
extras = snakemake.params.get('extras', '')
# program
java_path = f"-j {java}" if java else ""
out_cmd = f"-o {outdir}" if outdir else ""
shell(
"{fastqc} {java_path} {out_cmd} {extras} {input_data}"
)