[SciPy-user] Mathematica Element-wise Multiplication

Matthieu Brucher matthieu.brucher at gmail.com
Mon Dec 17 01:48:05 EST 2007


2007/12/17, Johann Cohen-Tanugi <cohen at slac.stanford.edu>:
>
> thanks for these precisions, David. Reading it, I still come to think
> that it is a potential source of confusion to let a "row array" have a
> transpose or T method, that essentially does nothing.



In object oriented code, this can happen often, but it is not a problem. It
does what you want : inverse the axis, even if there is only one axis.


I guess there is a
> reason behind this situation, but given the fact that it is there, I am
> wondering whether T or transpose of a row array could in fact return
> what it is expected to, aka the 2d column array. Is there any reason not
> to have this functionality?



More code in a simple function (thus slower) ? Breaking some code that
depend on it ? Not doing what the documentation says ?
I think the method should not be changed, it does exactly what it says it
does. Changing its behaviour because of Matlab is not a good solution,
Python is not Matlab.

Matthieu
-- 
French PhD student
Website : http://matthieu-brucher.developpez.com/
Blogs : http://matt.eifelle.com and http://blog.developpez.com/?blog=92
LinkedIn : http://www.linkedin.com/in/matthieubrucher
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.scipy.org/pipermail/scipy-user/attachments/20071217/7a458ddf/attachment.html>


More information about the SciPy-User mailing list