If you mean 'vector' instead of a matrix with more than one
row/col,
that's what Allin referred to in his earlier answer. (legacy thing)
max(vec(a_matrix)) works better them imaxc(imaxr(a_matrix))
I have run it with $stopwatch and huge matrices
Oleh
15 березня 2018, 12:30:29, від "Sven Schreiber" <svetosch(a)gmx.net>:
Am 15.03.2018 um 10:49 schrieb > oleg_komashko(a)ukr.net:
>>> eval max(deflist(1,2,3))
>>> </hansl>
>>
[Allin:]
>> Yes, should work according to the doc. This usage is an exception to the
>> rule (recently enforced properly) that series can never be referred to
>> by ID number when they appear as function arguments. But since the usage
>> is stated to be OK I have re-enabled it.
[Oleh:]
> It seems there are somewhat different rules work:
>
> eval max(deflist(1,2,3)) gives error since
>
> eval deflist(1,2,3) gives error: deflist requires
> declaring named list at the left-hand side
No, it was a bug and should work in the future, see above.
> In eval max(20 * ones(3,2)) '20' seems to be
> irrelevant:
Yes, I just wanted to make sure those numbers could not be mistaken for
series IDs (in a workfile with just 2 or 3 series).
eval max(ones(3,2)) will give an error
> Statistical functions except for sum() (max, min, mean, median, etc.)
> all works only with vector; one should evaluate max(vec(ones(3,2)) etc
If you mean 'vector' instead of a matrix with more than one row/col,
that's what Allin referred to in his earlier answer. (legacy thing)
(Because those functions do not _only_ work with a vector [or series],
they also work on lists, but with a slightly different meaning, see the
doc.)
cheers,
sven
_______________________________________________
Gretl-devel mailing list
Gretl-devel@lists.wfu.eduhttp://lists.wfu.edu/mailman/listinfo/gretl-devel