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

st: RE: Version control questions


From   "Nick Cox" <[email protected]>
To   <[email protected]>
Subject   st: RE: Version control questions
Date   Fri, 29 Apr 2005 16:40:46 +0100

In general, my advice is not to issue a program for 
a version you don't have yourself, as you then 
depend on others testing it. 

In this case, you might try something like this 

program myprog
	version 8.2 
	local oktype = cond(`c(version)' < 9, "integer", "real") 
	syntax ... , ... Level(`oktype' `c(level)') 

Nick 
[email protected] 

Richard Williams
 
> In Stata 9.0, level need not be an integer anymore, e.g. it can be 
> 99.99.  Further, looking at the docs for the 9.0 -version- 
> command, I don't 
> see any indication that -level- reverts to old behavior under version 
> control.  Ergo, for a program written under 8.2, instead of coding 
> something like
> 
> Level(integer `c(level)')
> 
> on the syntax command would it be better to code
> 
> Level(string)
> 
> and also dropping any error checks for level being between 10 
> and 99?  I 
> know that can delay error checking but I think Stata itself 
> will generate 
> errors quickly enough if the level is illegal.
 

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