PYFASTAQ REPLACE_BASES¶
Replaces all occurrences of one letter with another.
Example¶
This wrapper can be used in the following way:
rule replace_bases:
input:
"{sample}.rna.fa"
output:
"{sample}.dna.fa",
params:
old_base = "U",
new_base = "T",
log:
"logs/fastaq/replace_bases/test/{sample}.log"
wrapper:
"v1.3.2/bio/pyfastaq/replace_bases"
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.
Software dependencies¶
pyfastaq==3.17.0
Authors¶
- Michael Hall
Code¶
__author__ = "Michael Hall"
__copyright__ = "Copyright 2019, Michael Hall"
__email__ = "michael@mbh.sh"
__license__ = "MIT"
from snakemake.shell import shell
log = snakemake.log_fmt_shell(stdout=False, stderr=True)
shell(
"fastaq replace_bases"
" {snakemake.input[0]}"
" {snakemake.output[0]}"
" {snakemake.params.old_base}"
" {snakemake.params.new_base}"
" {log}"
)