junction.support: junction.support

junction.supportR Documentation

junction.support

Description

Takes as input a GRanges of bam alignments (e.g. outputted from bamUtils::read.bam) and a GRanges of rearranged reference aligned contigs (e.g. output of RSeqLib::BWA) and a set of Junction objects, and outputs reads supporting these junctions by building a contig around each junction (from the reference) and then running contig.support (see that functions docuemntation for criteria)

Usage

junction.support(
  reads,
  junctions = NULL,
  bwa = NULL,
  ref = NULL,
  pad = 500,
  bx = FALSE,
  pad.ref = pad * 20,
  both = TRUE,
  realign = TRUE,
  walks = NULL,
  verbose = TRUE,
  ...
)

Arguments

reads

GRanges in SAM / BAM format e.g. output of read.bam or BWA, with fields $qname, $cigar, $flag $seq all populated in standard fashion, and optionally $AS

junctions

Junction object

bwa

RSeqLib BWA object and path to fasta file corresponding to the reference

ref

optional DNAStringSet corresponding to reference genome sequence

pad

padding around the junction breakpoint around which to analyze contig and reference sequences, this should be several standard deviations above the average insert size (2000)

bx

logical flag whether data is linked reads, must then have BX flag, and the pad will be set to minimum 1e5

realign

flag whether to realign or just use existing alignments

verbose

logical flag (TRUE)

...

additional parameters to contig support

Value

reads re-aligned to the reference through the contigs with additional metadata describing features of the alignment

Author(s)

Marcin Imielinski


mskilab/skitools documentation built on Aug. 31, 2023, 1:13 p.m.