Skip to content

Commit 7be0975

Browse files
committed
plot_painting.py: fix namespace and set axis range
1 parent 8823744 commit 7be0975

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

scripts/plot_painting.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
#!/usr/bin/env python3
2-
"""
2+
'''
33
Summarise species composition of Genome Painter results into blocks of n size and generate plot.
44
55
Output is an interactive plotly plot which can be viewed in a modern web brower
66
77
Example usage:
88
./plot_painting.py --genome_painter_fp genome_painter_results.tsv.gz --output_fp genome_painter_plot.html
9-
"""
9+
'''
1010

1111

1212
import argparse
@@ -140,9 +140,10 @@ def main():
140140
layout = {'shapes': contig_shapes}
141141
else:
142142
layout = plotly.graph_objs.Layout()
143+
layout['yaxis'] = dict(range=[-5, 5])
143144

144145
# Create plot
145-
plotly.offline.plot({'data': traces, 'layout': layout}, show_link=False, auto_open=False, filename=output_fp)
146+
plotly.offline.plot({'data': traces, 'layout': layout}, show_link=False, auto_open=False, filename=args.output_fp)
146147

147148

148149
def get_filehandle_class(filepath):

0 commit comments

Comments
 (0)