> eval max(deflist(1,2,3))
> </hansl>
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.
BTW, this works:
eval max(20 * ones(3,1))
while this throws an error about wrong arg type:
eval max(20 * ones(3,2))
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
In eval max(20 * ones(3,2)) '20' seems to be
irrelevant: 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
Oleh
14 березня 2018, 20:22:11, від "Sven Schreiber" <svetosch(a)gmx.net>:
Am 14.03.2018 um 19:14 schrieb Allin Cottrell:
> On Wed, 14 Mar 2018, Sven Schreiber wrote:
>> eval max(deflist(1,2,3))
>> </hansl>
>
> 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.
BTW, this works:
eval max(20 * ones(3,1))
while this throws an error about wrong arg type:
eval max(20 * ones(3,2))
I tend to think that either both should work or both should fail. In the
former case the docs would need to reflect this.
And to be clear in the first case, there are no series IDs 20, so it
could not be possibly interpreted as such.
(There have been several times in the past when I remarked on the list
that max seems to be working for matrix input, but never got much of a
reply.)
thanks,
sven
_______________________________________________
Gretl-devel mailing list
Gretl-devel@lists.wfu.eduhttp://lists.wfu.edu/mailman/listinfo/gretl-devel