On Mon, 1 Jun 2015, Ignacio Diaz-Emparanza wrote:
I have just tried to use a program created a year before, but now
dows not
work.
It has a function which now produces an error. The problem is that the
program calls a function which applies another function to several series and
in a given step it is applied to 'const'. This was working with gretl
1.9.15cvs on 2014-05-07 17:57.
I have simplied the problem in the silly example below. Direct aplication of
function f1 seems not to have any problem, but when you run it from function
f2 for the series called 'const' this reports an error for function
'nobs(y)'
(This is for gretl from current cvs on Ubuntu Linux 14.04)
<hansl>
function series f1(series y)
scalar T=nobs(y)
return y/T
end function
function series f2(series y)
series cc = const
series zc = f1(cc)
zc
series z=f1(const)
return z
end function
nulldata 100
setobs 1 1 --time-series
e=randgen(N,2,1)
series y=f1(e)
series z2=f1(const)
series z3=f2(e)
</hansl>
This should now be fixed in CVS and snapshots.
Allin