thanks Sturl, your second code works well although I had to divide the vector elements through 128 to get just the binaries -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.scipy.org/pipermail/numpy-discussion/attachments/20110331/d33ce79d/attachment.html