[Numpy-discussion] numpy.trapz() doesn't respect subclass

josef.pktd@gmai... josef.pktd@gmai...
Sun Mar 21 23:57:16 CDT 2010


On Mon, Mar 22, 2010 at 12:49 AM, Ryan May <rmay31@gmail.com> wrote:
> Hi,
>
> I found that trapz() doesn't work with subclasses:
>
> http://projects.scipy.org/numpy/ticket/1438
>
> A simple patch (attached) to change asarray() to asanyarray() fixes
> the problem fine.

Are you sure this function works with matrices and other subclasses?

Looking only very briefly at it: the multiplication might be a problem.

Josef


>
> Ryan
>
> --
> Ryan May
> Graduate Research Assistant
> School of Meteorology
> University of Oklahoma
>
> _______________________________________________
> NumPy-Discussion mailing list
> NumPy-Discussion@scipy.org
> http://mail.scipy.org/mailman/listinfo/numpy-discussion
>
>


More information about the NumPy-Discussion mailing list