I want to test whether kappa is equal to 1 or not.
But I see this error. How can I fix it?
test /kappa = 1
test [kappa] = 1
test /kappa = 1
test [kappa] = 1
test /kappa = 1
test [kappa] = 1
mat list e(b)
. use https://www.stata-press.com/data/r14/cancer
. stset studytime, failure(died)
failure event: died != 0 & died < .
obs. time interval: (0, studytime]
exit on or before: failure
------------------------------------------------------------------------------
48 total observations
0 exclusions
------------------------------------------------------------------------------
48 observations remaining, representing
31 failures in single-record/single-failure data
744 total analysis time at risk and under observation
at risk from t = 0
earliest observed entry t = 0
last observed exit t = 39
. replace drug = drug==2 | drug==3
(28 real changes made)
. streg drug age, distribution(ggamma) nolog
failure _d: died
analysis time _t: studytime
note: drug omitted because of collinearity
Generalized gamma regression -- accelerated failure-time form
No. of subjects = 48 Number of obs = 48
No. of failures = 31
Time at risk = 744
LR chi2(1) = 6.63
Log likelihood = -57.175276 Prob > chi2 = 0.0100
------------------------------------------------------------------------------
_t | Coef. Std. Err. z P>|z| [95% Conf. Interval]
-------------+----------------------------------------------------------------
drug | 0 (omitted)
age | -.0771936 .03141 -2.46 0.014 -.138756 -.0156312
_cons | 7.173099 1.687563 4.25 0.000 3.865537 10.48066
-------------+----------------------------------------------------------------
/ln_sig | -.009931 .2119507 -0.05 0.963 -.4253468 .4054847
/kappa | .2632982 .6947163 0.38 0.705 -1.098321 1.624917
-------------+----------------------------------------------------------------
sigma | .9901181 .2098562 .6535431 1.500029
------------------------------------------------------------------------------
. mat list e(b)
e(b)[1,5]
_t: _t: _t: ln_sig: kappa:
drug age _cons _cons _cons
y1 1.3946577 -.07804164 6.4560907 -.37936318 .46692516
. test [kappa]_cons=1
( 1) [kappa]_cons = 1
chi2( 1) = 1.12
Prob > chi2 = 0.2889
.
Comment