From: Travis O. <oli...@ee...> - 2006-10-05 22:11:35
|
Martin Wiechert 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: > > > >>>>import numpy >>>>numpy.version.version >>>> >>>> >'1.0rc1.dev3171' > > >>>>from numpy import * >>>>a = ndarray ((2,2), object) >>>>a.flat [2] = (1, 2, 3) >>>>a.flat [2] >>>> >>>> >1 > > >>>>a >>>> >>>> >array([[None, None], > [1, None]], dtype=object) > >Is this a feature? Wouldn't a naive user like me expect >a.flat [2] == (1, 2, 3)? > > > You are probably right. This should be changed. -Travis |