@header@
 
 
matplotlib.matlab
index
/usr/local/lib/python2.3/site-packages/matplotlib/matlab.py

This is a matlab style functional interface the matplotlib.
 
The following plotting commands are provided; some of these do not
exist in matlab but have proven themselves to be useful nonetheless.
The majority of them, however, are matlab commands
 
_Plotting commands
 
  axes     - Create a new axes
  axhline  - draw a horizontal line across axes
  axvline  - draw a vertical line across axes
  axhspan  - draw a horizontal bar across axes
  axvspan  - draw a vertical bar across axes 
  axis     - Set or return the current axis limits
  bar      - make a bar chart
  barh     - a horizontal bar chart  
  cla      - clear current axes
  clf      - clear a figure window
  close    - close a figure window
  colorbar - add a colorbar to the current figure
  cohere   - make a plot of coherence
  csd      - make a plot of cross spectral density  
  draw     - Force a redraw of the current figure
  errorbar - make an errorbar graph
  figlegend - make legend on the figure rather than the axes
  figimage  - make a figure image
  figtext   - add text in figure coords
  figure   - create or change active figure
  fill     - make filled polygons
  gca      - return the current axes
  gcf      - return the current figure
  gci      - get the current image, or None
  get      - get a handle graphics property
  gray     - set the current colormap to gray
  jet      - set the current colormap to jet
  hist     - make a histogram
  hold     - set the axes hold state
  legend   - make an axes legend
  loglog   - a log log plot
  imread   - load image file into array
  imshow   - plot image data
  pcolor   - make a pseudocolor plot
  plot     - make a line plot
  polar    - make a polar plot on a PolarAxes
  psd      - make a plot of power spectral density
  rc       - control the default params
  savefig  - save the current figure
  scatter  - make a scatter plot
  set      - set a handle graphics property
  semilogx - log x axis
  semilogy - log y axis
  show     - show the figures
  specgram - a spectrogram plot
  stem     - make a stem plot
  subplot  - make a subplot (numrows, numcols, axesnum)
  table    - add a table to the plot
  text     - add some text at location x,y to the current axes
  title    - add a title to the current axes
  xlim     - set/get the xlimits
  ylim     - set/get the ylimits
  xticks   - set/get the xticks
  yticks   - set/get the yticks
  xlabel   - add an xlabel to the current axes
  ylabel   - add a ylabel to the current axes
  
_Matrix commands
 
  cumprod   - the cumulative product along a dimension
  cumsum    - the cumulative sum along a dimension
  detrend   - remove the mean or besdt fit line from an array
  diag      - the k-th diagonal of matrix 
  diff      - the n-th differnce of an array
  eig       - the eigenvalues and eigen vectors of v
  eye       - a matrix where the k-th diagonal is ones, else zero 
  find      - return the indices where a condition is nonzero  
  fliplr    - flip the rows of a matrix up/down
  flipud    - flip the columns of a matrix left/right
  linspace  - a linear spaced vector of N values from min to max inclusive
  meshgrid  - repeat x and y to make regular matrices
  ones      - an array of ones
  rand      - an array from the uniform distribution [0,1]
  randn     - an array from the normal distribution
  rot90     - rotate matrix k*90 degress counterclockwise
  squeeze   - squeeze an array removing any dimensions of length 1
  tri       - a triangular matrix
  tril      - a lower triangular matrix
  triu      - an upper triangular matrix
  vander    - the Vandermonde matrix of vector x
  svd       - singular value decomposition
  zeros     - a matrix of zeros
  
_Probability
 
  levypdf   - The levy probability density function from the char. func.
  normpdf   - The Gaussian probability density function
  rand      - random numbers from the uniform distribution
  randn     - random numbers from the normal distribution
 
_Statistics
 
  corrcoef  - correlation coefficient
  cov       - covariance matrix
  max       - the maximum along dimension m
  mean      - the mean along dimension m
  median    - the median along dimension m
  min       - the minimum along dimension m
  norm      - the norm of vector x
  prod      - the product along dimension m
  ptp       - the max-min along dimension m
  std       - the standard deviation along dimension m
  sum       - the sum along dimension m
 
