From: Matthew B. <mat...@gm...> - 2006-10-05 21:30:39
|
Hi, On 10/5/06, Martin Wiechert <mar...@gm...> wrote: > Hi list, > > when I try to assign a sequence as an element of an object array via flat > indexing only the first element of the sequence is assigned: I've also been having trouble with flat on object arrays. Is this intended? In [1]: from numpy import * In [2]: a = arange(2) In [3]: a[1] Out[3]: 1 In [4]: a.flat[1] Out[4]: 1 In [5]: b = array([a], dtype=object) In [6]: b[1] --------------------------------------------------------------------------- exceptions.IndexError Traceback (most recent call last) /home/mb312/devel_trees/scipy/Lib/io/<ipython console> IndexError: index out of bounds In [7]: b.flat[1] Out[7]: 1 Best, Matthew |