Re: [Numpy-discussion] getting position index from array

2012-01-20 Thread Ruby Stevenson
Exactly what I need - thank you very much. Ruby On Thu, Jan 19, 2012 at 11:33 PM, Benjamin Root wrote: > > > On Thursday, January 19, 2012, Ruby Stevenson wrote: >> hi, all >> >> I am a newbie on numpy ... I am trying to figure out, given an array, >> how to get back position value based on som

Re: [Numpy-discussion] getting position index from array

2012-01-19 Thread Benjamin Root
On Thursday, January 19, 2012, Ruby Stevenson wrote: > hi, all > > I am a newbie on numpy ... I am trying to figure out, given an array, > how to get back position value based on some conditions. > Say, array([1, 0, 0, 0 1], and I want to get a list of indices where > it is none-zero, [ 0 , 4 ] >

[Numpy-discussion] getting position index from array

2012-01-19 Thread Ruby Stevenson
hi, all I am a newbie on numpy ... I am trying to figure out, given an array, how to get back position value based on some conditions. Say, array([1, 0, 0, 0 1], and I want to get a list of indices where it is none-zero, [ 0 , 4 ] The closest thing I can find from the doc is select(), but I can't