Re: [Numpy-discussion] In-place fancy selection

2007-03-01 Thread Anne Archibald
On 01/03/07, Francesc Altet <[EMAIL PROTECTED]> wrote: Hi, I don't think there is a solution for this, but perhaps anybody may offer some idea. Given: In [79]:a=numpy.arange(9,-1,-1) In [80]:b=numpy.arange(10) In [81]:numpy.random.shuffle(b) In [82]:b Out[82]:array([2, 6, 3, 5, 4, 9, 0, 8, 7, 1

Re: [Numpy-discussion] In-place fancy selection

2007-03-01 Thread Francesc Altet
El dj 01 de 03 del 2007 a les 13:40 -0700, en/na Charles R Harris va escriure: > > > On 3/1/07, Francesc Altet <[EMAIL PROTECTED]> wrote: > Hi, > > I don't think there is a solution for this, but perhaps > anybody may > offer some idea. Given: > >

Re: [Numpy-discussion] In-place fancy selection

2007-03-01 Thread Charles R Harris
On 3/1/07, Francesc Altet <[EMAIL PROTECTED]> wrote: El dj 01 de 03 del 2007 a les 13:26 -0700, en/na Charles R Harris va escriure: > > > On 3/1/07, Francesc Altet <[EMAIL PROTECTED]> wrote: > Hi, > > I don't think there is a solution for this, but perhaps > anybody may >

Re: [Numpy-discussion] In-place fancy selection

2007-03-01 Thread Francesc Altet
El dj 01 de 03 del 2007 a les 13:26 -0700, en/na Charles R Harris va escriure: > > > On 3/1/07, Francesc Altet <[EMAIL PROTECTED]> wrote: > Hi, > > I don't think there is a solution for this, but perhaps > anybody may > offer some idea. Given: > >

Re: [Numpy-discussion] In-place fancy selection

2007-03-01 Thread Charles R Harris
On 3/1/07, Francesc Altet <[EMAIL PROTECTED]> wrote: Hi, I don't think there is a solution for this, but perhaps anybody may offer some idea. Given: In [79]:a=numpy.arange(9,-1,-1) In [80]:b=numpy.arange(10) In [81]:numpy.random.shuffle(b) In [82]:b Out[82]:array([2, 6, 3, 5, 4, 9, 0, 8, 7, 1]

Re: [Numpy-discussion] In-place fancy selection

2007-03-01 Thread Charles R Harris
On 3/1/07, Charles R Harris <[EMAIL PROTECTED]> wrote: On 3/1/07, Francesc Altet <[EMAIL PROTECTED]> wrote: > > Hi, > > I don't think there is a solution for this, but perhaps anybody may > offer some idea. Given: > > In [79]:a=numpy.arange(9,-1,-1) > In [80]:b=numpy.arange(10) > In [81]:numpy

Re: [Numpy-discussion] In-place fancy selection

2007-03-01 Thread Charles R Harris
On 3/1/07, Francesc Altet <[EMAIL PROTECTED]> wrote: Hi, I don't think there is a solution for this, but perhaps anybody may offer some idea. Given: In [79]:a=numpy.arange(9,-1,-1) In [80]:b=numpy.arange(10) In [81]:numpy.random.shuffle(b) In [82]:b Out[82]:array([2, 6, 3, 5, 4, 9, 0, 8, 7, 1]

[Numpy-discussion] In-place fancy selection

2007-03-01 Thread Francesc Altet
Hi, I don't think there is a solution for this, but perhaps anybody may offer some idea. Given: In [79]:a=numpy.arange(9,-1,-1) In [80]:b=numpy.arange(10) In [81]:numpy.random.shuffle(b) In [82]:b Out[82]:array([2, 6, 3, 5, 4, 9, 0, 8, 7, 1]) In [83]:a=a[b] In [84]:a Out[84]:array([7, 3, 6, 4, 5,