You can subscribe to this list here.
2004 
_{Jan}

_{Feb}

_{Mar}

_{Apr}

_{May}

_{Jun}

_{Jul}
(13) 
_{Aug}
(65) 
_{Sep}
(8) 
_{Oct}
(102) 
_{Nov}
(22) 
_{Dec}
(23) 

2005 
_{Jan}
(45) 
_{Feb}
(73) 
_{Mar}
(49) 
_{Apr}
(23) 
_{May}
(1) 
_{Jun}
(64) 
_{Jul}
(178) 
_{Aug}
(78) 
_{Sep}
(155) 
_{Oct}
(16) 
_{Nov}
(3) 
_{Dec}
(5) 
2006 
_{Jan}
(3) 
_{Feb}
(48) 
_{Mar}
(10) 
_{Apr}
(48) 
_{May}
(178) 
_{Jun}
(19) 
_{Jul}
(11) 
_{Aug}
(5) 
_{Sep}
(5) 
_{Oct}

_{Nov}
(1) 
_{Dec}

2007 
_{Jan}
(1) 
_{Feb}
(3) 
_{Mar}
(2) 
_{Apr}
(7) 
_{May}

_{Jun}

_{Jul}
(10) 
_{Aug}
(3) 
_{Sep}
(4) 
_{Oct}
(67) 
_{Nov}
(4) 
_{Dec}
(1) 
2008 
_{Jan}
(2) 
_{Feb}
(2) 
_{Mar}
(19) 
_{Apr}
(3) 
_{May}
(12) 
_{Jun}
(2) 
_{Jul}

_{Aug}

_{Sep}
(2) 
_{Oct}

_{Nov}
(3) 
_{Dec}

2009 
_{Jan}

_{Feb}

_{Mar}
(2) 
_{Apr}

_{May}
(1) 
_{Jun}
(1) 
_{Jul}
(1) 
_{Aug}

_{Sep}

_{Oct}
(1) 
_{Nov}

_{Dec}
(6) 
2010 
_{Jan}
(3) 
_{Feb}

_{Mar}

_{Apr}

_{May}

_{Jun}
(10) 
_{Jul}
(5) 
_{Aug}

_{Sep}

_{Oct}

_{Nov}

_{Dec}
(3) 
2011 
_{Jan}

_{Feb}

_{Mar}

_{Apr}
(14) 
_{May}
(112) 
_{Jun}
(11) 
_{Jul}
(48) 
_{Aug}

_{Sep}
(2) 
_{Oct}
(11) 
_{Nov}

_{Dec}
(5) 
2012 
_{Jan}

_{Feb}
(9) 
_{Mar}
(1) 
_{Apr}

_{May}
(2) 
_{Jun}

_{Jul}

_{Aug}

_{Sep}

_{Oct}
(82) 
_{Nov}
(1) 
_{Dec}
(5) 
2013 
_{Jan}
(3) 
_{Feb}

_{Mar}

_{Apr}
(1) 
_{May}
(6) 
_{Jun}

_{Jul}
(109) 
_{Aug}
(34) 
_{Sep}
(21) 
_{Oct}
(45) 
_{Nov}

_{Dec}
(34) 
2014 
_{Jan}

_{Feb}
(2) 
_{Mar}
(5) 
_{Apr}

_{May}

_{Jun}

_{Jul}

_{Aug}
(2) 
_{Sep}
(1) 
_{Oct}

_{Nov}
(3) 
_{Dec}

2015 
_{Jan}

_{Feb}
(1) 
_{Mar}
(1) 
_{Apr}
(45) 
_{May}
(2) 
_{Jun}
(2) 
_{Jul}

_{Aug}

_{Sep}

_{Oct}
(2) 
_{Nov}
(10) 
_{Dec}

S  M  T  W  T  F  S 


1

2

3

4

5
(2) 
6

7

8

9

10
(6) 
11
(7) 
12
(1) 
13
(2) 
14
(1) 
15
(5) 
16
(3) 
17
(30) 
18
(28) 
19
(15) 
20
(6) 
21
(14) 
22
(35) 
23
(9) 
24
(12) 
25
(1) 
26

