Skip to content

Commit

Permalink
Add padding between junction arcs to avoid overlapping - #11
Browse files Browse the repository at this point in the history
  • Loading branch information
emi80 committed Mar 24, 2021
1 parent a059577 commit 6cc291e
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions ggsashimi.py
Original file line number Diff line number Diff line change
Expand Up @@ -919,7 +919,8 @@ def get_debug_info():
# Find intron midpoint
xmid = round(mean(j[1:2]), 1)
ymid = max(j[3:4]) * 1.2
ypad = 0.2*(j[2]-j[1])/(max(d[,x])-min(d[,x]))
ymid = max(j[3:4]) * (1 + ypad)
# Thickness of the arch
lwd = scale_lwd(j[5]/j_tot_counts)
Expand All @@ -931,7 +932,7 @@ def get_debug_info():
# Choose position of the arch (top or bottom)
nss = i
if (nss%%%%2 == 0) { #bottom
ymid = -0.3 * maxheight
ymid = -(0.2 + ypad) * maxheight
# Draw the arcs
# Left
curve = xsplineGrob(x=c(0, 0, 1, 1), y=c(1, 0, 0, 0), shape=1, gp=curve_par)
Expand Down

0 comments on commit 6cc291e

Please sign in to comment.