Commit 3724b0e2 by cmaffeo2

### Allow crossover "type" to be specified

parent b37c4817
 ... @@ -823,7 +823,7 @@ class DoubleStrandedSegment(Segment): ... @@ -823,7 +823,7 @@ class DoubleStrandedSegment(Segment): end3 = end3.end3 end3 = end3.end3 self._connect_ends( self.end5, end3, type_, force_connection = force_connection ) self._connect_ends( self.end5, end3, type_, force_connection = force_connection ) def add_crossover(self, nt, other, other_nt, strands_fwd=(True,False), nt_on_5prime=True): def add_crossover(self, nt, other, other_nt, strands_fwd=(True,False), nt_on_5prime=True, type_="crossover"): """ Add a crossover between two helices """ """ Add a crossover between two helices """ ## Validate other, nt, other_nt ## Validate other, nt, other_nt ## TODO ## TODO ... @@ -842,7 +842,7 @@ class DoubleStrandedSegment(Segment): ... @@ -842,7 +842,7 @@ class DoubleStrandedSegment(Segment): # TODOTODO: may need to subtract or add a little depending on 3prime/5prime # TODOTODO: may need to subtract or add a little depending on 3prime/5prime assert(c >= 0 and c <= 1) assert(c >= 0 and c <= 1) other_loc = other.get_location_at(c, strands_fwd[1]) other_loc = other.get_location_at(c, strands_fwd[1]) self._connect(other, Connection( loc, other_loc, type_="crossover" )) self._connect(other, Connection( loc, other_loc, type_=type_ )) if nt_on_5prime: if nt_on_5prime: loc.is_3prime_side_of_connection = False loc.is_3prime_side_of_connection = False other_loc.is_3prime_side_of_connection = True other_loc.is_3prime_side_of_connection = True ... ...
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment