Last modified: 12 December 2018

How do I plot a curve from a file?


The make_figure and add_curve commands can plot data from a file (in both FITS binary and ASCII formats).

  1. Two columns: A set of (x,y) points.

    make_figure("file.lis[cols x,y]")
    add_curve("file.lis[cols x,y]")
    

    This will plot up columns x and y from the file file.lis.

  2. Three columns: A set of (x,y) points with symmetric errors on y.

    make_figure("file.lis[cols x,y,dy]")
    add_curve("file.lis[cols x,y,dy]")
    

    This will plot up columns x and y from the file file.lis, and draw symmetric error bars whose length is given by the dy column. The dy values should be >= 0.

  3. Four columns: A set of (x,y) points with asymmetric errors on y.

    make_figure("file.lis[cols x,y,dylo,dyhi]")
    add_curve("file.lis[cols x,y,dylo,dyhi]")
    

    This will plot up columns x and y from the file file.lis, and draw asymmetric error bars whose lengths are given by the dylo and dyhi columns (which should both be >= 0).