Re: [Matplotlib-users] Plot a sequence of zeros or ones

2007-02-13 Thread John Hunter
On 2/13/07, John Hunter <[EMAIL PROTECTED]> wrote: > Something like the following should do the trick: A minor modification: for a barcode, you'll want to pass interpolation='nearest' to the imshow command. I just committed the binary colormap to svn and added examples/barcode_demo.py. The new

Re: [Matplotlib-users] Plot a sequence of zeros or ones

2007-02-13 Thread John Hunter
On 2/13/07, Giorgio Gilestro <[EMAIL PROTECTED]> wrote: I have a long list composed of either 0s or 1s. I would like to plot the sequence as a horizontal bar in which 0 = black pixel, 1 = white pixel - something looking like a barcode, if you know what I mean. Is there a way do to that with matp

[Matplotlib-users] Plot a sequence of zeros or ones

2007-02-13 Thread Giorgio Gilestro
I have a long list composed of either 0s or 1s. I would like to plot the sequence as a horizontal bar in which 0 = black pixel, 1 = white pixel - something looking like a barcode, if you know what I mean. Is there a way do to that with matplotlib? Thanks