27

28

29
(1) 
30

31




From: <joergl@us...>  20060521 19:27:34

Revision: 2758 Author: joergl Date: 20060521 12:27:29 0700 (Sun, 21 May 2006) ViewCVS: http://svn.sourceforge.net/pyx/?rev=2758&view=rev Log Message:  mention one deformer in feature list Modified Paths:  trunk/pyx/www/index.pt Modified: trunk/pyx/www/index.pt ===================================================================  trunk/pyx/www/index.pt 20060521 19:26:03 UTC (rev 2757) +++ trunk/pyx/www/index.pt 20060521 19:27:29 UTC (rev 2758) @@ 26,7 +26,7 @@ <li>PostScript and PDF output for device independent, free scalable figures</li> <li>seamless TeX/LaTeX integration</li> <li>full access to PostScript features like paths, linestyles, fill patterns, transformations, clipping, bitmap inclusion, etc.</li>  <li>advanced geometric operations on paths like intersections, transformations, splitting, etc.</li> + <li>advanced geometric operations on paths like intersections, affine transformations, splitting, smoothing, etc.</li> <li>sophisticated graph generation: modular design, pluggable axes, axes partitioning based on rational number arithmetics, flexible graph styles, etc.</li> </ul> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. 
From: <joergl@us...>  20060521 19:26:11

Revision: 2757 Author: joergl Date: 20060521 12:26:03 0700 (Sun, 21 May 2006) ViewCVS: http://svn.sourceforge.net/pyx/?rev=2757&view=rev Log Message:  mention new examples Modified Paths:  trunk/pyx/www/news.pt Modified: trunk/pyx/www/news.pt ===================================================================  trunk/pyx/www/news.pt 20060521 19:23:01 UTC (rev 2756) +++ trunk/pyx/www/news.pt 20060521 19:26:03 UTC (rev 2757) @@ 12,9 +12,10 @@ <dt>200605xx: PyX 0.9 released</dt> <dd> This release features a new set of deformers for path manipulations like smoothing, shifting,  etc. Type 1 fontstripping is now handled by a newly written Python module.  The evaluating of functions for graph plotting is now left to Python. Transparency is  now supported for PDF output. Many more small improvements and bug fixes top + etc. A new set of extensively documented examples describing various aspects of PyX in a + cookbooklike fashion have been written. Type 1 fontstripping is now handled by a newly + written Python module. The evaluating of functions for graph plotting is now left to Python. + Transparency is now supported for PDF output. Many more small improvements and bug fixes top off this release. </dd> <dt>20060120: New PyX tutorial for Gnuplot users</dt> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. 
From: <joergl@us...>  20060521 19:23:08

Revision: 2756 Author: joergl Date: 20060521 12:23:01 0700 (Sun, 21 May 2006) ViewCVS: http://svn.sourceforge.net/pyx/?rev=2756&view=rev Log Message:  move item to next release (Andre, correct me, if this has been implemented in PyX 0.9 Modified Paths:  trunk/pyx/www/roadmap.pt Modified: trunk/pyx/www/roadmap.pt ===================================================================  trunk/pyx/www/roadmap.pt 20060521 19:21:25 UTC (rev 2755) +++ trunk/pyx/www/roadmap.pt 20060521 19:23:01 UTC (rev 2756) @@ 26,7 +26,7 @@ <tr><td colspan=3 class="tablehead">text</td></tr> <tr><td>text in arbitrarily shaped boxes and float text from box to box</td><td>experimental code</td><td>low priority</td></tr> <tr><td colspan=3 class="tablehead">graph system</td></tr>  <tr><td>time axes</td><td>experimental code</td><td>planned for 0.9</td></tr> + <tr><td>time axes</td><td>experimental code</td><td>planned for 0.10</td></tr> <tr><td>3d graph geometry and surface style</td><td>very old experimental code</td><td>planned for one of the next releases</td></tr> <tr><td>polar graph geometry</td><td>not started</td><td>planned for one of the next releases</td></tr> <tr><td colspan=3 class="tablehead">backend</td></tr> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. 
From: <joergl@us...>  20060521 19:21:32

