[SciPy-dev] Numpy example for arctan2 perhaps wrong/misleading/confusing?

Samuel John scipy@SamuelJohn...
Mon Jun 9 11:06:16 CDT 2008


Hi there!

On Mon, Jun 9, 2008 at 5:47 PM, Jonathan Guyer <guyer@nist.gov> wrote:
>
> On Jun 9, 2008, at 10:56 AM, Samuel John wrote:
>> I would argue to show just the scalar version in the example and
>> leave out
>> the broadcasting version, because it makes less sense here, doesn't
>> it?
>
> No. Perhaps, though, the example should not use two-element arrays, to
> avoid any ambiguity in interpretation.

However, I would prefer an example with scalars (first) but only for
arctan2... not the other examples.


>> Is there any fancy matrix-or-whatever notation, that really makes up a
>> good example for broadcasting with arctan2?
>

> We use this all the time to calculate fields of angles from fields of
> vector components. It's not a matrix thing. It's a field thing. It
> makes just as much (or as little) sense as sin(array([a1, a2,
> a3, ...])).

ok, fine ...


> It works like everything else. Please leave it alone.

No one want to change anything here :-)
Perhaps just one example :-P


cheers,
 Samuel


More information about the Scipy-dev mailing list