dasi.models.PCRProductAlignmentGroup

class dasi.models.PCRProductAlignmentGroup(fwd, template, rev, query_region, group_type, meta=None)[source]

Bases: dasi.models.alignment.AlignmentGroupBase

Represents a PCR product alignment from a template alignment and forward and reverse alignments. Represents several situations:

Situations the PCRProductAlignmentGroup represents:

Rev primer with overhang
            <--------
------------------
---->

Primers with overhangs
               <--------
   ------------------
-------->

Primers 'within' the template
        <-----
   ------------------
-------->

And so on...

Attributes

query_key

Return the query key associated with the query region.

subject_keys

Return the list of subject keys in this alignment group.

subject_regions

Return the list of subject regions in this alignment group.

Methods

size_ok()

Determine if the size of this molecule is ‘acceptable’ from the bounded molecule type.

sub_region(qstart, qend, atype)

Produce a new alignment group with sub-regions of the query region and subject regions at the specified new indicies.

Initialize a new PCRProductAlignmentGroup. Represents a PCR product. Query region end points are determined from the first non-None alignment and the last non-None alignment. Produces one new alignment, the template alignment, which is the intersection of the provided template alignment and the query_region, which represents the exact region for which PCR primers ought to align in a PCR reaction.

Parameters
  • fwd (Optional[Alignment]) – the forward primer alignment. Can be ‘inside’ the template or have an overhang.

  • template (Alignment) – template alignment

  • rev (Optional[Alignment]) – the reverse primer alignment. Can be ‘within’ the template or have an overhang.

  • group_type (str) – group type name

  • meta (Optional[dict]) – extra meta data

__init__(fwd, template, rev, query_region, group_type, meta=None)[source]

Initialize a new PCRProductAlignmentGroup. Represents a PCR product. Query region end points are determined from the first non-None alignment and the last non-None alignment. Produces one new alignment, the template alignment, which is the intersection of the provided template alignment and the query_region, which represents the exact region for which PCR primers ought to align in a PCR reaction.

Parameters
  • fwd (Optional[Alignment]) – the forward primer alignment. Can be ‘inside’ the template or have an overhang.

  • template (Alignment) – template alignment

  • rev (Optional[Alignment]) – the reverse primer alignment. Can be ‘within’ the template or have an overhang.

  • group_type (str) – group type name

  • meta (Optional[dict]) – extra meta data

Methods

__init__(fwd, template, rev, query_region, …)

Initialize a new PCRProductAlignmentGroup.

size_ok()

Determine if the size of this molecule is ‘acceptable’ from the bounded molecule type.

sub_region(qstart, qend, atype)

Produce a new alignment group with sub-regions of the query region and subject regions at the specified new indicies.

Attributes

alignments

meta

name

query_key

Return the query key associated with the query region.

query_region

subject_keys

Return the list of subject keys in this alignment group.

subject_regions

Return the list of subject regions in this alignment group.

type

property query_key

Return the query key associated with the query region.

Return type

str

size_ok()

Determine if the size of this molecule is ‘acceptable’ from the bounded molecule type.

Returns

whether this passes the size requirement of the molecule type.

sub_region(qstart, qend, atype)

Produce a new alignment group with sub-regions of the query region and subject regions at the specified new indicies.

Return type

AlignmentGroupBase

property subject_keys

Return the list of subject keys in this alignment group.

property subject_regions

Return the list of subject regions in this alignment group.

Return type

List[Region]