Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: st: RE: RE: RE: RE: error messages while using the stgest command
From
Victor Mauricio Herrera <[email protected]>
To
[email protected]
Subject
RE: st: RE: RE: RE: RE: error messages while using the stgest command
Date
Fri, 04 Jun 2010 15:21:55 -0500
Nick is right. After removing the parenthesis everything works fine. Also, variables created by lafconf and baseconf are dropped after running stgest and this prevented weibull from runing. Once I recreated them with makebase and makelag the weibull model and gesttowb ran also without problem.
Thanks!
Victor.
On 06/04/10, Nick Cox <[email protected]> wrote:
> Yes, that's my guess.
>
> If it gets as far as the -graph- command then the local macro options is
> discovered at that point, and only then, to contain junk that Stata
> can't make sense of.
>
> It's my impression that in this sense Stata has not changed for some
> while. Any parsing that leaves a residuum of buggy material in some
> local macro will not bite unless and until that macro is scrutinised.
>
> Here's a demo:
>
> Here's a program:
>
> program martin
> syntax [, * ]
> sysuse auto, clear
> regress mpg weight
> end
>
> Here I run it:
>
> . martin, complete and utter nonsense
>
> (1978 Automobile Data)
>
> Source | SS df MS Number of obs =
> 74
> -------------+------------------------------ F( 1, 72) =
> 134.62
> Model | 1591.9902 1 1591.9902 Prob > F =
> 0.0000
> Residual | 851.469256 72 11.8259619 R-squared =
> 0.6515
> -------------+------------------------------ Adj R-squared =
> 0.6467
> Total | 2443.45946 73 33.4720474 Root MSE =
> 3.4389
>
> ------------------------------------------------------------------------
> ------
> mpg | Coef. Std. Err. t P>|t| [95% Conf.
> Interval]
> -------------+----------------------------------------------------------
> ------
> weight | -.0060087 .0005179 -11.60 0.000 -.0070411
> -.0049763
> _cons | 39.44028 1.614003 24.44 0.000 36.22283
> 42.65774
> ------------------------------------------------------------------------
> ------
>
> What happened:
>
> 1. I typed as if they were options "complete and utter nonsense".
>
> 2. A consequence of the -syntax- statement is that a local macro options
> is created with contents "complete and utter nonsense".
>
> 3. My program never actually used `options'. Thus my program never bit
> me, and Stata never complained, even though I typed (you guessed) some
> nonsense on the command line.
>
> Nick
> [email protected]
>
> Martin Weiss
>
> So, given your experience of Stata 7, Nick: Did the misplaced
> paranthesis
> somehow end up in the -options- for the -graph- command? The error
> message
> initially reported by Victor in
> http://www.stata.com/statalist/archive/2010-06/msg00133.html would seem
> to
> indicate this sequence of events.
>
> Nick Cox
>
> The first error now seems pretty clear.
>
> The parenthesis ( before lasttime(endfudate) is what is causing the
> error. Delete it.
>
> (You are probably misreading the syntax diagram within which the square
> brackets [ ] group together optional options and are not characters to
> be typed.)
>
> Victor Mauricio Herrera
>
> Regarding the first error, I included no graph options in my
> instructions. This is exactly what I typed:
>
> stgest diabetes cursmoke agebase sex hyperten obese, lagconf(hyperten
> obese diabetes) baseconf(hyperten obese diabetes) /*
> */ visit(visit) firstvis(2) (lasttime(endfudate) range(-50 50) step(1)
> saveres(caergestsmoknocens) replace
>
> I tried with two different datasets and got the same error.
>
>
> *
> * 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/
--
VICTOR M. HERRERA MD. MS.
Research Assistant - Wisconsin Diabetes Registry
Population Health Sciences Department
University of Wisconsin
610 Walnut St. 626 WARF
Madison, WI 53726
(608) 265-3686
*
* 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/