Revision: 2755 Author: joergl Date: 20060521 12:21:25 0700 (Sun, 21 May 2006) ViewCVS: http://svn.sourceforge.net/pyx/?rev=2755&view=rev Log Message:  add first proposal for release notes Modified Paths:  trunk/pyx/www/news.pt Modified: trunk/pyx/www/news.pt ===================================================================  trunk/pyx/www/news.pt 20060521 19:09:09 UTC (rev 2754) +++ trunk/pyx/www/news.pt 20060521 19:21:25 UTC (rev 2755) @@ 9,6 +9,14 @@ <h1>PyX  News</h1> <dl> + <dt>200605xx: PyX 0.9 released</dt> + <dd> + This release features a new set of deformers for path manipulations like smoothing, shifting, + etc. Type 1 fontstripping is now handled by a newly written Python module. + The evaluating of functions for graph plotting is now left to Python. Transparency is + now supported for PDF output. Many more small improvements and bug fixes top + off this release. + </dd> <dt>20060120: New PyX tutorial for Gnuplot users</dt> <dd> Titus Winters wrote a very nice <a href="http://www.cs.ucr.edu/~titus/pyxTutorial/">tutorial</a>; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. 
From: <joergl@us...>  20060521 19:09:16

Revision: 2754 Author: joergl Date: 20060521 12:09:09 0700 (Sun, 21 May 2006) ViewCVS: http://svn.sourceforge.net/pyx/?rev=2754&view=rev Log Message:  some updates to titles Modified Paths:  trunk/pyx/examples/graphs/function.txt trunk/pyx/examples/graphs/lissajous.txt Modified: trunk/pyx/examples/graphs/function.txt ===================================================================  trunk/pyx/examples/graphs/function.txt 20060521 19:03:12 UTC (rev 2753) +++ trunk/pyx/examples/graphs/function.txt 20060521 19:09:09 UTC (rev 2754) @@ 1,4 +1,4 @@ Plotting a mathematical function +Plotting a function graph Here, we explain how to plot the graph of a realvalued mathematical function of a single real parameter. ... Modified: trunk/pyx/examples/graphs/lissajous.txt ===================================================================  trunk/pyx/examples/graphs/lissajous.txt 20060521 19:03:12 UTC (rev 2753) +++ trunk/pyx/examples/graphs/lissajous.txt 20060521 19:09:09 UTC (rev 2754) @@ 1,4 +1,4 @@ Parametric function +Plotting a parametric function This example shows how to use a `paramfunction` as a data source for a graph. `paramfunction` defines a parameter variable name given as a string in the first This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. 
From: <joergl@us...>  20060521 19:03:20

