[Matplotlib-users] How to create a square wave plot

2011-08-02 Thread Freedom Fighter
Hi, what's the easiest method of creating a square wave plot? Let's say I have a data stream of bits that have values of "1" or "-1". The plot function wants to draw a diagonal line between those points but I need to have a horizontal line. So to get a "square wave" I must insert additional p

Re: [Matplotlib-users] How to create a square wave plot

2011-08-02 Thread sebastian
Hi, On Tue, 02 Aug 2011 08:43:47 +, Freedom Fighter wrote: > Hi, > > what's the easiest method of creating a square wave plot? > Let's say I have a data stream of bits that have values of "1" or > "-1". > The plot function wants to draw a diagonal line between those points > but I need to

Re: [Matplotlib-users] How to create a square wave plot

2011-08-02 Thread Freedom Fighter
Perfect. This works. import random import matplotlib.pyplot as plt N = 10 x_vals = range(N) bit_vals = [-1, 1] my_bits = [] for x in xrange(N): my_bits.append(bit_vals[random.randint(0, 1)]) print my_bits fig = plt.figure() ax = fig.add_axes([0.1, 0.1, 0.8, 0.8]) ax.set_ylim(ymin=-2,

Re: [Matplotlib-users] plot with discontinuous x-axis

2011-08-02 Thread denoise
Great! The last post from the page http://stackoverflow.com/questions/5656798/python-matplotlib-is-there-a-way-to-make-a-discontinuous-axis was exactly what i want! It should work for me with some little modifications! Thanks to all! I'll post a screenshot when it's ready! Hubert Warren Weck

[Matplotlib-users] installation issues

2011-08-02 Thread Ivan D Vasin
i came across some issues while attempting to install matplotlib today: first issue: no bug tracker matplotlib's website has a link to a bug tracker that is no longer available. i'm guessing this mailing list is the new bug tracker, which seems to me like a downgrade. second i

[Matplotlib-users] Installation on Mac OS X Lion - good news

2011-08-02 Thread Felix-Antoine Fortin
Hi, Just a quick point of information that might saved time to some of you. Installation of matplotlib is now pretty straightforward on Mac OS X 10.7 with HomeBrew. Let's say you want to install the last version : $ brew install pkg-config $ git clone git://github.com/matplotlib/matplotlib.git $

Re: [Matplotlib-users] installation issues

2011-08-02 Thread John Hunter
On Mon, Aug 1, 2011 at 6:48 PM, Ivan D Vasin wrote: > i came across some issues while attempting to install matplotlib today: > > > > first issue: no bug tracker > > matplotlib's website has a link to a bug tracker that is no longer available. >  i'm guessing this mailing list is > the

Re: [Matplotlib-users] close gtk2 figure without main_quit() call

2011-08-02 Thread Benjamin Root
On Mon, Aug 1, 2011 at 2:44 PM, Alexey Uimanov wrote: > I am writing gtk2 application on python, I need to plot a chart in > separate window and i just use this code > >def matplot_print(self, print_values): >"""\brief print data by matplotlib and shw the figure >\param print_

[Matplotlib-users] Matplotlib freezing in Save menu

2011-08-02 Thread Peter DeVore
Hello all, In Windows, when I create any plot, click on the save button, then right click in the save window (e. g. to create a new folder or rename a file), Matplotlib freezes. It stays frozen until I close Explorer. Also the Interpret that launched it stays frozen too. OS: Windows XP x64