Skip to content

Commit

Permalink
default to unique region barchart
Browse files Browse the repository at this point in the history
  • Loading branch information
Chien-Chi Lo committed Sep 29, 2020
1 parent 92ae075 commit 409edd6
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions amplicov/amplicov
Original file line number Diff line number Diff line change
Expand Up @@ -181,8 +181,8 @@ def barplot(mean_dict,uniq_mean_d,input_bed,overall_mean,outdir,prefix):
uniq_y=list(uniq_mean_d.values())
barcolor1 = ['lightsalmon' if i >= 20 else 'blue' if i >5 else 'black' for i in y]
barcolor2 = ['lightsalmon' if i >= 20 else 'blue' if i >5 else 'black' for i in uniq_y]
fig = go.Figure(data=[go.Bar(x=x, y=y, marker_color=barcolor1)])
fig.add_trace(go.Bar(x=uniq_x,y=uniq_y,marker_color=barcolor2,visible=False))
fig = go.Figure(data=[go.Bar(x=x, y=y, marker_color=barcolor1,visible=False)])
fig.add_trace(go.Bar(x=uniq_x,y=uniq_y,marker_color=barcolor2,visible=True))

depthMean = [dict(type='line',
xref='paper',x0=0,x1=1,
Expand Down Expand Up @@ -242,13 +242,12 @@ def barplot(mean_dict,uniq_mean_d,input_bed,overall_mean,outdir,prefix):
),
dict(
buttons=list([
dict(label='Whole Amplicon',
method='update',
args=[{"visible": [True, False]}]),
dict(label='Unique',
method='update',
args=[{"visible": [False, True]}])

args=[{"visible": [False, True]}]),
dict(label='Whole Amplicon',
method='update',
args=[{"visible": [True, False]}])
]),
direction="down",
x=0.15,
Expand Down

0 comments on commit 409edd6

Please sign in to comment.