| |
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]
Re: st: stcox: weighted regression changes the # of observations
From |
[email protected] (Jeff Pitblado, StataCorp LP) |
To |
[email protected] |
Subject |
Re: st: stcox: weighted regression changes the # of observations |
Date |
Fri, 01 Dec 2006 11:01:04 -0600 |
Michael McCulloch <[email protected]>
> I'm conducting cox regression on a dataset measuring survival after
> treatment. I'm puzzled as to why weighted regression (using -iweight-
> after -stcox-) would show a different # of observations in the output. Here
> are results of the ways I've done the analysis. In each case, I start with
> only 33 subjects.
>
> (output omitted)
As documented in '[U] 11.1.6 weights'
iweights, or importance weights, are weights that indicate the
"importance" of the observation in some vague sense. iweights have no
formal statistical definition; any command that supports iweights will
define exactly how they are treated. In most cases, they are intended
for use by programmers who want to produce a certain computation.
However -iweight-s are usually treated computationally as -fweight-s that are
allowed to take on non-integer values. For commands that have that
interpretation, the sum of the weights is treated as the sample size. I
believe most of Stata's estimation commands that allow -iweight-s (including
-stcox-) are consistent in this regard.
> *Note: I'm using inverse probability of treatment weighting, with the
> following command immediately preceding -stcox-:
> stset datedied [iweight=wt_unst_II]
-bootstrap- is not meant for weighted data. Currently -stcox- with the
-vce(bootstrap)- option does not complain when weights have been -stset, but
it should (we will fix this soon).
> Another anomaly is why the bootstrap option yields a narrower ci95.
Standard errors from the bootstrap are not guaranteed to be larger than
the conventionally computed standard errors.
--Jeff
[email protected]
*
* 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/