Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: Re: storing likelihood values


From   Kit Baum <[email protected]>
To   [email protected]
Subject   st: Re: storing likelihood values
Date   Tue, 22 Jun 2004 11:00:26 -0400

On Jun 22, 2004, at 2:33 AM, Rafa wrote:


Alternatively you can generate new variables containing the log likelihood,
you simple change local ll_`x' for gen ll_`x' in the above loop.
A Very Bad Idea. Variables should not be used to contain scalars unless you have some arithmetic of that sort in mind. Imagine that one could have a couple of million observations; the overhead of storing the same number that many times (when all one wants is the number, stashed somewhere) is stupendous. Use macros, as suggested, or stuff the LLF values into cells of an array if you'd like to be able to produce a nice table from them. (Shameless plug: findit outtable).

Kit

*
* For searches and help try:
* http://www.stata.com/support/faqs/res/findit.html
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/




© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index