Changeset 6239


Ignore:
Timestamp:
Jan 29, 2009, 3:25:40 PM (10 years ago)
Author:
rwilson
Message:

Updated the README - now explains usage better.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • misc/tools/plotcsv/README

    r6235 r6239  
    1 This directory holds development code for the 'plotcsv' program
    2 which plots time-series data in a CSV file to a screen window.
     1This directory holds the code for the 'plotcsv' program.  This program
     2is meant to be used to view stage versus time from an ANUGA *.csv data
     3file and compare a similar graph from another file as a quality assurance
     4step.
    35
    4 Ideally, the program will stop running but leave the plot window
    5 on the screen, to be closed by the user.  CAN'T DO THIS IN MATPLOTLIB!?
     6Usage:  plotcsv.py <options> <filename>
     7where <filename> is the path to the data file to plot
     8  and <options>  is zero or more of:
     9                   -x <datacol> where <datacol> is a column specifier,
     10                   -y <datacol>     either a number or a header string
     11                   -v <range>   force a range in Y axis values, of the form
     12                                    <min>,<max>, eq, "-5,10"
     13                   -h           prints this help
    614
    7 Also, the user would like to be able to specify a fixed Y axis scale
    8 to make comparison of two plots 'by eye' easier.
     15The <datacol> values above may be either a column number (starting from the
     16left at column 0) or a string that must match one of the column header
     17strings in the first line of the CSV file.  If the '-x' or '-y' options
     18x are not supplied then the X column is assumed to be column 0 and the Y
     19column is assumed to be column 1.
    920
    10 plotcsv.py
    11 A program that does the above, except it doesn't 'persist'.
     21The '-v' option can be used to force a max/min range in the Y axis to allow
     22easier comparison of two graphs that would otherwise autoscale the Y axis
     23differently.
    1224
    13 To use it:
    14 plotcsv.py -x time -y stage test.csv
     25Ideally, the program will stop running but leave the plot window on the screen,
     26to be closed by the user, but this doesn't appear possible with matplotlib.
     27
     28For example, try:
     29    plotcsv.py -x time -y stage test.csv
    1530or
    16 plotcsv.py -x time -y stage -v -2,25 test.csv
     31    plotcsv.py -x time -y stage -v -2,25 test.csv
    1732or
    18 plotcsv.py -x time -y depth test.csv
     33    plotcsv.py -x time -y depth test.csv
    1934or
    20 plotcsv.py -x 0 -y 1 test.csv
     35    plotcsv.py -x 0 -y 1 test.csv
    2136or even
    22 plotcsv.py test.csv
     37    plotcsv.py test.csv
    2338
    24 To get help:
    25 plotcvs.py -h
Note: See TracChangeset for help on using the changeset viewer.