Skip to content

Commit

Permalink
Error in coordiates recomputation fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
karel-brinda committed Aug 14, 2015
1 parent a5e97cb commit f05c38b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion rnftools/utils/ChainSequence.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ def zero_based_transl(self,coordinate):
(left1,right1),(left2,right2)=self._interval_pairs[p]
assert right1-left1>0
slope=1.0*(right2-left2)/(right1-left1)
translated_coordinate=int(round(left2+slope*(right1-left1)))
translated_coordinate=int(round(left2+slope*(coordinate-left1)))
return translated_coordinate

def one_based_transl(self, coordinate):
Expand Down

0 comments on commit f05c38b

Please sign in to comment.