Hi,
I am trying to run non-linear least squares to estimate some parameters.
A colleague of mine has run the estimation in Matlab to check the robustness of the estimates that I am getting.
1. I am finding the EViews is converging to the boundary points, that I have set, more often than Matlab.
2. The objective function gives a smaller sum of squares for Matlab than EViews when parameter estimates differ between the two.
I have tried increasing the max number of iterations, as well as the convergence used.
I have also tried setting use numeric only.
None of these options have changed my results.
Is there a way to change the iteration algorithm being used by EViews?
Any advice on something else I could try?
(I have currently invested some time trying to learn how to use EViews and I don't want to have to change software packages now :) )
Please Help!
Jen
NLS - Converging to bounds....
Moderators: EViews Gareth, EViews Moderator
-
EViews Chris
- EViews Developer
- Posts: 161
- Joined: Wed Sep 17, 2008 10:39 am
Re: NLS - Converging to bounds....
Could you elaborate on 'EViews is converging to the boundary points, that I have set'?
There's a few different problems that can arise in NLS that are a bit different in nature:
1) if the objective function is not globally convex, then you can end up at a local minimum instead of a global minimum
2) the objective function can be such that if the coefficients get into a particular bad region during the optimisation, it can be hard to escape (eg. a whole portion of the objective becomes zero due to a coeficient inside an exp() function causing underflow)
3) if you start a long way away from the optimum, the Gauss-Newton approximation to the Hessian can be a poor approximation to the true Hessian and so the Gauss-Newton steps can take a long time to make significant progress
In most cases, your best bet for fixing all of these problems is to choose starting values carefully. (Note that EViews will pull in whatever happens to be in the coefficient vector 'c' at the time you begin the NLS procedure to use as starting values).
EViews currently always uses a Gauss-Newton approximation to the hessian for NLS problems, but for most NLS problems this is a very effective algorithm. (EViews doesn't currently support using a BFGS approximation to the Hessian, which is another popular choice, but on most NLS problems Gauss-Newton tends to use fewer iterations and is at least as reliable).
Matlab has a wide variety of optimization procedures available (depending on which Matlab toolboxes you have purchsed) and they certainly deal with a much broader variety of optimization problems than those handled by EViews, but most NLS problems are likely to yield the same results in the two packages.
You may like to send a workfile showing an example of the problems that you are having to support@eviews.com. We'd be happy to have a look and see if anything unexpected seems to be going on.
There's a few different problems that can arise in NLS that are a bit different in nature:
1) if the objective function is not globally convex, then you can end up at a local minimum instead of a global minimum
2) the objective function can be such that if the coefficients get into a particular bad region during the optimisation, it can be hard to escape (eg. a whole portion of the objective becomes zero due to a coeficient inside an exp() function causing underflow)
3) if you start a long way away from the optimum, the Gauss-Newton approximation to the Hessian can be a poor approximation to the true Hessian and so the Gauss-Newton steps can take a long time to make significant progress
In most cases, your best bet for fixing all of these problems is to choose starting values carefully. (Note that EViews will pull in whatever happens to be in the coefficient vector 'c' at the time you begin the NLS procedure to use as starting values).
EViews currently always uses a Gauss-Newton approximation to the hessian for NLS problems, but for most NLS problems this is a very effective algorithm. (EViews doesn't currently support using a BFGS approximation to the Hessian, which is another popular choice, but on most NLS problems Gauss-Newton tends to use fewer iterations and is at least as reliable).
Matlab has a wide variety of optimization procedures available (depending on which Matlab toolboxes you have purchsed) and they certainly deal with a much broader variety of optimization problems than those handled by EViews, but most NLS problems are likely to yield the same results in the two packages.
You may like to send a workfile showing an example of the problems that you are having to support@eviews.com. We'd be happy to have a look and see if anything unexpected seems to be going on.
Re: NLS - Converging to bounds....
Thanks for the info I really appreciate it.
I have emailed a copy of my workfile/program if someone could take a look that would be really appreciated.
I also included a new somewhat related question in my email....
When I am trying to put my equation into a system and then run nls I am unable to get a result.
I get a near singluar matrix error.
Any ideas as to why I am able to run equation.ls but when the same equation is in a system and I run system.ls I get an error?
Thanks again!
Jen
I have emailed a copy of my workfile/program if someone could take a look that would be really appreciated.
I also included a new somewhat related question in my email....
When I am trying to put my equation into a system and then run nls I am unable to get a result.
I get a near singluar matrix error.
Any ideas as to why I am able to run equation.ls but when the same equation is in a system and I run system.ls I get an error?
Thanks again!
Jen
Who is online
Users browsing this forum: No registered users and 2 guests
