octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Making bsxfun automatic


From: Jordi Gutiérrez Hermoso
Subject: Making bsxfun automatic
Date: Wed, 3 Aug 2011 19:54:35 -0500

For some stuff at work, I've been working with numpy, and I see that
they implemented something I asked about way back when:

     
http://octave.1599824.n4.nabble.com/Applying-each-element-of-a-vector-to-each-row-of-a-matrix-tp3094532p3094532.html

While bsxfun works, it's obscure, people don't know about it, and
frankly, it's just damn ugly, and I shouldn't feel proud about myself
for using it to solve something. People should just attempt the
multiplication they want with .* and be happy it works. Numpy's
approach is just that: bsxfun is just simply "automatic" and it seems
much nicer. We could implement this without breaking any Matlab code,
making it a nice Octave extension.

Any objections?

- Jordi G. H.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]