Skip to content

mavis/validate/evidence

class GenomeEvidence

inherits Evidence

class TranscriptomeEvidence

inherits Evidence

TranscriptomeEvidence.traverse()

given some genomic position and a distance. Uses the input transcripts to compute all possible genomic end positions at that distance if intronic positions are ignored

def traverse(  # type: ignore
    self,
    start: int,
    distance: int,
    direction: str,
    strand: str = STRAND.NS,
    chrom: Optional[str] = None,
):

Args

  • start (int): the genomic start position
  • distance (int): the amount of exonic/intergenic units to traverse
  • direction (str): the direction wrt to the positive/forward reference strand to traverse
  • strand (str)
  • chrom (Optional[str])

TranscriptomeEvidence.compute_fragment_size()

Template_length to match genome template length (aka. fragment size - 1 read length if all mapped perfectly)

def compute_fragment_size(self, read, mate):

Args

  • read
  • mate

TranscriptomeEvidence.distance()

give the current list of transcripts, computes the putative exonic/intergenic distance given two genomic positions. Intronic positions are ignored

Intergenic calculations are only done if exonic only fails

def distance(self, start: int, end: int, strand: str = STRAND.NS, chrom: Optional[str] = None):

Args

  • start (int)
  • end (int)
  • strand (str)
  • chrom (Optional[str])

TranscriptomeEvidence.generate_window()

given some input breakpoint uses the current evidence setting to determine an appropriate window/range of where one should search for supporting reads

def generate_window(self, breakpoint: Breakpoint):

Args

  • breakpoint (Breakpoint): the breakpoint we are generating the evidence window for

Returns

  • Interval: the range where reads should be read from the bam looking for evidence for this event

TranscriptomeEvidence.exon_boundary_shift_cigar()

given an input read, converts deletions to N when the deletion matches the exon boundaries. Also shifts alignments to correspond to the exon boundaries where possible

def exon_boundary_shift_cigar(self, read):

Args

  • read