Package atmopy :: Package display :: Module matplotlib_ext
[show private | hide private]
[frames | no frames]

Module atmopy.display.matplotlib_ext

Function Summary
int dstep(config, date)
Returns the time index of a given date in a data array defined by a configuration file.
matplotlib.lines segplot(x, y, fmt, maxdelta, **kwargs)
Plots x versus y, breaking the plot at any point where x[i] - x[i-1] > maxdelta.
matplotlib.lines segplot_date(x, y, fmt, maxdelta, **kwargs)
Plots x versus y with dates, breaking the plot at any point where x[i] - x[i-1] > maxdelta.
matplotlib.lines segplot_logx(x, y, fmt, maxdelta, **kwargs)
Plots log(x) versus y, breaking the plot at any point where x[i] - x[i-1] > maxdelta.
  set_style1(lines)
Sets parameters for specified lines, style #1.
  set_style2(lines)
Sets parameters for specified lines, style #2.
  set_style_fromconfig(config, section, lines)
Searches for style variables in specified section of configstream, and applies the style to the given lines.

Function Details

dstep(config, date)

Returns the time index of a given date in a data array defined by a configuration file.
Parameters:
config - The configuration or the configuration file.
           (type=Config or string)
date
           (type=string or datetime.datetime)
Returns:
The time index corresponding to 'date' in the data array defined in 'config'.
           (type=int)

segplot(x, y, fmt, maxdelta, **kwargs)

Plots x versus y, breaking the plot at any point where x[i] - x[i-1] > maxdelta. kwargs are passed on to plot.
Parameters:
x - Data to plot in absciss.
           (type=sequence of float or int)
y - Data to plot in ordinates
           (type=sequence of float or int)
fmt - Line style and color, combined in a single format string, as in 'bo' for blue circles. See Matplotlib 'plot' command for more details.
           (type=string)
maxdelta - Maximum delta between two consecutive x values for which a line should be drawn.
           (type=float or int)
kwargs - The **kwargs can be used to set line properties (any property that has a set_* method). You can use this to set a line label (for auto legends), linewidth, anitialising, marker face color, etc. See Matplotlib 'plot' command documentation for more details.
           (type=keyword argument list)
Returns:
The list of plotted lines.
           (type=matplotlib.lines)

segplot_date(x, y, fmt, maxdelta, **kwargs)

Plots x versus y with dates, breaking the plot at any point where x[i] - x[i-1] > maxdelta. kwargs are passed on to plot
Parameters:
x - Dates to plot in absciss.
           (type=sequence of dates represented as float days)
y - y values at those dates.
           (type=sequence of float or int)
fmt - Line style and color, combined in a single format string, as in 'bo' for blue circles. See Matplotlib 'plot' command for more details.
           (type=string)
maxdelta - Maximum delta between two consecutive x values for which a line should be drawn.
           (type=float or int)
kwargs - The **kwargs can be used to set line properties (any property that has a set_* method). You can use this to set a line label (for auto legends), linewidth, anitialising, marker face color, etc. See Matplotlib 'plot' command documentation for more details.
           (type=keyword argument list)
Returns:
The list of plotted lines.
           (type=matplotlib.lines)

segplot_logx(x, y, fmt, maxdelta, **kwargs)

Plots log(x) versus y, breaking the plot at any point where x[i] - x[i-1] > maxdelta. kwargs are passed on to plot.
Parameters:
x - Data to plot in abscissa.
           (type=sequence of float or int)
y - Data to plot in ordinates
           (type=sequence of float or int)
fmt - Line style and color, combined in a single format string, as in 'bo' for blue circles. See Matplotlib 'plot' command for more details.
           (type=string)
maxdelta - Maximum delta between two consecutive x values for which a line should be drawn.
           (type=float or int)
kwargs - The **kwargs can be used to set line properties (any property that has a set_* method). You can use this to set a line label (for auto legends), linewidth, anitialising, marker face color, etc. See Matplotlib 'plot' command documentation for more details.
           (type=keyword argument list)
Returns:
The list of plotted lines.
           (type=matplotlib.lines)

set_style1(lines)

Sets parameters for specified lines, style #1. Style is red, continuous line, 1.5 width, antialiased.
Parameters:
lines - Lines to set this predefined style to.
           (type=matplotlib.lines)

set_style2(lines)

Sets parameters for specified lines, style #2. Style is blue, discontinuous line, 1.0 width, antialiased.
Parameters:
lines - Lines to set this predefined style to.
           (type=matplotlib.lines)

set_style_fromconfig(config, section, lines)

Searches for style variables in specified section of configstream, and applies the style to the given lines. Style must have following entries : antialiased (True/False) color (r,y,...) linestyle (-, --, ...) linewidth (float) grid (True/False) date_format (date format, ie %d/%m/%y) labels_rotation (integer) For more details about style options, see matplotlib reference page.
Parameters:
config - The configstream containing the style definition.
           (type=ConfigStream)
section - Name of the section in ConfigStream in which the style is defined.
           (type=string)
lines - Lines to apply the loaded style to.
           (type=matplotlib.lines)

Generated by Epydoc 2.1 on Tue May 19 10:37:13 2009 http://epydoc.sf.net