Am 01.12.2014 um 23:50 schrieb Allin Cottrell:
On Mon, 1 Dec 2014, Sven Schreiber wrote:
If we were redesigning this from scratch, the latter usage might
perhaps be better written as, e.g.,
$coeff[idxof(seriesname)]
Please no, that's certainly not what I wanted to imply...
As for b[] in "restrict", well yes we might have said by
analogy
that you need to use b() rather than b[] when giving a regressor
name rather than an index. Only it's not required for disambiguation
in that context because "restrict" is a self-contained little
environment where the full power of "genr" is not available.
Basically I'm asking for syntactic sugar from a user's point of view so
that the behavior of $coeff() can be matched by b(). This seems to me
like the most natural/intuitive way. "Can do" is perfectly fine with me,
I don't need more "must do", so if b[myvar] stays then it's fine with
me.
Another way of stating this could be: Exactly because 'restrict' has its
own environment, why can't gretl allow the user more flexibility in
there, where side effects shouldn't be an issue (I hope)?
thanks,
sven