1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216
|
<html>
<head>
<title>Class: GridData</title>
</head>
<body bgcolor="#ffffff">
<p><i><a href="index.html">Table of Contents</a></i></p>
<table border="0" cellpadding="5" cellspacing="0" width="100%">
<tr bgcolor="#88bbee">
<th rowspan="2"
valign="top"
align="left"
width="10%"><font color="#000000">Class: GridData</font>
</th>
<th align="right"><font color="#000000">./PlotItems.py</font></th>
</tr>
<tr>
<td>
<dl><dt><p><strong>Holds data representing a function of two variables, for use in splot.</strong><p>
</dt><dd><p> <code>GridData</code> represents a function that has been tabulated on a
rectangular grid. The data are written to a file; no copy is kept
in memory.</p>
</dd></dl>
<table border="0" cellpadding="5" cellspacing="0" width="100%%">
<tr>
<th bgcolor="#99ccff"
rowspan="2"
valign="top"
align="left"
width="20%"
>
<font color="#000000">
<a name="Base Classes">Base Classes</a>
</font>
</th>
<th bgcolor="#99ccff"
valign="top"
align="left"
>
<font color="#000000"> </font>
</th>
</tr>
<tr>
<td>
<a href="PlotItems.py_PlotItem.html">PlotItem</a><br>
</td>
</tr>
</table>
<table border="0" cellpadding="5" cellspacing="0" width="100%%">
<tr>
<th bgcolor="#99ccff"
rowspan="2"
valign="top"
align="left"
width="20%"
>
<font color="#000000">
<a name="Methods">Methods</a>
</font>
</th>
<th bgcolor="#99ccff"
valign="top"
align="left"
>
<font color="#000000"> </font>
</th>
</tr>
<tr>
<td>
<a href="#__init__">__init__</a><br>
<a href="#pipein">pipein</a><br>
<tr>
<th bgcolor="#99ccff"
rowspan="2"
valign="top"
align="left"
width="20%"
>
<font color="#000000">
<a name="__init__"></a>
</font>
</th>
<th bgcolor="#99ccff"
valign="top"
align="left"
>
<font color="#000000">__init__ </font>
</th>
</tr>
<tr>
<td>
<pre>
__init__ (
self,
data,
xvals=None,
yvals=None,
binary=1,
inline=_unset,
**keyw,
)
</pre><dl><dt><p><strong>GridData constructor.</strong><p>
</dt><dd><p> Arguments:</p>
<dl><dt> <code>data</code></dt><dd><p>the data to plot: a 2-d array with dimensions
(numx,numy).</p>
</dd>
<dt> <code>xvals</code></dt><dd><p>a 1-d array with dimension <code>numx</code></p>
</dd>
<dt> <code>yvals</code></dt><dd><p>a 1-d array with dimension <code>numy</code></p>
</dd>
<dt> <code>binary=<bool></code></dt><dd><p>send data to gnuplot in binary format?</p>
</dd>
<dt> <code>inline=<bool></code></dt><dd><p>send data to gnuplot "inline"?</p>
</dd></dl>
<p> Note the unusual argument order! The data are specified
<em>before</em> the x and y values. (This inconsistency was probably
a mistake; after all, the default xvals and yvals are not very
useful.)</p>
<p> <code>data</code> must be a data array holding the values of a function
f(x,y) tabulated on a grid of points, such that <code>data[i,j] ==
f(xvals[i], yvals[j])</code>. If <code>xvals</code> and/or <code>yvals</code> are
omitted, integers (starting with 0) are used for that
coordinate. The data are written to a temporary file; no copy
of the data is kept in memory.</p>
<p> If <code>binary=0</code> then the data are written to a datafile as <code>x y
f(x,y)</code> triplets (y changes most rapidly) that can be used by
gnuplot's <code>splot</code> command. Blank lines are included each time
the value of x changes so that gnuplot knows to plot a surface
through the data.</p>
<p> If <code>binary=1</code> then the data are written to a file in a binary
format that <code>splot</code> can understand. Binary format is faster
and usually saves disk space but is not human-readable. If
your version of gnuplot doesn't support binary format (it is a
recently-added feature), this behavior can be disabled by
setting the configuration variable
<code>gp.GnuplotOpts.recognizes_binary_splot=0</code> in the appropriate
gp*.py file.</p>
<p> Thus if you have three arrays in the above format and a
Gnuplot instance called g, you can plot your data by typing
<code>g.splot(Gnuplot.GridData(data,xvals,yvals))</code>.</p>
</dd></dl>
<tr>
<th bgcolor="#99ccff"
rowspan="2"
valign="top"
align="left"
width="20%"
>
<font color="#000000">
<a name="pipein"></a>
</font>
</th>
<th bgcolor="#99ccff"
valign="top"
align="left"
>
<font color="#000000">pipein </font>
</th>
</tr>
<tr>
<td>
<pre>
pipein ( self, f )
</pre><p>
<TABLE BORDER=1 CELLPADDING=2>
</TABLE></p>
</td></tr>
</td>
</tr>
</table>
</td>
</tr>
</table>
<hr>
<p><i><a href="index.html">Table of Contents</a></i></p>
<i>This document was automatically generated on Fri Jan 26 13:13:18 2001
by <a href="http://happydoc.sourceforge.net">HappyDoc</a> version r0_9_2</i>
</body>
</html>
|