On Tue, 13 Mar 2018, Sven Schreiber wrote: > Am 13.03.2018 um 00:13 schrieb Summers, Peter: > >> If you mean being able to do something like (assuming m has been >> defined) >> >> <console> >> rows(m) >> </console> >> instead of >> <console> >> r = rows(m) >> r >> </console> > > Exactly.
Though of course you don't have to take two lines over it as things stand: the real comparison is "eval rows(m)" versus plain "rows(m)". >> Maybe this just reflects my Matlab background, but it's always >> struck me as inefficient on gretl's part. > > Not just Matlab, but also R, Python, Julia, you name it. What you're suggesting (making "eval" implicit for any input line that doesn't make sense as a command or function call) could probably be done, but there's a relevant difference between the languages you mention and hansl. Unlike hansl, none of those languages have commands, they all work purely via functions. So if a given input line is not a function call it can immediately be taken as an "eval" request. Other languages that have commands -- bash, stata, for example, and I suspect other econometrics software such as RATS, Eviews, Limdep -- don't do the "automatic-eval" thing. By default they're expecting a command-word, if not a function call. At present we print one line of text when the console is opened, apprising the user of 'help'. Maybe we could add a second line, something like "You can use 'eval' to evaluate any expression". Allin
