|
From: <jd...@us...> - 2008-12-10 15:02:17
|
Revision: 6548
http://matplotlib.svn.sourceforge.net/matplotlib/?rev=6548&view=rev
Author: jdh2358
Date: 2008-12-10 15:02:14 +0000 (Wed, 10 Dec 2008)
Log Message:
-----------
updated plot docstring
Modified Paths:
--------------
trunk/matplotlib/lib/matplotlib/axes.py
Modified: trunk/matplotlib/lib/matplotlib/axes.py
===================================================================
--- trunk/matplotlib/lib/matplotlib/axes.py 2008-12-10 14:55:05 UTC (rev 6547)
+++ trunk/matplotlib/lib/matplotlib/axes.py 2008-12-10 15:02:14 UTC (rev 6548)
@@ -3171,46 +3171,55 @@
Return value is a list of lines that were added.
- The following line styles are supported::
+ The following format string characters are accepted to control
+ the line style or marker
- - # solid line
- -- # dashed line
- -. # dash-dot line
- : # dotted line
- . # points
- , # pixels
- o # circle symbols
- ^ # triangle up symbols
- v # triangle down symbols
- < # triangle left symbols
- > # triangle right symbols
- s # square symbols
- + # plus symbols
- * # star symbols
- x # cross symbols
- D # diamond symbols
- d # thin diamond symbols
- 1 # tripod down symbols
- 2 # tripod up symbols
- 3 # tripod left symbols
- 4 # tripod right symbols
- h # hexagon symbols
- H # rotated hexagon symbols
- p # pentagon symbols
- | # vertical line symbols
- _ # horizontal line symbols
- steps # use gnuplot style 'steps' # kwarg only
+ ================ ===============================
+ character description
+ ================ ===============================
+ '-' solid line style
+ '--' dashed line style
+ '-.' dash-dot line style
+ ':' dotted line style
+ '.' point marker
+ ',' pixel marker
+ 'o' circle marker
+ 'v' triangle_down marker
+ '^' triangle_up marker
+ '<' triangle_left marker
+ '>' triangle_right marker
+ '1' tri_down marker
+ '2' tri_up marker
+ '3' tri_left marker
+ '4' tri_right marker
+ 's' square marker
+ 'p' pentagon marker
+ '*' star marker
+ 'h' hexagon1 marker
+ 'H' hexagon2 marker
+ '+' plus marker
+ 'x' x marker
+ 'D' diamond marker
+ 'd' thin_diamond marker
+ '|' vline marker
+ '_' hline marker
+ ================ ===============================
+
The following color abbreviations are supported::
- b # blue
- g # green
- r # red
- c # cyan
- m # magenta
- y # yellow
- k # black
- w # white
+ ========== ========
+ character color
+ ========== ========
+ 'b' blue
+ 'g' green
+ 'r' red
+ 'c' cyan
+ 'm' magenta
+ 'y' yellow
+ 'k' black
+ 'w' white
+ ========== ========
In addition, you can specify colors in many weird and
wonderful ways, including full names (``'green'``), hex
@@ -3239,6 +3248,15 @@
Neither line will be antialiased.
+ You do not need to use format strings, which are just
+ abbreviations. All of the line properties can be controlled
+ by keyword arguments. For example, you can set the color,
+ marker, linestyle, and markercolor with::
+
+ plot(x, y, color='green', linestyle='dashed', marker='o',
+ markerfacecolor='blue', markersize=12). See
+ :class:`~matplotlib.lines.Line2D` for details.
+
The kwargs are :class:`~matplotlib.lines.Line2D` properties:
%(Line2D)s
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|