Plot with missing points

Hi all,

   I am really enjoying working with matplotlib and hats off to an excellent effort.

   I have done a cursory search of the mailing list archives but didn't find the answer to a practical question that I ran into in MATLAB all the time (which is where I'm coming from in terms of familiarity).

   Suppose I have an array to plot, and I want to exclude certain points from being plotted. In MATLAB, I would set the y vector points I wanted excluded to "NaN" and then the plot routine would draw connected lines up to the point before the excluded one, skip the bad/not wanted point, and then continue drawing lines beginning at the next point.

   How does one accomplish that using matplotlib? This actually comes up quite often in our radar work here, in cases where we are making log plots of vectors which may contain zeros.



Phil Erickson email: pje@...101...
Atmospheric Sciences Group WWW:
MIT Haystack Observatory voice: 781 981 5769
Westford, MA 01886 USA fax: 781 981 5766

Public key: