Description Usage Arguments Details Value Examples
View source: R/chimeric_reads.R
It checks for two different things: 1. If the SA tag exists. This tag only exists for SAM/BAM files produced by bwa-mem. 2. If the rname of two reads with the same qname is different. This generally indicates that the reads have been aligned to two different portions of the genome.
chimeric_reads(bamfile, checks = 3)
the path to the BAM file
1 indicates checking only for SA tag, 2 only for rname, and 3 for both. Default is both.
The indices returned will be those with any of the features above. The user also has the option to only check for 1 of the 2.
NOTE that the absence of either of the 2 features above does NOT mean that your alignment does not have chimeras, especially if you are using older versions of reference aligners. This is merely a heuristic diagnostic using convenient metrics to assess overall quality of your alignment.
Planned improvements: Also check for if the 0x800 flag exists, indicating a supplementary and thus chimeric alignment. This flag only exists in version 1.5 of the SAM and BAM formats and beyond.
Indices of chimeric records. If there aren't
1 2 3
no_tags_no_rname <- system.file("extdata","ex1.bam",package="Rsamtools") chimeric_reads(no_tags_no_rname,checks=1) chimeric_reads(no_tags_no_rname)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.