Skip to content

Commit

Permalink
BUGFIX: correct off-by-one error in BED output
Browse files Browse the repository at this point in the history
The BED-formatted output was not correctly reverting
intron start coordinates to 0-based indexing as
required by the BED format spec. Thanks to @MichaelHiller for bringing
this to my attention.
  • Loading branch information
glarue committed Jan 10, 2024
1 parent ee2b884 commit 99b5aaa
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions intronIC/intronIC.py
Original file line number Diff line number Diff line change
Expand Up @@ -4251,6 +4251,7 @@ def output_format(
attribs.insert(1, rounded_score)
attribs.insert(2, dnts)
elif out_type == 'BED':
attribs[1] -= 1 # revert start to 0-based indexing
attribs.insert(3, label)
if separator is not None:
attribs = separator.join([str(a) for a in attribs])
Expand Down

0 comments on commit 99b5aaa

Please sign in to comment.