_Time series analysis
 
  bartlett  - M-point Bartlett window
  blackman  - M-point Blackman window
  cohere    - the coherence using average periodiogram
  csd       - the cross spectral density using average periodiogram
  fft       - the fast Fourier transform of vector x
  hamming   - M-point Hamming window
  hanning   - M-point Hanning window
  hist      - compute the histogram of x
  kaiser    - M length Kaiser window
  psd       - the power spectral density using average periodiogram
  sinc      - the sinc function of array x
 
_Dates
 
  date2num  - convert python datetimes to numeric representation
  drange    - create an array of numbers for date plots
  num2date  - convert numeric type (float days since 0001) to datetime
  
_Other
 
  angle     - the angle of a complex array
  load     - load ASCII data into array
  polyfit   - fit x, y to an n-th order polynomial
  polyval   - evaluate an n-th order polynomial
  roots     - the roots of the polynomial coefficients in p
  save      - save an array to an ASCII file
  trapz     - trapezoidal integration
 
__end
 
Credits: The plotting commands were provided by
John D. Hunter <jdhunter@ace.bsd.uhicago.edu>
 
Most of the other commands are from the Numeric, MLab and FFT, with
the exception of those in mlab.py provided by matplotlib.

 
Modules
       
LinearAlgebra
MLab
Numeric
RandomArray
matplotlib._matlab_helpers
matplotlib.cm
copy
copy_reg
matplotlib.image
math
matplotlib
matplotlib.mlab
multiarray
matplotlib.numerix
operator
os
pickle
string
sys
types

 
Functions
       
arange(...)
arange(start, stop=None, step=1, typecode=None)
 
 Just like range() except it returns an array whose type can be
specified by the keyword argument typecode.
array(...)
array(sequence, typecode=None, copy=1, savespace=0) will return a new array formed from the given (potentially nested) sequence with type given by typecode.  If no typecode is given, then the type will be determined as the minimum type required to hold the objects in sequence.  If copy is zero and sequence is already an array, a reference will be returned.  If savespace is nonzero, the new array will maintain its precision in operations.
arrayrange = arange(...)
arange(start, stop=None, step=1, typecode=None)
 
 Just like range() except it returns an array whose type can be
specified by the keyword argument typecode.
axes(*args, **kwargs)
Add an axes at positon rect specified by::
 
axes() by itself creates a default full subplot(111) window axis
 
axes(rect, axisbg='w') where rect=[left, bottom, width, height] in
normalized (0,1) units.  axisbg is the background color for the
axis, default white
 
axes(h) where h is an axes instance makes h the
current axis An Axes instance is returned
axis(*v)
Set/Get the axis properties::
 
axis()  returns the current axis as a length a length 4 vector
 
axis(v) where v = [xmin, xmax, ymin, ymax] sets the min and max of the x
    and y axis limits
 
axis('off') turns off the axis lines and labels
 
axis('equal') sets the xlim width and ylim height to be to be
    identical.  The longer of the two intervals is chosen
changed_name_function(f, newname)
choose(...)
choose(a, (b1,b2,...))
clf()
Clear the current figure
clim(vmin=None, vmax=None)
Set the color limits of the current image
 
To apply clim to all axes images do
 
clim(0, 0.5)
 
If either vmin or vmax is None, the image min/max respectively
will be used for color scaling.
 
If you want to set the clim of multiple images,
use, for example for im in gca().get_images(): im.set_clim(0,
0.05)
close(*args)
Close a figure window
 
close() by itself closes the current figure
 
close(num) closes figure number num
 
close(h) where h is a figure handle(instance) closes that figure
 
close('all') closes all the figure windows
colorbar(tickfmt='%1.1f')
Create a colorbar for current mappable image (see gci)
 
tickfmt is a format string to format the colorbar ticks
 
return value is the colorbar axes instance
colors()
This is a do nothing function to provide you with help on how
matplotlib handles colors.
 
Commands which take color arguments can use several formats to
specify the colors.  For the basic builtin colors, you can use a
single letter
 
  b  : blue
  g  : green
  r  : red
  c  : cyan
  m  : magenta
  y  : yellow
  k  : black 
  w  : white
 
 
For a greater range of colors, you have two options.  You can
specify the color using an html hex string, as in
 
  color = '#eeefff'
 
or you can pass an R,G,B tuple, where each of R,G,B are in the
range [0,1].  The example below creates a subplot with a dark
slate gray background
 
   subplot(111, axisbg=(0.1843, 0.3098, 0.3098))
 
Here is an example that creates a pale turqoise title
 
  title('Is this the best color?', color='#afeeee')
cross_correlate(...)
cross_correlate(a,v, mode=0)
draw()
redraw the current figure
figimage(*args, **kwargs)
FIGIMAGE(X) # add non-resampled array to figure
 
FIGIMAGE(X, xo, yo) # with pixel offsets
 
FIGIMAGE(X, **kwargs) # control interpolation ,scaling, etc
 
Add a nonresampled figure to the figure from array X.  xo and yo are
offsets in pixels
 
X must be a float array
 
    If X is MxN, assume luminance (grayscale)
    If X is MxNx3, assume RGB
    If X is MxNx4, assume RGBA
 
The following kwargs are allowed: 
 
  * cmap is a cm colormap instance, eg cm.jet.  If None, default to
    the rc image.cmap valuex
 
  * norm is a matplotlib.colors.normalize instance; default is
    normalization().  This scales luminance -> 0-1
 
  * vmin and vmax are used to scale a luminance image to 0-1.  If
    either is None, the min and max of the luminance values will be
    used.  Note if you pass a norm instance, the settings for vmin and
    vmax will be ignored.
 
  * alpha = 1.0 : the alpha blending value
 
  * origin is either 'upper' or 'lower', which indicates where the [0,0]
    index of the array is in the upper left or lower left corner of
    the axes.  Defaults to the rc image.origin value
 
This complements the axes image which will be resampled to fit the
current axes.  If you want a resampled image to fill the entire
figure, you can define an Axes with size [0,1,0,1].
 
A image.FigureImage instance is returned.
figlegend(handles, labels, loc)
Place a legend in the figure.  Labels are a sequence of
strings, handles is a sequence of line or patch instances, and
loc can be a string or an integer specifying the legend
location
 
USAGE: 
  legend( (line1, line2, line3),
          ('label1', 'label2', 'label3'),
          'upper right')
 
See help(legend) for information about the location codes
 
A matplotlib.legend.Legend instance is returned
figtext(*args, **kwargs)
Add text to figure at location x,y (relative 0-1 coords) See
the help for Axis text for the meaning of the other arguments
figure(num=1, figsize=None, dpi=None, facecolor=None, edgecolor=None, frameon=True)
figure(num = 1, figsize=(8, 6), dpi=80, facecolor='w', edgecolor='k')
 
 
Create a new figure and return a handle to it
 
If figure(num) already exists, make it active and return the
handle to it.
 
  figure(1)
 
figsize - width in height x inches; defaults to rc figure.figsize
dpi     - resolution; defaults to rc figure.dpi
facecolor - the background color; defaults to rc figure.facecolor
edgecolor - the border color; defaults to rc figure.edgecolor
 
rcParams gives the default values from the .matplotlibrc file
fromstring(...)
fromstring(string, typecode='l', count=-1) returns a new 1d array initialized from the raw binary data in string.  If count is positive, the new array will have count elements, otherwise it's size is determined by the size of string.
gca(**kwargs)
Return the current axis instance.  This can be used to control
axis properties either using set or the Axes methods.
 
Example:
 
  plot(t,s)
  set(gca(), 'xlim', [0,10])  # set the x axis limits
 
or
 
  plot(t,s)
  a = gca()
  a.set_xlim([0,10])          # does the same
gcf()
Return a handle to the current figure
gci()
get the current ScalarMappable instance (image or patch
collection), or None if no images or patch collecitons have been
defined.  The commands imshow and figimage create images
instances, and the commands pcolor and scatter create patch
collection instances
get(o, s)
Return the value of handle property s
 
h is an instance of a class, eg a Line2D or an Axes or Text.
if s is 'somename', this function returns
 
  o.get_somename()
get_current_fig_manager()
get_plot_commands()
gray()
set the default colormap to gray and apply to current image if any
hold(b=None)
Set the hold state.  If hold is None (default), toggle the
hold state.  Else set the hold state to boolean value b.
 
Eg
hold()      # toggle hold
hold(True)  # hold is on
hold(False) # hold is off
imread(*args, **kwargs)
return image file in fname as numerix array
 
Return value is a MxNx4 array of 0-1 normalized floats
imshow(*args, **kwargs)
IMSHOW(X, cmap=None, norm=None, aspect=None, interpolation=None,
       alpha=1.0, vmin=None, vmax=None, origin=None, extent=None)
               
IMSHOW(X) - plot image X to current axes, resampling to scale to axes
            size (X may be numarray/Numeric array or PIL image)
 
IMSHOW(X, **kwargs) - Use keyword args to control image scaling,
colormapping etc. See below for details
 
 
Display the image in X to current axes.  X may be a float array or a
PIL image. If X is a float array, X can have the following shapes
 
    MxN    : luminance (grayscale)
 
    MxNx3  : RGB
 
    MxNx4  : RGBA
 
A matplotlib.image.AxesImage instance is returned
 
The following kwargs are allowed: 
 
  * cmap is a cm colormap instance, eg cm.jet.  If None, default to rc
    image.cmap value (Ignored when X has RGB(A) information)
 
  * aspect is one of: free or preserve.  if None, default to rc
    image.aspect value
 
  * interpolation is one of: bicubic bilinear blackman100 blackman256
    blackman64 nearest sinc144 sinc256 sinc64 spline16 or spline36.
    If None, default to rc image.interpolation
 
  * norm is a matplotlib.colors.normalize instance; default is
    normalization().  This scales luminance -> 0-1 (Ignored when X is
    PIL image).
 
  * vmin and vmax are used to scale a luminance image to 0-1.  If
    either is None, the min and max of the luminance values will be
    used.  Note if you pass a norm instance, the settings for vmin and
    vmax will be ignored.
 
  * alpha = 1.0 : the alpha blending value
 
  * origin is either upper or lower, which indicates where the [0,0]
    index of the array is in the upper left or lower left corner of
    the axes.  If None, default to rc image.origin
 
  * extent is a data xmin, xmax, ymin, ymax for making image plots
    registered with data plots.  Default is the image dimensions
    in pixels
jet()
set the default colormap to jet and apply to current image if any
load(fname)
Load ASCII data from fname into an array and return the array.
 
The data must be regular, same number of values in every row
 
fname can be a filename or a file handle
 
matfile data is not currently supported, but see
Nigel Wade's matfile ftp://ion.le.ac.uk/matfile/matfile.tar.gz
 
Example usage:
 
x,y = load('test.dat')  # data in two columns
 
X = load('test.dat')    # a matrix of data
 
x = load('test.dat')    # a single column of data
mpl_connect(s, func)
Connect event with string s to func.  The signature of func is
 
  def func(event)
 
where event is a MplEvent.  The following events are recognized
 
 'button_press_event' 
 'button_release_event' 
 'motion_notify_event' 
 
 For the three events above, if the mouse is over the axes,
 the variable event.inaxes will be set to the axes it is over,
 and additionally, the variables event.xdata and event.ydata
 will be defined.  This is the mouse location in data coords.
 See backend_bases.MplEvent.
 
return value is a connection id that can be used with
mpl_disconnect
mpl_disconnect(cid)
Connect s to func. return an id that can be used with disconnect
Method should return None
pcolor(*args, **kwargs)
PCOLOR(*args, **kwargs)        
 
Function signatures
 
  PCOLOR(C) - make a pseudocolor plot of matrix C
 
  PCOLOR(X, Y, C) - a pseudo color plot of C on the matrices X and Y
 
  PCOLOR(C, **kwargs) - Use keywork args to control colormapping and
                        scaling; see below
 
Optional keywork args are shown with their defaults below (you must
use kwargs for these):
 
  * cmap = cm.jet : a cm Colormap instance from matplotlib.cm.
    defaults to cm.jet
         
  * norm = normalize() : matplotlib.colors.normalize is used to scale
    luminance data to 0,1.
 
  * vmin=None and vmax=None : vmin and vmax are used in conjunction
    with norm to normalize luminance data.  If either are None, the
    min and max of the color array C is used.  If you pass a norm
    instance, vmin and vmax will be None
        
  * shading = 'flat' : or 'faceted'.  If 'faceted', a black grid is
    drawn around each rectangle; if 'flat', edge colors are same as
    face colors
 
  * alpha=1.0 : the alpha blending value
  
Return value is a matplotlib.collections.PatchCollection
object
 
Grid Orientation
 
    The behavior of meshgrid in matlab is a bit counterintuitive for
    x and y arrays.  For example,
 
        x = arange(7)
        y = arange(5)
        X, Y = meshgrid(x,y)
 
        Z = rand( len(x), len(y))
        pcolor(X, Y, Z)
 
    will fail in matlab and matplotlib.  You will probably be
    happy with
 
        pcolor(X, Y, transpose(Z))
 
    Likewise, for nonsquare Z,
 
        pcolor(transpose(Z))
 
    will make the x and y axes in the plot agree with the numrows and
    numcols of Z
plotting()
Plotting commands
axes     - Create a new axes
axis     - Set or return the current axis limits
bar      - make a bar chart
cla      - clear current axes
clf      - clear a figure window
close    - close a figure window
colorbar - add a colorbar to the current figure
cohere   - make a plot of coherence
csd      - make a plot of cross spectral density
draw     - force a redraw of the current figure
errorbar - make an errorbar graph
figlegend - add a legend to the figure
figimage - add an image to the figure, w/o resampling
figtext  - add text in figure coords
figure   - create or change active figure
fill     - make filled polygons
gca      - return the current axes
gcf      - return the current figure
gci      - get the current image, or None
get      - get a handle graphics property
gray     - set the current colormap to gray
jet      - set the current colormap to jet
hist     - make a histogram
hold     - set the hold state on current axes
legend   - add a legend to the axes
loglog   - a log log plot
imread   - load image file into array
imshow   - plot image data
pcolor   - make a pseudocolor plot
plot     - make a line plot
psd      - make a plot of power spectral density
rc       - control the default params
savefig  - save the current figure
scatter  - make a scatter plot
set      - set a handle graphics property
semilogx - log x axis
semilogy - log y axis
show     - show the figures
specgram - a spectrogram plot
stem     - make a stem plot
subplot  - make a subplot (numrows, numcols, axesnum)
table    - add a table to the axes
text     - add some text at location x,y to the current axes
title    - add a title to the current axes
xlabel   - add an xlabel to the current axes
ylabel   - add a ylabel to the current axes
polar(*args, **kwargs)
POLAR(theta, r)
 
Make a polar plot.  Multiple theta, r arguments are supported,
with format strings, as in plot.
raise_msg_to_str(msg)
msg is a return arg from a raise.  Join with new lines
rc(*args, **kwargs)
Set the current rc params.  Group is the grouping for the rc, eg
for lines.linewidth the group is 'lines', for axes.facecolor, the
group is 'axes', and so on.  kwargs is a list of attribute
name/value pairs, eg
 
  rc('lines', linewidth=2, color='r')
 
sets the current rc params and is equivalent to
 
  rcParams['lines.linewidth'] = 2
  rcParams['lines.color'] = 'r'
 
The following aliases are available to save typing for interactive
users
    'lw'  : 'linewidth'
    'ls'  : 'linestyle'        
    'c'   : 'color'
    'fc'  : 'facecolor'
    'ec'  : 'edgecolor'
    'mfc' : 'markerfacecolor'
    'mec' : 'markeredgecolor'
    'mew' : 'markeredgewidth'
    'aa'  : 'antialiased'            
    'l'   : 'lines'
    'a'   : 'axes'
    'f'   : 'figure'
    'p'   : 'patches'
    'g'   : 'grid'
 