Revision: 2753 Author: joergl Date: 20060521 12:03:12 0700 (Sun, 21 May 2006) ViewCVS: http://svn.sourceforge.net/pyx/?rev=2753&view=rev Log Message:  describe plotting of more than one data set and graph key Added Paths:  trunk/pyx/examples/graphs/change.txt Added: trunk/pyx/examples/graphs/change.txt ===================================================================  trunk/pyx/examples/graphs/change.txt (rev 0) +++ trunk/pyx/examples/graphs/change.txt 20060521 19:03:12 UTC (rev 2753) @@ 0,0 +1,36 @@ +Plotting more than one data set and adding a graph key + +In this example we demonstrate how to plot more than one data set in a graph. +Furthermore, adding a graph key labelling the data is explained. ... + +In order to display more than one data set, we pass a list of data sets to the +`plot` method of the graph. In the present case, we contruct this list out of +three lists of `graph.data.function` instances. For each data set we also +set a title using the corresponding keyword argument of the data class. + +For a more colorful output, we pass the `color.palette.Rainbow` color palette +to the `graph.style.line` class. PyX then automatically chooses color spanning +the whole range of the rainbow palette. + +! If you look at the output, you will notice that not only the colors are +cycled through, but also the line style changes. The reason for this behavior +is that the default line attributes of the `graph.style.line` style contain an +`attr.changelist` comprising a couple of different line styles. When you pass +additional line attributes, these are appended to the default attributes (this +is generally the case in PyX). Consequently, you get a change of both the +color and the line style. If you only want to change the color, either +pass the desired line style explicitly, i.e., use + graph.style.line([style.linestyle.solid, color.palette.Rainbow]) +or clear a previous setting of the line style using the `clear` attribute +of the corresponding class: + graph.style.line([style.linestyle.clear, color.palette.Rainbow]) + +Finally, when plotting more than one data set you might want to label them in +your graph. We already have passed titles identifying each data set, so we only +have to add a graph key. This is done by passing a `graph.key.key` instance as +the `key` keyword argument to the graph. Usually, you only need to specify the +position of the key using the `pos` argument of the `graph.key.key` +constructor. The syntax should be selfexplaining; here we use `br` to put +the key at the bottomright position of the graph. In order to save some +space, we furthermore decreases the distance between the key entries a little +bit by passing a value of 0.1 to the `dist` argument. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. 
From: <joergl@us...>  20060521 19:03:05

Revision: 2752 Author: joergl Date: 20060521 12:02:55 0700 (Sun, 21 May 2006) ViewCVS: http://svn.sourceforge.net/pyx/?rev=2752&view=rev Log Message:  describe plotting of more than one data set and graph key Modified Paths:  trunk/pyx/examples/graphs/INDEX trunk/pyx/examples/graphs/change.py Modified: trunk/pyx/examples/graphs/INDEX ===================================================================  trunk/pyx/examples/graphs/INDEX 20060521 18:27:14 UTC (rev 2751) +++ trunk/pyx/examples/graphs/INDEX 20060521 19:02:55 UTC (rev 2752) @@ 4,9 +4,9 @@ histogram axis errorbar +change piaxis manyaxes inset link change arrows Modified: trunk/pyx/examples/graphs/change.py ===================================================================  trunk/pyx/examples/graphs/change.py 20060521 18:27:14 UTC (rev 2751) +++ trunk/pyx/examples/graphs/change.py 20060521 19:02:55 UTC (rev 2752) @@ 1,10 +1,14 @@ from pyx import * g = graph.graphxy(width=10, +g = graph.graphxy(width=8, x=graph.axis.linear(min=0, max=2),  y=graph.axis.linear(min=0, max=2)) g.plot([graph.data.function("x(y)=y**(2**(3%i))" % i) for i in range(3)] +  [graph.data.function("y(x)=x**(2**%i)" % i) for i in range(4)], + y=graph.axis.linear(min=0, max=2), + key=graph.key.key(pos="br", dist=0.1)) +g.plot([graph.data.function("x(y)=y**(2**%i)" % i, title=r"$x = y^{%g}$" % (2**i)) + for i in range(2, 0, 1)] + + [graph.data.function("x(y)=y", title=r"$x = y$")] + + [graph.data.function("y(x)=x**(2**%i)" % i, title=r"$y = x^{%g}$" % (2**i)) + for i in range(1, 3)], [graph.style.line([color.palette.Rainbow])]) g.writeEPSfile("change") g.writePDFfile("change") This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. 
From: <mschindler@us...>  20060521 18:27:22

