Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: st: Maximum Likelihood with mata vs Stata


From   "Amparo Nagore Garcia" <[email protected]>
To   [email protected]
Subject   Re: st: Maximum Likelihood with mata vs Stata
Date   Wed, 26 Mar 2014 12:36:38 +0100

Thank you very much Maarten!I will see the possibility of programing analytical solutions. 
On the other hand, it seems that "ml maximize" calls moptimize() from mata, so I thought that it does not matter whether I use any of them for the speed  of the computations, but I am not totally sure about that. 
Best,
Amparo 
On Miércoles 26 Marzo 2014 09:55 CET, Maarten Buis <[email protected]> wrote: 
 
> I don't know the insides -ml-, but I am not surprised. What the
> evaluator program does is create a variable, and that is something
> Stata can do very quickly.
> 
> In my experience you can get a lot of extra speed by specifying
> analytical solutions to the first and second derivatives (at the cost
> of spending extra time programming, checking, and debugging them).
> 
> Hope this helps,
> Maarten
> 
> 
> On Tue, Mar 25, 2014 at 9:22 PM, Amparo Nagore Garcia
> <[email protected]> wrote:
> > Hello everyone,
> >
> > I am estimating my own likelihood function of a correlated competing risks model following chapter 11 "Mata-based likelihood evaluators" of "Maximum Likelihood Estimation with Stata" from William Gould , Jeffrey Pitblado and Brian Poi.
> > So I have programmed in mata the evaluator function and I have used ml maximize to maximize the function. I am using Stata 11.
> > I have a large dataset and three destination states. I have to estimate 130 variables.
> > I have the impression that it is not faster than the estimation using my likelihood function estimated using my stata code for the evaluator function. Is it possible? It may be due to the fact that I am maximizing the function using "ml maximize", and in this case I am not taking advantage of the matrix computation. Is there any trick to make it faster?
> >
> > Any help will be really appreciated.
> >
> > Thank you very much in advance.
> >
> > Amparo
> >
> > *
> > *   For searches and help try:
> > *   http://www.stata.com/help.cgi?search
> > *   http://www.stata.com/support/faqs/resources/statalist-faq/
> > *   http://www.ats.ucla.edu/stat/stata/
> 
> 
> 
> -- 
> ---------------------------------
> Maarten L. Buis
> WZB
> Reichpietschufer 50
> 10785 Berlin
> Germany
> 
> http://www.maartenbuis.nl
> ---------------------------------
> 
> *
> *   For searches and help try:
> *   http://www.stata.com/help.cgi?search
> *   http://www.stata.com/support/faqs/resources/statalist-faq/
> *   http://www.ats.ucla.edu/stat/stata/
> 
 
 
 

*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/faqs/resources/statalist-faq/
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index