Am 16.09.2021 um 22:12 schrieb Allin Cottrell:
On Thu, 16 Sep 2021, Sven Schreiber wrote:
> around "ols y 0 y(-1 .. -3). I also wouldn't mind if
{1..N} meant the
> same thing as seq(1,N).
>
> I know I know, all pure syntactic sugar and not strictly necessary, but
> again: some harmonization might be nice.
FWIW, the "to" in a range of lags is a RATS-ism from way back. I'm not
too keen on propagating it to other contexts.
I agree, harmonization the other way around would be more sensible.
There's yet another range symbol: ':' in matrix indexing,
M[1:n,]. The
thought has crossed my mind to change the standard loop range spec to
loop i=1:N # as in R
but I think it's too late. We'd surely have to support the original
syntax as well, so it would add complications.
Right; and gretl's 1..N is already quite nice since it's very close to
the math formula formulation of 1...N (or 1 \ldots N).
Perhaps we could keep in the back of our head the possibility to allow
".." for integer ranges in more contexts. Including matrix indexing as
in M[1..n,]. (Since only integers are involved, there should be no
confusion with the decimal dot, apart from two dots being special already.)
cheers
sven