Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

RE: st: RE: RE: -outreg2- in Stata 10


From   "Nick Cox" <[email protected]>
To   <[email protected]>
Subject   RE: st: RE: RE: -outreg2- in Stata 10
Date   Wed, 1 Aug 2007 21:38:19 +0100

There is a bundle of different issues here. Let me 
try to clarify, especially for anyone trying to 
follow along. 

1. The guessing is about -outreg2- because I haven't 
tested it. I don't use it; I just looked at the code. 

2. There is no guessing about -index()-. This
is documented. Richard wants a list of old stuff: 
the list under the help for -version- is long 
and detailed. In about 15 years of Stata programming
I doubt that I have looked at it, or its predecessors, 
more than a very few times. If you use -version-, 
you usually don't need to. That doesn't provide all 
he wants, but I imagine the explanation really is as simple as
the fact that the manuals are already pretty long
and only a very few people want to know about all
the old stuff too. As each new set of manuals arrives, 
I always keep the old ones. 

3. Let me emphasise here that the bugs being talked about 
are those of user-programmmers, 
Roy Wada for -outreg2- and my sparring partner Thomas 
J. Steichen and myself for -concord-. Bugs bite democratically, 
the just and the unjust, the young and the ancient, and so 
forth. And StataCorp do warn, in every manual, to go back and 
put -version <whatever>- at the top. It's true. 

4. What happens to -version- when one program calls another? 
I used the term "subroutine" informally (or sloppily, if you prefer) 
but Stata, unlike say Fortran, has no formal term 
"subroutine". The situation is this: one program calls 
another. Nothing else is important here. 

Whether they are in the same file, or whether 
you, the Stata user, think about them as being 
bound together in a family relationship, is not 
important. That's a matter of your convenience or
your way of thinking about it, but your Stata executable 
is, as you will agree, essentially unaware of any of that.) 

Richard's guess, as I understand it, was that when a program 
calls another, the -version- set is passed on (unless it is 
was explicitly set to something else inside). 

In the case of -concord-, it is the main program that 
lacks a -version- statement. So, the program runs under
version 10 in Stata 10. 

In the case of -outreg2-, something else is going 
on, as the main program is -version 8.2- and 
calls subroutines, one of which lacks a -version- 
statement. Richard raises a good point
and I don't quite understand this. The only oddity 
that springs to mind is that -program outreg2- 
is _not_ the first program defined in outreg2.ado. 
At one time, if not now, there could be puzzling 
consequences if that were so. Perhaps StataCorp 
can elucidate. 

Nick 
[email protected] 

Richard Williams
 
> At 12:13 PM 8/1/2007, Mentzakis, Emmanouil wrote:
> >As from Stata 10, -index()- is only
> >available under version control.
> >
> >It so happens that at least one subroutine of -outreg2- lacks a
> >-version- statement by a small accident. Thus the program is 
> being run
> >under Stata 10. My guess is that it needs a -version 8.2- statement.
> 
> That is my guess too.  As I understand it, -index- got renamed in 
> Stata 9.  Stata policy is to keep the old names working for one 
> version, and then they stop working the version after that, unless 
> you use version control.  So, that is why -index- still worked in 
> Stata 9 but not in 10.
> 
> To clarify though: does the -version- command only apply to the 
> subroutine that contains it?  i.e. you can't just say version 8.2 in 
> the first routine, it needs to be in every subroutine as well?  I 
> thought you just had to do it the first time, but apparently that is 
> not the case, you need to do it in every subroutine.
> 
> As a sidelight, I wish the old names just kept working, and/or that 
> there was some nice master listing of all the old names and their 
> modern counterparts.  When going through older programs, it can be 
> difficult to figure out what a command does because, while it works 
> under version control, it is no longer documented.

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