Re: [Matplotlib-users] Plot to display or file in the same script?

2011-01-26 Thread Benjamin Root
On Wednesday, January 26, 2011, David Perlman dperl...@wisc.edu wrote: I'm trying to make a simple utility for doing a quick check of some data (electrophysiology recordings from our fMRI scanner lab).  I want it to be foolproof as much as possible, so I was trying to figure out how to write

Re: [Matplotlib-users] Plot to display or file in the same script?

2011-01-26 Thread David Perlman
The problem is that if no display is available, the error gets raised on the point where I try to create a new figure, long before getting to show(), so I can't do anything at all. Here's what it looks like when I log in without a display available: import matplotlib.pyplot as plt