Am 13.09.2015 um 22:01 schrieb Riccardo (Jack) Lucchetti:
On Sun, 13 Sep 2015, Allin Cottrell wrote:
> On Fri, 11 Sep 2015, Sven Schreiber wrote:
>> there are already .<= and .>=
>
> OK, ".!=" will be there in gretl 1.10.2.
Nice to have; however, I'd still prefer !(a.=b) over (a.!=b). But it's a
matter of taste, I suppose.
I have to admit that I wasn't aware of the possibility to do !(a.=b),
but in any case I'm not even sure they should be equivalent. The "!" is
a logical negation operator, and what's the logical value of a matrix?
In principle one could argue that only the all-zero matrix is "False".
It's not obvious (but of course can be declared like that) that !() is
an element-wise operation.
(In NumPy there are separate matrix methods .any and .all to make
related logical distinctions, IIRC.)
Bottom line, I think it's good to have .!= directly.
Thanks,
sven