Thus you could abbreviate the above rc command as
 
      rc('l', lw=2, c='r')
 
 
Note you can use python's kwargs dictionary facility to store
dictionaries of default parameters.  Eg, you can customize the
font rc as follows
 
  font = {'family' : 'monospace',
          'weight' : 'bold',
          'size'   : 'larger',
         }
 
  rc('font', **font)  # pass in the font dict as kwargs
 
This enables you to easily switch between several configurations.
Use rcdefaults to restore the default rc params after changes.
rcdefaults()
Restore the default rc params - the ones that were created at
matplotlib load time
reshape(...)
reshape(a, (d1, d2, ..., dn)).  Change the shape of a to be an n-dimensional array with dimensions given by d1...dn.  Note: the size specified for the new array must be exactly equal to the size of the  old one or an error will occur.
save(fname, X, fmt='%1.4f')
Save the data in X to file fname using fmt string to convert the
data to strings
 
fname can be a filename or a file handle    
 
Example usage:
 
save('test.out', X)         # X is an array
save('test1.out', (x,y,z))  # x,y,z equal sized 1D arrays
save('test2.out', x)        # x is 1D
save('test3.out', x, fmt='%1.4e')  # use exponential notation
savefig(*args, **kwargs)
SAVEFIG(fname, dpi=150, facecolor='w', edgecolor='w',
        orientation='portrait'):
 
Save the current figure to filename fname.  dpi is the resolution
in dots per inch.
 
Output file types currently supported are jpeg and png and will be
deduced by the extension to fname
 
facecolor and edgecolor are the colors os the figure rectangle
 
orientation is either 'landscape' or 'portrait' - not supported on
all backends; currently only on postscript output.
searchsorted = binarysearch(...)
binarysearch(a,v)
set(h, *args, **kwargs)
Set handle h property in string s to value val
 
h can be a handle or vector of handles.
 
h is an instance (or vector of instances) of a class, eg a Line2D
or an Axes or Text.
 
args is a list of string, value pairs.  if the string
is 'somename', set function calls
 
  o.set_somename(value)
 
for every instance in h.
specgram(*args, **kwargs)
SPECGRAM(x, NFFT=256, Fs=2, detrend=mlab.detrend_none,
         window=mlab.window_hanning, noverlap=128,
         cmap=None, xextent=None)
                 
Compute a spectrogram of data in x.  Data are split into NFFT length
segements and the PSD of each section is computed.  The windowing
function window is applied to each segment, and the amount of overlap
of each segment is specified with noverlap.  
 
    * cmap is a colormap; if None use default determined by rc
 
    * xextent is the image extent in the xaxes xextent=xmin, xmax -
      default 0, max(bins), 0, max(freqs) where bins is the return
      value from matplotlib.mlab.specgram
 
    * See help(psd) for information on the other keyword arguments.
 
Return value is (Pxx, freqs, bins, im), where
 
    bins are the time points the spectrogram is calculated over
 
    freqs is an array of frequencies
 
    Pxx is a len(times) x len(freqs) array of power
 
    im is a matplotlib.image.AxesImage.
subplot(*args, **kwargs)
Create a subplot command, creating axes with
 
  subplot(numRows, numCols, plotNum)
 
where plotNum=1 is the first plot number and increasing plotNums
fill rows first.  max(plotNum)==numRows*numCols
 
You can leave out the commas if numRows<=numCols<=plotNum<10, as
in
 
  subplot(211)    # 2 rows, 1 column, first (upper) plot
 
subplot(111) is the default axis
 
The background color of the subplot can be specified via keyword
argument 'axisbg', which takes a color string or gdk.Color as value, as in
 
subplot(211, axisbg='y')
take(...)
take(a, indices, axis=0).  Selects the elements in indices from array a along the given axis.
title(s, *args, **kwargs)
Set the title of the current axis to s
 