Revision: 2751 Author: mschindler Date: 20060521 11:27:14 0700 (Sun, 21 May 2006) ViewCVS: http://svn.sourceforge.net/pyx/?rev=2751&view=rev Log Message:  allow empty paramlist in normath._split_pt  and some consequence in connector Modified Paths:  trunk/pyx/pyx/connector.py trunk/pyx/pyx/normpath.py Modified: trunk/pyx/pyx/connector.py ===================================================================  trunk/pyx/pyx/connector.py 20060521 18:11:29 UTC (rev 2750) +++ trunk/pyx/pyx/connector.py 20060521 18:27:14 UTC (rev 2751) @@ 76,7 +76,8 @@ pass else: sp = self.intersect(cutpath)[0]  self.normsubpaths = self.split(sp[:1])[0].normsubpaths + if sp: + self.normsubpaths = self.split(sp[:1])[0].normsubpaths ################ @@ 92,7 +93,8 @@ self.box2 = box2 connector_pt.__init__(self,  [path.normsubpath([path.normline_pt(*(self.box1.center+self.box2.center))], closed=0)]) + [path.normsubpath([path.normline_pt(self.box1.center[0], self.box1.center[1], + self.box2.center[0], self.box2.center[1])], closed=0)]) self.omitends(box1, box2) self.shortenpath(boxdists) @@ 332,7 +334,7 @@ """a line is the straight connector between the centers of two boxes"""  def __init__(self, box1, box2, boxdists=[0,0]): + def __init__(self, box1, box2, boxdists=(0,0)): line_pt.__init__(self, box1, box2, boxdists=map(unit.topt, boxdists)) Modified: trunk/pyx/pyx/normpath.py ===================================================================  trunk/pyx/pyx/normpath.py 20060521 18:11:29 UTC (rev 2750) +++ trunk/pyx/pyx/normpath.py 20060521 18:27:14 UTC (rev 2751) @@ 1806,6 +1806,8 @@ def _split_pt(self, params): """split path at params and return list of normpaths""" + if not params: + return [] # instead of distributing the parameters, we need to keep their # order and collect parameters for splitting of normsubpathitem This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. 
From: <joergl@us...>  20060521 18:11:34

Revision: 2750 Author: joergl Date: 20060521 11:11:29 0700 (Sun, 21 May 2006) ViewCVS: http://svn.sourceforge.net/pyx/?rev=2750&view=rev Log Message:  test case for bug #1492548 Modified Paths:  trunk/pyx/examples/graphs/histogram.py Modified: trunk/pyx/examples/graphs/histogram.py ===================================================================  trunk/pyx/examples/graphs/histogram.py 20060521 16:24:30 UTC (rev 2749) +++ trunk/pyx/examples/graphs/histogram.py 20060521 18:11:29 UTC (rev 2750) @@ 1,7 +1,7 @@ from pyx import * d = graph.data.list([(1, 0.3),  (2, 0.5), + (2, .7), (3, 0.3), (4, 0.8), (5, 0.5)], x=1, y=2) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. 
From: <joergl@us...>  20060521 16:24:38

Revision: 2749 Author: joergl Date: 20060521 09:24:30 0700 (Sun, 21 May 2006) ViewCVS: http://svn.sourceforge.net/pyx/?rev=2749&view=rev Log Message:  some fixes and enhancements Modified Paths:  trunk/pyx/examples/graphs/README Modified: trunk/pyx/examples/graphs/README ===================================================================  trunk/pyx/examples/graphs/README 20060521 16:20:45 UTC (rev 2748) +++ trunk/pyx/examples/graphs/README 20060521 16:24:30 UTC (rev 2749) @@ 1,13 +1,14 @@ Basic plotting One of PyX major strengths are its graph plotting capabilities. PyX offers you a flexible system which, while providing sensible defaults, allows you to +One of PyX's major strengths are its graphplotting capabilities. PyX offers +you a flexible system which, while providing sensible defaults, allows you to customize almost every aspect of the graph output. Such a flexibility comes at a price, though: you need to learn at least a little bit about the different components playing together in order to produce a graph. In this section, we try to give you a gentle introduction to one component after the other. We start by demonstrating how to plot various kind of data (from a file, a function mapping x values to y values, a parametric function, a histogram). Along the way, we introduce more and more concepts which you need to understand in order to be able to make use of the full power of PyX's graphplotting system. +Subsequently, we explain how to modify various properties of the axes of the +graph. Along the way, we introduce more and more concepts which you need to +understand in order to be able to make use of the full power of PyX's +graphplotting system. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. 
From: <joergl@us...>  20060521 16:21:04

Revision: 2748 Author: joergl Date: 20060521 09:20:45 0700 (Sun, 21 May 2006) ViewCVS: http://svn.sourceforge.net/pyx/?rev=2748&view=rev Log Message:  add a gentle introduction to axes (Andre, please have a look at the XXX part) Modified Paths:  trunk/pyx/examples/graphs/INDEX Added Paths:  trunk/pyx/examples/graphs/axis.py trunk/pyx/examples/graphs/axis.txt Modified: trunk/pyx/examples/graphs/INDEX ===================================================================  trunk/pyx/examples/graphs/INDEX 20060521 15:26:42 UTC (rev 2747) +++ trunk/pyx/examples/graphs/INDEX 20060521 16:20:45 UTC (rev 2748) @@ 2,6 +2,7 @@ function lissajous histogram +axis errorbar piaxis manyaxes Added: trunk/pyx/examples/graphs/axis.py ===================================================================  trunk/pyx/examples/graphs/axis.py (rev 0) +++ trunk/pyx/examples/graphs/axis.py 20060521 16:20:45 UTC (rev 2748) @@ 0,0 +1,8 @@ +from pyx import * + +g = graph.graphxy(width=8, + x=graph.axis.log(min=1e1, max=1e4), + y=graph.axis.lin(min=5, max=5)) +g.plot(graph.data.function("y(x)=tan(log(1/x))")) +g.writeEPSfile("axis") +g.writePDFfile("axis") Added: trunk/pyx/examples/graphs/axis.txt ===================================================================  trunk/pyx/examples/graphs/axis.txt (rev 0) +++ trunk/pyx/examples/graphs/axis.txt 20060521 16:20:45 UTC (rev 2748) @@ 0,0 +1,27 @@ +Using a logarithmic axis and defining the axis range + +Sometimes, you have to visualize rather pathological funtions containing +divergencies and/or varying over a large parameter range. This is best done +using an appropriate axis. Here, we show a simple example how to do +this with PyX. ... + +In order to change the properties of the graph axes, we have to create +appropriate instances of an axis class and pass them as keyword arguments to +the `graph.graphxy` constructor. A number of predefined axes is contained in +the `graph.axis` module. Here, we use a linear (abbreviated as +`graph.axis.lin`) and a logarithmic (abbreviated as `graph.axis.log`) axis. In +both cases, we pass a minimal and maximal value for the axis range. Whereas for +the xaxis this is not strictly necessary (we could as well tell the +`graph.data.function` instance to emit data in a certain xrange), it is +important for the yaxis because the function diverges for certain x values. If +we do not set the y range manually, we would obtain a rather compressed display +of the function in the ydirection, which, moreover, would strongly depend on +the sampling points choosen by PyX along the xdirection. + +! Note how PyX changes the way the xaxis is drawn. Instead of simple decimal +numbers, an exponential notation is used. This happens automatically, if the axis +values become too big. + +XXX Andre, please more info: I don't feel being qualified enough + + This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. 
From: <joergl@us...>  20060521 15:26:50

Revision: 2747 Author: joergl Date: 20060521 08:26:42 0700 (Sun, 21 May 2006) ViewCVS: http://svn.sourceforge.net/pyx/?rev=2747&view=rev Log Message:  reorder examples Modified Paths:  trunk/pyx/examples/graphs/INDEX Modified: trunk/pyx/examples/graphs/INDEX ===================================================================  trunk/pyx/examples/graphs/INDEX 20060521 15:25:29 UTC (rev 2746) +++ trunk/pyx/examples/graphs/INDEX 20060521 15:26:42 UTC (rev 2747) @@ 1,8 +1,8 @@ minimal function +lissajous +histogram errorbar histogram lissajous piaxis manyaxes inset This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. 
From: <joergl@us...>  20060521 15:25:36

