[Numpy-discussion] behavior of 'insert' for inserting multiple values

Travis E. Oliphant oliphant@enthought....
Fri May 30 11:38:21 CDT 2008


mark wrote:
> I think this is a special case that was overlooked.
> It works if there are multiple positions but only one value:
>   
>>>> a = arange(5)
>>>> insert(a,[3,3],4)
>>>>         
> array([0, 1, 2, 4, 4, 3, 4])
>
> But not when you give one position with mutiple values:
>   
>>>> insert(a,3,[7,7])
>>>>         
> array([0, 1, 2, 7, 3, 4])
>
> It would be great if somebody could implement this.
> Probably not too hard I guess,
> Thanks. You guys are the best,
>   
If you file a ticket, this request is less likely to be lost or 
forgotten.  Thanks for the testing and feedback.

Best regards,

-Travis

>   



More information about the Numpy-discussion mailing list