This software is created to use Oxford Nanopore RNA004 flowcells for tRNA sequecin and contains two programs.
Use bwamapbam
to align the Dorado output BAM using BWA and keep the modification tags generated by Dorado
. Unfortunately BWA is currently affected by a bug that writes an incorrect SAM header to it's output, which confuses our SAM parser. See this github issue. use the patch provided in this repository to fix BWA.
After alignment use trnamapqrecal
to adjust the mapping qualities to account for the low distance reference sequences. This program will assign > q0 mapping qualities to reads that have high enough alignment scores for the primary alignment compared to the alternative mappings given the actual distance of the reference seqeunces.
Usage: bwamapbam [OPTIONS] --reference <REFERENCE> --bam <BAM> --out <OUT>
Options:
--reference <REFERENCE>
--bam <BAM>
--out <OUT>
--bwa <BWA> [default: bwa]
--args <ARGS> [default: "-t8 -Y -h30,200 -W13 -k6 -xont2d -T20 -u"]
-h, --help Print help
Use --bwa
to provide an alternative BWA executable path. BWA arguments are
optimal for human tRNA reference mapping. Use the --args
to customize the BWA
command line arguments, the -u
is required to generate the XB
tag this
software relies on. The reference should be the location of the BWA indexed .fa
file.
Usage: trnamapqrecal [OPTIONS] --reference <REFERENCE> --bam <BAM> --out <OUT>
Options:
--reference <REFERENCE>
--bam <BAM>
--out <OUT>
--counts <COUNTS>
--qs <QS> [default: 0]
-h, --help Print help
If --counts
is provided the tRNA reference counts are output grouped by
mapping quality. You can use --counts
in combination with --qs
to filter on
ONT read quality (qs
tag should be in BAM records). --out
should be a BAM
file, this output is not filtered for read quality! You can use a samtools
expression to filter the bam file.
When running modkit
on the
recalibrated bam you should probably filter for mapq and qs using a samtools
expression:
samtools view -q1 -e '[qs] > 4' in.bam -o out.bam
The paper for which this software was implemented is under submission
Adva Kochavi, Arno Velds, Roderick Beijersbergen, Reuven Agami. (2025). Exploiting nanopore sequencing advances for tRNA sequencing of human cancer models