# HG changeset patch # User devteam # Date 1496496570 14400 # Node ID efda9a4a50e7dfd16b05cb4a7fa68b552cef6d80 # Parent 4f8b9e70fda03cea19b69c09ee8240dfcc44779a planemo upload for repository https://github.com/galaxyproject/tools-devteam/tree/master/tools/scatterplot commit 405b0656c97b3971605e09f77cf46ca1f4870346 diff -r 4f8b9e70fda0 -r efda9a4a50e7 scatterplot.py --- a/scatterplot.py Thu Sep 15 11:14:37 2016 -0400 +++ b/scatterplot.py Sat Jun 03 09:29:30 2017 -0400 @@ -1,6 +1,8 @@ #!/usr/bin/env python # Greg Von Kuster +from __future__ import print_function + import sys from numpy import array @@ -35,7 +37,7 @@ invalid_value = '' invalid_column = 0 i = 0 - for i, line in enumerate( file( in_fname ) ): + for i, line in enumerate( open( in_fname ) ): valid = True line = line.rstrip( '\r\n' ) if line and not line.startswith( '#' ): @@ -74,14 +76,14 @@ r.pdf( out_fname, 8, 8 ) r.plot( a, type="p", main=title, xlab=xlab, ylab=ylab, col="blue", pch=19 ) r.dev_off() - except Exception, exc: + except Exception as exc: stop_err( "%s" % str( exc ) ) else: stop_err( "All values in both columns %s and %s are non-numeric or empty." % ( sys.argv[3], sys.argv[4] ) ) - print "Scatter plot on columns %s, %s. " % ( sys.argv[3], sys.argv[4] ) + print("Scatter plot on columns %s, %s. " % ( sys.argv[3], sys.argv[4] )) if skipped_lines > 0: - print "Skipped %d lines starting with line #%d, value '%s' in column %d is not numeric." % ( skipped_lines, first_invalid_line, invalid_value, invalid_column ) + print("Skipped %d lines starting with line #%d, value '%s' in column %d is not numeric." % ( skipped_lines, first_invalid_line, invalid_value, invalid_column )) if __name__ == "__main__": main() diff -r 4f8b9e70fda0 -r efda9a4a50e7 scatterplot.xml --- a/scatterplot.xml Thu Sep 15 11:14:37 2016 -0400 +++ b/scatterplot.xml Sat Jun 03 09:29:30 2017 -0400 @@ -1,12 +1,20 @@ - + of two numeric columns numpy - - R - rpy2 + rpy2 - scatterplot.py $input $out_file1 $col1 $col2 "$title" "$xlab" "$ylab" + + @@ -29,7 +37,7 @@ - + + +