Skip to content

Commit

Permalink
flip pos, END where needed
Browse files Browse the repository at this point in the history
  • Loading branch information
brentp committed Feb 12, 2019
1 parent 2dc7f91 commit 5c30ffd
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions svtools/lmerge.py
Original file line number Diff line number Diff line change
Expand Up @@ -242,6 +242,16 @@ def create_merged_variant(BP, c, v_id, vcf, use_product, weighting_scheme='unwei
[cipos95, ciend95]=getCI95( p_L, p_R, max_i_L, max_i_R)
new_pos_L = new_start_L + max_i_L
new_pos_R = new_start_R + max_i_R

# sometimes after looking at PRs, the left and right can be swapped.
# flip them back so downstream tools don't break.
if new_pos_R < new_pos_L:
new_pos_R, new_pos_L = new_pos_L, new_pos_R
cipos95, ciend95 = ciend95, cipos95
p_L, p_R = p_R, p_L
max_i_R, max_i_L = max_i_L, max_i_R


BP0=BP[c[0]]
A=BP0.l.rstrip().split('\t', 10)

Expand Down

0 comments on commit 5c30ffd

Please sign in to comment.