Notice: On March 31, it was **announced** that Statalist is moving from an email list to a **forum**. The old list will shut down on April 23, and its replacement, **statalist.org** is already up and running.

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

From |
"Martin Weiss" <martin.weiss1@gmx.de> |

To |
<statalist@hsphsun2.harvard.edu> |

Subject |
AW: st: How to retrieve parameter estimates from an ML program, so they can be used in estimation of expected values, variances, etc... |

Date |
Mon, 29 Mar 2010 15:29:29 +0200 |

<> " A really indispensable book when writing this kind of programs in Stata is: http://www.stata.com/bookstore/mle.html"; With the fourth edition apparently forthcoming: http://www.stata-press.com/forthcoming.html HTH Martin -----Ursprüngliche Nachricht----- Von: owner-statalist@hsphsun2.harvard.edu [mailto:owner-statalist@hsphsun2.harvard.edu] Im Auftrag von Maarten buis Gesendet: Montag, 29. März 2010 15:22 An: statalist@hsphsun2.harvard.edu Betreff: Re: st: How to retrieve parameter estimates from an ML program, so they can be used in estimation of expected values, variances, etc... --- On Mon, 29/3/10, SLG Brilleman wrote: > I have recently written a program for ml estimation using > the generalized Gamma distribution. The estimation routine > seems to run fine and will produce estimates of the > coefficients for the linear predictor (mu), and estimates of > the two shape parameters (sigma and kappa). > > My problem is that I want to estimate the expected value of > yi (i.e. the individual predictions) - an equation involving > estimates of all three parameters (mu, sigma, kappa). I am > reasonably new to STATA and cannot figure out the syntax to > retrieve and store the estimates of mu, sigma, and kappa, so > that I can generate the new variable yi. > > I have tried 'ereturn', 'scalar' and 'gen' statements both > within the program and externally after ml maximise (when > outside the program I have the additional problem of > distinguishing between the two shape parameters currently > both _cons in the output). You can use predict to get the linear predictors, you can also write your own predict sub-program, which will be called by -predict- automatically create more complicated predictions. See for example -viewsource logit_p.ado-. A really indispensable book when writing this kind of programs in Stata is: http://www.stata.com/bookstore/mle.html Hope this helps, Maarten -------------------------- Maarten L. Buis Institut fuer Soziologie Universitaet Tuebingen Wilhelmstrasse 36 72074 Tuebingen Germany http://www.maartenbuis.nl -------------------------- * * For searches and help try: * http://www.stata.com/help.cgi?search * http://www.stata.com/support/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/statalist/faq * http://www.ats.ucla.edu/stat/stata/

**References**:**st: How to retrieve parameter estimates from an ML program, so they can be used in estimation of expected values, variances, etc...***From:*SLG Brilleman <sam.brilleman@bristol.ac.uk>

**Re: st: How to retrieve parameter estimates from an ML program, so they can be used in estimation of expected values, variances, etc...***From:*Maarten buis <maartenbuis@yahoo.co.uk>

- Prev by Date:
**st: string variable question** - Next by Date:
**Re: st: string variable question** - Previous by thread:
**Re: st: How to retrieve parameter estimates from an ML program, so they can be used in estimation of expected values, variances, etc...** - Next by thread:
**Re: st: How to retrieve parameter estimates from an ML program, so they can be used in estimation of expected values, variances, etc...** - Index(es):