Default font override is:
  override = {
    'fontsize'            : 'medium',
    'verticalalignment'   : 'bottom',
    'horizontalalignment' : 'center'
  }
 
See the text docstring for information of how override and the
optional args work
xlabel(s, *args, **kwargs)
Set the x axis label of the current axis to s
 
Default override is
 
  override = {
      'fontsize'            : 'small',
      'verticalalignment'   : 'top',
      'horizontalalignment' : 'center'
      }
 
See the text docstring for information of how override and
the optional args work
xlim(*args, **kwargs)
Set/Get the xlimits of the current axes
 
xmin, xmax = xlim()   : return the current xlim
xlim( (xmin, xmax) )  : set the xlim to xmin, xmax
xlim( xmin, xmax )    : set the xlim to xmin, xmax
xticks(*args, **kwargs)
Set/Get the xlimits of the current ticklocs, labels
 
# return locs, labels where locs is an array of tick locations and
# labels is an array of tick labels.
locs, labels = xticks()              
 
# set the locations of the xticks
xticksarange(6) )
 
# set the locations and labels of the xticks
xticksarange(5), ('Tom', 'Dick', 'Harry', 'Sally', 'Sue') )
 
The keyword args, if any, are text properties; see text for more
information on text properties.
ylabel(s, *args, **kwargs)
Set the y axis label of the current axis to s
 
Defaults override is
 
    override = {
       'fontsize'            : 'small',
       'verticalalignment'   : 'center',
       'horizontalalignment' : 'right',
       'rotation'='vertical' : }
 
See the text docstring for information of how override and the
optional args work
ylim(*args, **kwargs)
Set/Get the ylimits of the current axes
 
ymin, ymax = ylim()   : return the current ylim
ylim( (ymin, ymax) )  : set the ylim to ymin, ymax
ylim( ymin, ymax )    : set the ylim to ymin, ymax
yticks(*args, **kwargs)
Set/Get the ylimits of the current ticklocs, labels
 
# return locs, labels where locs is an array of tick locations and
# labels is an array of tick labels.
locs, labels = yticks()              
 
# set the locations of the yticks
yticksarange(6) )
 
# set the locations and labels of the yticks
yticksarange(5), ('Tom', 'Dick', 'Harry', 'Sally', 'Sue') )
 
The keyword args, if any, are text properties; see text for more
information on text properties.
zeros(...)
zeros((d1,...,dn),typecode='l',savespace=0) will return a new array of shape (d1,...,dn) and type typecode with all it's entries initialized to zero.  If savespace is nonzero the array will be a spacesaver array.

 
Data
        Character = 'c'
