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

st: Re: Re: confidence interval


From   dr kardos l�szl� <[email protected]>
To   <[email protected]>
Subject   st: Re: Re: confidence interval
Date   Tue, 20 Jan 2004 14:49:44 +0100

victor michael zammit:
>mpg       Coef. Std. Err.       t P>t [95% Conf. Interval]
>
>weight   -.0058175 .0006175     -9.421 0.000 -.0070489 -.0045862
>price   -.0000935 .0001627     -0.575 0.567 -.000418 .0002309
>_cons    39.43966 1.621563     24.322 0.000 36.20635 42.67296
>
>
>can any one please tell me how I could retrieve the lower bound and the
>upper bound for 95% and 99% confidence intervals ?

>Yes. You can use the -parmest- package...


parmest sounds great, yet victor may want to retrieve the ci bounds more
directly. if he utilizes the general formula

u/lbound = point_estimate +/- z*se

(substitute z with the key deviant of the relevant distribution and the ci
width of your choice),

and the way to access estimation results in stata ([U] 21.9), he can go, e.g

di "upper bound: " _b[weight]-invttail(e(df_r),.975)*_se[weight]

or assign the result thereof to a local macro, etc.


note that -invttail- gives a negative result where some might expect a
positive one, hence a subtraction is called for when calculating the upper
bound. with other regressions using the z statistics, it is simpler as you
can use -invnorm(p)- which gives a positive deviant and involves no hassle
with the degrees of freedom. other listers please correct me if e(df_r) is
not the one really used in the above calculation - it is quite empirical
from my part but has so far seemed to work.

laszlo

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