Table of Contents

Module: graph ..\graph.py

Graph.py provides a collection of methods for making quick-plots of a data object in a variety of ways.

Functions   
addeimage
animation
colorimage
contour
histogram
image
lineplot
mapimage
scatter
  addeimage 
addeimage ( mapname='outlsupu' )

Pop up the GUI for fetching an image via ADDE and then display it. <mapname> is the filename of the basemap file to use (def=outlsupu)

  animation 
animation (
        data,
        width=400,
        height=500,
        title="VisAD Animation",
        )

Quick plot of an animation. <data> is a list/tuple of iamges to animate. <width> and <height> are the size, and <title> is the label for the titlebar. Returns a reference to the display.

  colorimage 
colorimage (
        red_data,
        green_data,
        blue_data,
        panel=None,
        colortable=None,
        width=400,
        height=400,
        title="VisAD Color Image",
        )

Display a color image, from three images <red_data>, <green_data> and <blue_data>. <panel> is the name of a panel to put this into (default= make a new one), <colortable> is a color table to use (def = gray scale), <width> and <height> are the dimensions. <title> is the phrase for the title bar. Returns a reference to the display.

  contour 
contour (
        data,
        panel=None,
        enableLabels=1,
        interval=None,
        width=400,
        height=400,
        title="VisAD Contour Plot",
        )

Quick plot of a contour (isopleth) from <data>. <panel> is the name of a panel to put this into (default= make a new one), <enableLabels> controls whether the contour lines will be labelled, <interval[4]> is a list containing the contour interval info (interval, minimum, maximum, base), <width> and <height> are the dimensions, <title> is the phrase for the title bar. Returns a reference to the display.

  histogram 
histogram (
        data,
        bins=20,
        width=400,
        height=400,
        title="VisAD Histogram",
        color=None,
        panel=None,
        )

Quick plot of a histogram from <data>. <bins> is the number of bins to use (def = 20), <panel> is the name of a panel to put this into (default= make a new one), <color> is the color to use, <width> and <height> are the dimensions, <title> is the phrase for the title bar. Returns a reference to the display.

quick look histogram - only first range component is used.

  image 
image (
        data,
        panel=None,
        colortable=None,
        width=400,
        height=400,
        title="VisAD Image",
        )

Display an image with a gray scale color mapping. <data> contains the image, <panel> is the name of a panel to put this into (default= make a new one), <colortable> is a color table to use (def = gray scale), <width> and <height> are the dimensions. <title> is the phrase for the title bar. Returns a reference to the display.

  lineplot 
lineplot (
        data,
        panel=None,
        color=None,
        width=400,
        height=400,
        title="Line Plot",
        )

Quick plot of a line plot from <data>. <panel> is the name of a panel to put this into (default= make a new one), <color> is the color to use, <width> and <height> are the dimensions, <title> is the phrase for the title bar. Returns a reference to the display.

a simple line plot for one parameter

  mapimage 
mapimage (
        imagedata,
        mapfile="outlsupw",
        panel=None,
        colortable=None,
        width=400,
        height=400,
        lat=None,
        lon=None,
        title="VisAD Image and Map",
        )

Display an image with a basemap. <imagedata> is the image object, <mapfile> is the name of the map file to use (def = outlsupw). <panel> is the name of a panel to put this into (default= make a new one), <colortable> is a color table to use (def = gray scale), <width> and <height> are the dimensions. <lat> and <lon> are lists/tuples of the range (min->max) of the domain (def = compute them). <title> is the phrase for the title bar. Returns a reference to the display.

mapimage displays a navigatedimage with a basemap on top

  scatter 
scatter (
        data_1,
        data_2,
        panel=None,
        pointsize=None,
        width=400,
        height=400,
        xlabel=None,
        ylabel=None,
        title="VisAD Scatter",
        )

Quick plot of a scatter diagram between <data_1> and <data_2>. <panel> is the name of a panel to put this into (default= make a new one), <pointsize> is the size of the scatter points (def = 1), <width> and <height> are the dimensions, <xlabel> and <ylabel> are the axes labels to use (def = names of data objects). <title> is the phrase for the title bar. Returns a reference to the display.

basic scatter plot between two fields.

Classes   

myAnimFrame

Supporting class for animations.


Table of Contents

This document was automatically generated on Wed Feb 26 13:00:02 2003 by HappyDoc version 2.1