Revision: 2746 Author: joergl Date: 20060521 08:25:29 0700 (Sun, 21 May 2006) ViewCVS: http://svn.sourceforge.net/pyx/?rev=2746&view=rev Log Message:  add an introduction to the basic plotting section Added Paths:  trunk/pyx/examples/graphs/README Added: trunk/pyx/examples/graphs/README ===================================================================  trunk/pyx/examples/graphs/README (rev 0) +++ trunk/pyx/examples/graphs/README 20060521 15:25:29 UTC (rev 2746) @@ 0,0 +1,13 @@ +Basic plotting + +One of PyX major strengths are its graph plotting capabilities. PyX offers you +a flexible system which, while providing sensible defaults, allows you to +customize almost every aspect of the graph output. Such a flexibility comes at +a price, though: you need to learn at least a little bit about the different +components playing together in order to produce a graph. In this section, we +try to give you a gentle introduction to one component after the other. We +start by demonstrating how to plot various kind of data (from a file, a +function mapping x values to y values, a parametric function, a histogram). +Along the way, we introduce more and more concepts which you need to understand +in order to be able to make use of the full power of PyX's graphplotting +system. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. 
From: <joergl@us...>  20060521 15:16:42

Revision: 2745 Author: joergl Date: 20060521 08:16:32 0700 (Sun, 21 May 2006) ViewCVS: http://svn.sourceforge.net/pyx/?rev=2745&view=rev Log Message:  more graphs example work Modified Paths:  trunk/pyx/examples/graphs/INDEX trunk/pyx/examples/graphs/lissajous.txt trunk/pyx/examples/graphs/minimal.py trunk/pyx/examples/graphs/minimal.txt Added Paths:  trunk/pyx/examples/graphs/function.py trunk/pyx/examples/graphs/function.txt Modified: trunk/pyx/examples/graphs/INDEX ===================================================================  trunk/pyx/examples/graphs/INDEX 20060520 15:46:35 UTC (rev 2744) +++ trunk/pyx/examples/graphs/INDEX 20060521 15:16:32 UTC (rev 2745) @@ 1,4 +1,5 @@ minimal +function errorbar histogram lissajous Added: trunk/pyx/examples/graphs/function.py ===================================================================  trunk/pyx/examples/graphs/function.py (rev 0) +++ trunk/pyx/examples/graphs/function.py 20060521 15:16:32 UTC (rev 2745) @@ 0,0 +1,6 @@ +from pyx import * + +g = graph.graphxy(width=8) +g.plot(graph.data.function("y(x)=sin(x)/x", min=15, max=15)) +g.writeEPSfile("function") +g.writePDFfile("function") Added: trunk/pyx/examples/graphs/function.txt ===================================================================  trunk/pyx/examples/graphs/function.txt (rev 0) +++ trunk/pyx/examples/graphs/function.txt 20060521 15:16:32 UTC (rev 2745) @@ 0,0 +1,32 @@ +Plotting a mathematical function + +Here, we explain how to plot the graph of a realvalued mathematical function of +a single real parameter. ... + +As in the previous example, we first create a `graph.graphxy` instance passing +the width as argument. We then pass a `graph.data.function` instance to the +`plot` method of the graph. As first argument, we pass the function in the form +"y(x) = f(x)". Here, the lefthand side of the equation defines which parameter +is independent (here: `x`) and which one is dependent (here: `y`). We also need +to inform PyX about the range of the independent variable. This is done by passing +the parameters `min` and `max`. + +! In order to increase the resolution of the function graph, you can use the +parameter `points` of the `graph.data.function` class to increase the number of +sampling points from its default value of `100`. + +Note that the default graph style for function data is `graph.style.line` synce +PyX assumes a continuous xrange. + +! You only need to pass the `min` and `max` parameters to the +`graph.data.function` class, if PyX cannot figure out an axis range by itself. +Thus, an alternative way to achieve the above result would look like + g = graph.graphxy(width=8, x=graph.axis.linear(min=15, max=15)) + g.plot(graph.data.function("y(x)=sin(x)/x")) +Here, we explicitely define an xaxis range by passing an appropriate +argument to the `x` parameter of the `graph.graphxy` class. + +! For PyX it does not matter, whether you plot a function of a parameter `x` or +a parameter `y`. Thus, you may as well write + g.plot(graph.data.function("x(y)=sin(y)/y", min=15, max=15)) +to obtain a plot where the ycoordinate is the independent one. Modified: trunk/pyx/examples/graphs/lissajous.txt ===================================================================  trunk/pyx/examples/graphs/lissajous.txt 20060520 15:46:35 UTC (rev 2744) +++ trunk/pyx/examples/graphs/lissajous.txt 20060521 15:16:32 UTC (rev 2745) @@ 5,7 +5,7 @@ argument, a minimal and a maximal value given as the second and third argument and an expression string as forth argument. ... This expression string assigns a tuple of expressions to a tuple of data names. As usual the styles will decide #what those data names are responsible for. +what those data names are responsible for. ! Like for the function, you can also access external data and functions in your expression. Suppose we want to provide the data for this example by means of Modified: trunk/pyx/examples/graphs/minimal.py ===================================================================  trunk/pyx/examples/graphs/minimal.py 20060520 15:46:35 UTC (rev 2744) +++ trunk/pyx/examples/graphs/minimal.py 20060521 15:16:32 UTC (rev 2745) @@ 4,14 +4,3 @@ g.plot(graph.data.file("minimal.dat", x=1, y=2)) g.writeEPSfile("minimal") g.writePDFfile("minimal")  # the file minimal.dat looks like: # 1 2 # 2 3 # 3 8 # 4 13 # 5 18 # 6 21  # graph styles can be modified by a second parameter to the plot method: # g.plot(graph.data.file("minimal.dat", x=1, y=2), [graph.style.line()]) Modified: trunk/pyx/examples/graphs/minimal.txt ===================================================================  trunk/pyx/examples/graphs/minimal.txt 20060520 15:46:35 UTC (rev 2744) +++ trunk/pyx/examples/graphs/minimal.txt 20060521 15:16:32 UTC (rev 2745) @@ 1,6 +1,15 @@ Basic graph drawing: data contained in a file +Plotting data contained in a file This example shows how to draw a graph representing data stored in a file. ... +We assume that the data is arranged in the file `minimal.dat` in a whitespaceseparated +twocolumn form: + # minimal.dat + 1 2 + 2 3 + 3 8 + 4 13 + 5 18 + 6 21 The first step is to create an instance of the `graphxy` class which can be found in the `graph` module. By convention, we call it `g`. The constructor @@ 18,10 +27,33 @@ column of the file contains the x (y) values. The `graph.data.file` instance is then directly passed to the `plot` method of the graph `g`. +! Note that PyX by default ignores comments starting by a # sign when reading +in the data from the file. + +!! The previous statement is actually not completely correct, as PyX +uses the last comment preceding the actual data to give names to the columns. +Thus, for a file looking like + # my data (this line is ignored by PyX, but not the following) + # x y + 1 2 + ... +you wouldn't need to label the columns in the `graph.data.file` call at all. + Finally, we write the graph to an EPS and PDF file. Here, we use that every graph is (by inheritance) an instance of the `canvas` class, as well, such that we can directly write it into a file. ! Of course, you can also insert a graph into another canvas and write this canvas later to a file. This way, you can, for instance, easily arrange more than one graph on a page. +than one graph on a page. Later examples will make use of this fact. + +In PyX, the way data is plotted in a graph is defined by a socalled graph +style. A couple of standard graph styles are contained in the module +`graph.style`. Depending on the data source, PyX chooses a default style. Here, +we are taking the data from a file and PyX assumes that the values represent a +discrete set of data points. Hence, it chooses the symbol style +`graph.style.symbol` to plot the data. To override this default behaviour, you +can pass a list of styles as second argument to the `plot` method. For instance, +to have PyX drawing a line through the data points, you can use + + g.plot(graph.data.file("minimal.dat", x=1, y=2), [graph.style.line()]) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. 