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

st: programming stata: storing results in arrays for future reference


From   "Mitrani, Alex" <[email protected]>
To   <[email protected]>
Subject   st: programming stata: storing results in arrays for future reference
Date   Fri, 18 Jun 2004 18:56:59 +0100

Dear stata users,

I am embarking on my first programming exercise with stata, and would appreciate a little advice.  The task involves getting a model command to iterate a number of times with a sub-set of the independent variables being systematically modified each time using different values of a scaling factor (say going from 0 to 5 in increments of 0.1).  I need to retrieve the log likelihood of each model, and display them alongside the corresponding values of the scaling factor.  In this way the scalilng factor that results in the model best fitting the data can be obtained.    

I am sure this is all possible, but having read the material in the users' guide on programming stata, I cannot see a simple way of storing the different values of the log likelihood in an array (I know that this is very straight-forward in most other programming languages), so that they can be conveniently displayed after the model runs have been finished, for instance by looping a display command over all the values contained in the array.  

Any help with this would be greatly appreciated.  


Alex





Alex Mitrani


Steer Davies Gleave 
28-32 Upper Ground, London SE1 9PD, UK

[direct]	+44 (0)20 7910 5578
[main]	+44 (0)20 7919 8500
[fax]	+44 (0)20 7827 9850
[e-mail]   	[email protected]

http://www.steerdaviesgleave.com/
This message is sent in confidence for the addressee only. It may contain legally privileged information. The contents are not to be disclosed to anyone other than the addressee. Unauthorised recipients are requested to preserve this confidentiality and to advise the sender immediately of any error in transmission.


*
*   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