Complex = 'D'
Complex0 = 'F'
Complex16 = 'F'
Complex32 = 'F'
Complex64 = 'D'
Complex8 = 'F'
DAILY = 3
FR = FR
FRIDAY = FR
False = False
Float = 'd'
Float0 = 'f'
Float16 = 'f'
Float32 = 'f'
Float64 = 'd'
Float8 = 'f'
HOURLY = 4
HOURS_PER_DAY = 24.0
Infinity = inf
Int = 'l'
Int0 = '1'
Int16 = 's'
Int32 = 'i'
Int8 = '1'
LittleEndian = True
MINUTELY = 5
MINUTES_PER_DAY = 1440.0
MO = MO
MONDAY = MO
MONTHLY = 1
MUSECONDS_PER_DAY = 86400000000.0
NewAxis = None
PyObject = 'O'
SA = SA
SATURDAY = SA
SECONDLY = 6
SECONDS_PER_DAY = 86400.0
SEC_PER_DAY = 86400
SEC_PER_HOUR = 3600
SEC_PER_MIN = 60
SEC_PER_WEEK = 604800
SU = SU
SUNDAY = SU
TH = TH
THURSDAY = TH
TU = TU
TUESDAY = TU
True = True
UInt = 'u'
UInt16 = 'w'
UInt32 = 'u'
UInt8 = 'b'
UnsignedInt16 = 'w'
UnsignedInt32 = 'u'
UnsignedInt8 = 'b'
UnsignedInteger = 'u'
WE = WE
WEDNESDAY = WE
WEEKDAYS = (MO, TU, WE, TH, FR, SA, SU)
WEEKLY = 2
YEARLY = 0
absolute = <ufunc 'absolute'>
add = <ufunc 'add'>
arccos = <ufunc 'arccos'>
arccosh = <ufunc 'arccosh'>
arcsin = <ufunc 'arcsin'>
arcsinh = <ufunc 'arcsinh'>
arctan = <ufunc 'arctan'>
arctan2 = <ufunc 'arctan2'>
arctanh = <ufunc 'arctanh'>
bitwise_and = <ufunc 'bitwise_and'>
bitwise_or = <ufunc 'bitwise_or'>
bitwise_xor = <ufunc 'bitwise_xor'>
ceil = <ufunc 'ceil'>
conjugate = <ufunc 'conjugate'>
cos = <ufunc 'cos'>
cosh = <ufunc 'cosh'>
divide = <ufunc 'divide'>
divide_safe = <ufunc 'divide_safe'>
division = _Feature((2, 2, 0, 'alpha', 2), (3, 0, 0, 'alpha', 0), 8192)
e = 2.7182818284590451
equal = <ufunc 'equal'>
exp = <ufunc 'exp'>
exp_safe_MAX = 1.7976931348623157e+308
exp_safe_MIN = -708.39641853226408
fabs = <ufunc 'fabs'>
floor = <ufunc 'floor'>
floor_divide = <ufunc 'floor_divide'>
fmod = <ufunc 'fmod'>
greater = <ufunc 'greater'>
greater_equal = <ufunc 'greater_equal'>
hypot = <ufunc 'hypot'>
inf = inf
infty = inf
invert = <ufunc 'invert'>
left_shift = <ufunc 'left_shift'>
less = <ufunc 'less'>
less_equal = <ufunc 'less_equal'>
log = <ufunc 'log'>
log10 = <ufunc 'log10'>
logical_and = <ufunc 'logical_and'>
logical_not = <ufunc 'logical_not'>
logical_or = <ufunc 'logical_or'>
logical_xor = <ufunc 'logical_xor'>
maximum = <ufunc 'maximum'>
minimum = <ufunc 'minimum'>
multiply = <ufunc 'multiply'>
name = 'vlines'
negative = <ufunc 'negative'>
not_equal = <ufunc 'not_equal'>
nx = <matplotlib.nc_imports._TypeNamespace instance>
pi = 3.1415926535897931
power = <ufunc 'power'>
rcParams = {'axes.edgecolor': 'k', 'axes.facecolor': 'w', 'axes.grid': False, 'axes.hold': True, 'axes.labelcolor': 'k', 'axes.labelsize': 12.0, 'axes.linewidth': 1.0, 'axes.titlesize': 14.0, 'backend': 'GTKAgg', 'datapath': '/usr/local/share/matplotlib', ...}
rcParamsDefault = {'axes.edgecolor': 'k', 'axes.facecolor': 'w', 'axes.grid': False, 'axes.hold': True, 'axes.labelcolor': 'k', 'axes.labelsize': 12.0, 'axes.linewidth': 1.0, 'axes.titlesize': 14.0, 'backend': 'GTKAgg', 'datapath': '/usr/local/share/matplotlib', ...}
readme = '\nMLab2.py, release 1\n\nCreated on February 2003 b...\nLook at: http://pdilib.sf.net for new releases.\n'
remainder = <ufunc 'remainder'>
right_shift = <ufunc 'right_shift'>
sin = <ufunc 'sin'>
sinh = <ufunc 'sinh'>
sqrt = <ufunc 'sqrt'>
subtract = <ufunc 'subtract'>
tan = <ufunc 'tan'>
tanh = <ufunc 'tanh'>
true_divide = <ufunc 'true_divide'>
typecodes = {'Character': 'c', 'Complex': 'FD', 'Float': 'fd', 'Integer': '1sil', 'UnsignedInteger': 'bwu'}
verbose = <matplotlib.Verbose instance>
version = 'Numeric 23.1'
which = ('numeric', 'rc')
@footer@