bio.align

Source code: bio/align.seq

class bio.align.CIGAR
class bio.align.Alignment

Magic methods:

__str__()
bio.align.seq_align(: seq,  : seq,  : Ptr[i8],  : i8,  : i8,  : int,  : int,  : int,  : int,  : Ptr[Alignment])
bio.align.seq_align_dual(: seq,  : seq,  : Ptr[i8],  : i8,  : i8,  : i8,  : i8,  : int,  : int,  : int,  : int,  : Ptr[Alignment])
bio.align.seq_align_splice(: seq,  : seq,  : Ptr[i8],  : i8,  : i8,  : i8,  : i8,  : int,  : int,  : Ptr[Alignment])
bio.align.seq_align_global(: seq,  : seq,  : Ptr[i8],  : i8,  : i8,  : int,  : bool,  : Ptr[Alignment])
bio.align.seq_align_default(: seq,  : seq,  : Ptr[Alignment])
bio.align.seq_palign(: pseq,  : pseq,  : Ptr[i8],  : i8,  : i8,  : int,  : int,  : int,  : int,  : Ptr[Alignment])
bio.align.seq_palign_dual(: pseq,  : pseq,  : Ptr[i8],  : i8,  : i8,  : i8,  : i8,  : int,  : int,  : int,  : int,  : Ptr[Alignment])
bio.align.seq_palign_global(: pseq,  : pseq,  : Ptr[i8],  : i8,  : i8,  : int,  : Ptr[Alignment])
bio.align.seq_palign_default(: pseq,  : pseq,  : Ptr[Alignment])
class bio.align.SubMat

Substitution matrix for amino acid alignment

Magic methods:

__new__(d: Dict[Tuple[str, str], int])
__str__()
extension CIGAR

Properties:

qlen
rlen

Magic methods:

__new__()
__len__()
__eq__(other: CIGAR)
__ne__(other: CIGAR)
__copy__()
__bool__()
__new__(cigar: str)
__getitem__(idx: int)
__iter__()
__str__()
__reversed__()
extension Alignment

Properties:

cigar
score

Magic methods:

__new__()
__new__(cigar: str, score: int)
__bool__()
extension seq

Magic methods:

__matmul__(other: seq)

Methods:

align(other: seq, a: int = 2, b: int = 4, ambig: int = 0, gapo: int = 4, gape: int = 2, gapo2: int = - 1, gape2: int = - 1, bandwidth: int = - 1, zdrop: int = - 1, end_bonus: int = 0, score_only: bool = False, right: bool = False, generic_sc: bool = False, approx_max: bool = False, approx_drop: bool = False, ext_only: bool = False, rev_cigar: bool = False, splice: bool = False, splice_fwd: bool = False, splice_rev: bool = False, splice_flank: bool = False)

Performs Smith-Waterman alignment against another sequence.

  • a: match score

  • b: mismatch score

  • ambig: ambiguous (i.e. N) match score

  • gapo: gap open cost

  • gape: gap extension cost

  • gapo2: 2nd gap open cost for dual gap cost function

  • gape2: 2nd gap extension cost for dual gap cost function

  • bandwidth: bandwidth for DP alignment

  • zdrop: off-diagonal drop-off to stop extension

  • end_bonus: score bonus for reaching end of DP matrix

  • score_only: if true, don’t compute CIGAR

  • right: if true, right-align gaps

  • approx_max: if true, approximate max

  • approx_drop: if true, approximate Z-drop

  • rev_cigar: if true, reverse CIGAR in output

  • ext_only: if true, perform extension alignment

  • splice: if true, perform spliced alignment

extension pseq

Magic methods:

__matmul__(other: pseq)

Performs Smith-Waterman alignment against another sequence. Uses Blosum-62, gap open cost 11 and gap extend cost 1.

Methods:

align(other: pseq, mat: SubMat, gapo: int = 4, gape: int = 2, gapo2: int = - 1, gape2: int = - 1, bandwidth: int = - 1, zdrop: int = - 1, end_bonus: int = 0, score_only: bool = False, right: bool = False, generic_sc: bool = False, approx_max: bool = False, approx_drop: bool = False, ext_only: bool = False, rev_cigar: bool = False)

Performs Smith-Waterman alignment against another sequence.

  • mat: score matrix

  • gapo: gap open cost

  • gape: gap extension cost

  • gapo2: 2nd gap open cost for dual gap cost function

  • gape2: 2nd gap extension cost for dual gap cost function

  • bandwidth: bandwidth for DP alignment

  • zdrop: off-diagonal drop-off to stop extension

  • end_bonus: score bonus for reaching end of DP matrix

  • score_only: if true, don’t compute CIGAR

  • right: if true, right-align gaps

  • approx_max: if true, approximate max

  • approx_drop: if true, approximate Z-drop

  • rev_cigar: if true, reverse CIGAR in output

  • ext_only: if true, perform extension alignment

class bio.align.InterAlignParams

Magic methods:

__new__(a: int, b: int, ambig: int, gapo: int, gape: int, score_only: bool, bandwidth: int, zdrop: int, end_bonus: int)
class bio.align.SeqPair

Magic methods:

__new__(id: int, len1: int, len2: int, flags: int)
class bio.align.InterAlignYield

Magic methods:

__new__(query: seq, target: seq, extz_only: bool, rev_cigar: bool)