Skip to content

Commit

Permalink
Add direction to alignment annotations
Browse files Browse the repository at this point in the history
  • Loading branch information
veghp committed Dec 10, 2024
1 parent 483ecf4 commit 206bf5a
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions ediacara/Comparator.py
Original file line number Diff line number Diff line change
Expand Up @@ -376,8 +376,6 @@ def interpret_asm(self):
else:
self.wrong_length = False

part_type = "assembly" # all aln entries should be the asm seq

# ALIGNMENT ANALYSIS (asm aligned to ref)
# This block finds ins/del using unaligned sections:
# Deletions (investigate Target Start/End)
Expand Down Expand Up @@ -446,11 +444,17 @@ def interpret_asm(self):
)
self.ref.features.append(feature)

part_type = "assembly" # all aln entries should be the asm seq

for index, row in self.aln.iterrows():
# ALIGNMENT FEATURE
# This block adds a feature showing the alignment:
if row["strand"] == "+":
strand = +1
else:
strand = -1
location = SeqFeature.FeatureLocation(
row["target_start"], row["target_end"]
row["target_start"], row["target_end"], strand=strand
)
feature = SeqFeature.SeqFeature(
location=location,
Expand Down

0 comments on commit 206bf5a

Please sign in to comment.