On Fri, 28 Jan 2011, GREg Ory wrote:
I need some tips on estimating panel data using nonlinear switching
regression technique. AFAIK there are two ways of solving it.
I've had one more go at this problem, because it seems like quite
a nice showcase for what one can now do with gretl scripting. I'm
attaching a script which combines the grid-search approach with
NLS estimation. That is, I first do the grid-search, over what
you stated were acceptable values for mu and sigma, then I
initialize NLS using the best values from the grid. The script
includes a "switch" to turn fixed-effects on or off.
What I'm getting from this (with fixed effects on) is:
grid-search
(mu,sigma) = (0.40, 0.20); SSR = 25.6531, R^2 = 0.803620
NLS (unconstrained)
(mu,sigma) = (0.18, 0.03); SSR = 25.4212, R^2 = 0.806201
That is, NLS finds a slightly better fit with an "out of bounds"
mu value. NLS also shows that the sigma estimate is statistically
indistinguishable from zero, which suggests that the logistic term
may not be appropriate.
Allin Cottrell