Commit 3724b0e2 authored by cmaffeo2's avatar cmaffeo2
Browse files

Allow crossover "type" to be specified

parent b37c4817
......@@ -823,7 +823,7 @@ class DoubleStrandedSegment(Segment):
end3 = end3.end3
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 """
## Validate other, nt, other_nt
## TODO
......@@ -842,7 +842,7 @@ class DoubleStrandedSegment(Segment):
# TODOTODO: may need to subtract or add a little depending on 3prime/5prime
assert(c >= 0 and c <= 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:
loc.is_3prime_side_of_connection = False
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