looping over arrays in numarray/numeric

2005-09-09 Thread proof
a = range(100) b = [a] * 3 b[1] = [k + i for k, i in zip(b[1], b[2])] This is rather slow in python and I thought that kind of things should be written using numeric or numarray. I tried to read trough manuals but it didn't help me. So how is this done using numeric or numarray? --

Re: looping over arrays in numarray/numeric

2005-09-09 Thread Robert Kern
proof wrote: a = range(100) b = [a] * 3 b[1] = [k + i for k, i in zip(b[1], b[2])] This is rather slow in python and I thought that kind of things should be written using numeric or numarray. I tried to read trough manuals but it didn't help me. So how is this done using numeric or