Problem with cygwin/ipython interactive mode

Hi there,

I feel like I am really close to getting matplotlib working under
cygwin/ipython (although the problem persists in the conventional python
shell also).

On a more general note it seems there are dozens of different ways to run
matplotlib under windows. I used as many cygwin packages as seemed
relvant including the cygwin version of python and X etc. I then
installed numpy and ipython from source (following the linux
instructions). I tried to install pygtk and wxpython without success
(also from source). I am a bit confused in this situation when I should
follow windows installation and when I should follow unix e.g. Windows
installers of python packages appear not to work at all...

There were only two minor issues. I had to run ash / rebaseall

Also I had to create the following symbolic links :

cd /lib
ln -s libtk84.a libtk8.4.a
ln -s libtcl84.a libtcl8.4.a

Anyway my problem is the following :

from pylab import *
from numpy import *
contour(eye(100))
show()

This then produces the image and the function show() blocks on the shell.
This is all normal behaviour (it also happens in linux).

However If I then close the window and then type :
contour(eye(100))

A "Figure 1" window appears, but nothing happens in it (on linux the
contour plot would reappear).
in this situation show() also does nothing. From this point on nothing I
do can make the figure plot...

I checked the instructions on :
http://matplotlib.sourceforge.net/interactive.html
and have used the config file there with minor changes for TkAgg and
interactive mode. However this also did not work. Note : again under
cygwin I placed the file in ~/.matplotlib/matplotlibrc rather than the
suggested windows location and this seemed to work.

While interactive mode is useful it is not mandatory for what I am doing
and perhaps the easiest thing to do is set matplotlib to dump all output
to files...

Thanks in advance for any help!

David

I checked the instructions on :
http://matplotlib.sourceforge.net/interactive.html
and have used the config file there with minor changes for TkAgg and
interactive mode. However this also did not work. Note : again under
cygwin I placed the file in ~/.matplotlib/matplotlibrc rather than the
suggested windows location and this seemed to work.

While interactive mode is useful it is not mandatory for what I am doing
and perhaps the easiest thing to do is set matplotlib to dump all output
to files...

I have never used mpl under cygwin in windows, but it might help to
make sure your parameters and config files are as you expect. For
example, in interactive mode, you should not need to call show to get
the figure to appear. Please report the output of a test script in
the same environment with the --verbose-helpful flag

python test.py --verbose-helpful

where test.py is something like:

  from pylab import plot, show
  plot([1,2,3])
  show()

this should echo your backedn and interactive settings, as well as the
matplotlibrc file location.

JDH

···

On Jan 22, 2008 11:11 PM, <djr@...1853...> wrote: