Prev: MayaVi install
Next: How to print without spaces?
From: gerlos on 15 Sep 2009 19:33 John Nagle ha scritto: > I'm looking for something that can draw simple bar and pie charts > in Python. I'm trying to find a Python package, not a wrapper for > some C library, as this has to run on both Windows and Linux > and version clashes are a problem. > Did you look at matplotlib? In their examples page there are some charts like the ones you asked for. I guess it could work for you, and it seems to work flawlessy in MS Windows as in gnu/linux. regards gerlos -- "Solo lo scienziato è vero poeta: ci dà la luna, ci promette le stelle, ci farà un nuovo universo se sarà il caso." < http://gerlos.altervista.org > gerlos +- - - > gnu/linux registred user #311588
From: Alan G Isaac on 15 Sep 2009 22:36 There's John Zelle's graphics.py: http://mcsp.wartburg.edu/zelle/python/ provides basic functionality. Pmw.Blt http://heim.ifi.uio.no/~hpl/Pmw.Blt/doc/reference.html pygooglechart You suggested this needs a browser, but not so, you can download the PNGs and use the default viewer to display them. But really, Matplotlib is both cross platform and great. Alan Isaac
From: John Nagle on 16 Sep 2009 00:23 gerlos wrote: > John Nagle ha scritto: > >> I'm looking for something that can draw simple bar and pie charts >> in Python. I'm trying to find a Python package, not a wrapper for >> some C library, as this has to run on both Windows and Linux >> and version clashes are a problem. >> > > Did you look at matplotlib? In their examples page there are some charts > like the ones you asked for. I guess it could work for you, and it seems to > work flawlessy in MS Windows as in gnu/linux. That's a wrapper for Antigrain ("http://www.antigrain.com/"), which is a C++ library. I'm trying hard to avoid dependencies on binary libraries with limited support. Builds exist only for Python 2.4 and 2.5. John Nagle
From: John Nagle on 16 Sep 2009 00:33 Alan G Isaac wrote: > There's John Zelle's graphics.py: > http://mcsp.wartburg.edu/zelle/python/ > provides basic functionality. "The package is a wrapper around Tkinter". It runs Tkinter in a separate thread and sends commands to it. > Pmw.Blt > http://heim.ifi.uio.no/~hpl/Pmw.Blt/doc/reference.html That's a wrapper for the BLT package for Tcl. (http://blt.sourceforge.net/). The documentation for the wrapper says it was developed for Windows 98. > > pygooglechart > You suggested this needs a browser, but not so, > you can download the PNGs and use the default viewer > to display them. That outsources the job to Google, which could choose at any time to cancel that service (as they did, for example, with their SOAP-based search API.) "You acknowledge and agree that Google may stop (permanently or temporarily) providing the Services (or any features within the Services) to you or to users generally at Google�s sole discretion, without prior notice to you." Besides, outsourcing something this basic just adds something else that can break. John Nagle
From: John Nagle on 16 Sep 2009 00:50
Ethan Furman wrote: > John Nagle wrote: >> >> http://home.gna.org/pychart/doc/introduction.html >> >> Tried PyChart. Set up for PNG file format. Got the error >> "Exception: Ghostscript not found." This thing just creates >> PostScript, then pumps it through GhostScript (anybody remember that?) >> to get other formats. And does the documentation say that? Only >> in the FAQ section. Grrr. >> >> There doesn't seem to be any pure Python chart module at all. >> Just wrappers. >> >> John Nagle > > http://home.gna.org/pychart/doc/module-theme.html > > > > Looks like it will directly create pdf files, not sure if that will for > you. > > Hope this helps. Thanks. More usefully, the program will generate SVG output. That I can use. There are some bugs; the SVG text sizes are about 2x too big. But I can fix that. John Nagle |