Assignment will never change the data-type of an already allocated array. So,
x['f2'] = y will try to convert the array to 'S10'.
On my system I get:
array([(1, 2.0, 'Hello'), (2, 3.0, 'World')],
dtype=[('f0', ' Dear All,
>
> See below code pls,
>
> import sicpy
> import numpy as np
On Thu, Sep 23, 2010 at 7:22 PM, Lisandro Dalcin wrote:
> On 23 September 2010 01:26, Charles R Harris
> wrote:
> >
> >
> > On Wed, Sep 22, 2010 at 10:00 PM, Charles R Harris
> > wrote:
> >>
> >>
> >> On Wed, Sep 22, 2010 at 9:14 PM, Fernando Perez
> >> wrote:
> >>>
> >>> On Wed, Sep 22, 2010
On 23 September 2010 01:26, Charles R Harris wrote:
>
>
> On Wed, Sep 22, 2010 at 10:00 PM, Charles R Harris
> wrote:
>>
>>
>> On Wed, Sep 22, 2010 at 9:14 PM, Fernando Perez
>> wrote:
>>>
>>> On Wed, Sep 22, 2010 at 7:16 PM, Charles R Harris
>>> wrote:
>>> >
>>> > Done in 29cccb6.
>>> >
>>>
>
Hi all,
The commit mailing list is running again.
Regards
Stéfan
___
NumPy-Discussion mailing list
NumPy-Discussion@scipy.org
http://mail.scipy.org/mailman/listinfo/numpy-discussion
Hi Brett, Josef, Gökhan, and Anne,
Many thanks for the suggestions! This indexing problem was not as
straight-forward as I had anticipated. I have it working now, thanks
to your help.
Gökhan, I'm driving an ecosystem--atmosphere carbon dioxide flux model
with MODIS measurements, so this_par and
On Tue, Sep 21, 2010 at 12:48 PM, Ken Basye wrote:
> If that's going to break too much code, here's a pathway that might be
> acceptable: Add a new function moveaxis() which works the way
> rollaxis() does for positive arguments but in the new way for negative
> arguments. Eventually, rollaxis c
On Thu, Sep 23, 2010 at 10:32 AM, Anne Archibald
wrote:
> Just a quick correction: len(a) gives a.shape[0], while what you want
> is actually len(a.shape). So:
>
> In [1]: a = np.zeros((2,3,4,5,6))
>
> In [2]: len(a)
> Out[2]: 2
>
> In [8]: np.rollaxis(a,0,len(a.shape)).shape
> Out[8]: (3, 4, 5, 6
On 23 September 2010 02:20, Ralf Gommers wrote:
>
>
> On Wed, Sep 22, 2010 at 4:14 AM, Anne Archibald
> wrote:
>>
>> Hi Ken,
>>
>> This is a tricky one. The current behaviour of rollaxis is to remove
>> the requested axis from the list of axes and then insert it before the
>> axis specified. This
Dag Sverre Seljebotn wrote:
> Friedrich Romstedt wrote:
>
>> I just ran across the problem of priorities with ndarrays again and it
>> keeps biting me. I did once ago a workaround to get my ``undarray``
>> class's methods be called when being the second operand of e.g.
>> + . But since I wrot
Friedrich Romstedt wrote:
> I just ran across the problem of priorities with ndarrays again and it
> keeps biting me. I did once ago a workaround to get my ``undarray``
> class's methods be called when being the second operand of e.g.
> + . But since I wrote it, always Python crashes
> on exit w
Anne says:
This is a tricky one. The current behaviour of rollaxis is to remove
the requested axis from the list of axes and then insert it before the
axis specified. This is exactly how python's list insertion works:
In [1]: a = range(10)
In [3]: a.insert(-1,'a')
In [4]
Hi Sebastian,
Thanks for your reply!
2010/9/22 Sebastian Walter :
> [...] I think the issue is not so much numpy but rather the
> way Python implements operator overloading using methods like __add__
> and __radd__. Hence, your suggestion seems to be a Python Enhancement
> Proposal and should be
On Thu, Sep 23, 2010 at 12:20 AM, Ralf Gommers
wrote:
>
>
> On Wed, Sep 22, 2010 at 4:14 AM, Anne Archibald <
> aarch...@physics.mcgill.ca> wrote:
>
>> Hi Ken,
>>
>> This is a tricky one. The current behaviour of rollaxis is to remove
>> the requested axis from the list of axes and then insert it
13 matches
Mail list logo