diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..7dee378 --- /dev/null +++ b/.gitignore @@ -0,0 +1,3 @@ +.DS_Store + +.idea/ \ No newline at end of file diff --git a/pplot b/pplot index 8ddb154..c3f710c 100755 --- a/pplot +++ b/pplot @@ -6,10 +6,12 @@ import re import getopt marker = '.' -opts, args = getopt.getopt(sys.argv[1:], 'l') +opts, args = getopt.getopt(sys.argv[1:], 'lS') for o, a in opts: if o == '-l': marker = '.-' + elif o == '-S': + plt.gca().set_aspect(1.0) x = [] y = [] @@ -21,4 +23,6 @@ for line in sys.stdin: plt.plot(x, y, marker) plt.minorticks_on() plt.grid(which='both', color='#aaaaaa') +# add a little bit of margin around the figure so that minimal/maximal points are easier to see +plt.margins(0.05) plt.savefig(sys.stdout, format='png')