diff --git a/gwinc/__main__.py b/gwinc/__main__.py index 1f466ed711cd6a196b08cb29b1ff5b7a1979e165..a773c1c8653d5f4ac34d5b5baeb6b78090a489d9 100644 --- a/gwinc/__main__.py +++ b/gwinc/__main__.py @@ -57,6 +57,8 @@ group.add_argument('--save', '-s', help="save figure to file") group.add_argument('--interactive', '-i', action='store_true', help="open interactive shell when plotting") +group.add_argument('--no-plot', '-np', action='store_false', dest='plot', + help="supress plotting") parser.add_argument('IFO', nargs='?', default=IFO, help="IFO name or description file path (.yaml or .mat)") @@ -140,7 +142,7 @@ You may interact with plot using "plt." methods, e.g.: ipshell.run_code("plot_noise(noises)") ipshell.run_code("plt.title('{}')".format(title)) ipshell() - else: + elif args.plot: plot_noise(noises) plt.title(title) if args.save: