Bookmark and Share

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: means compairison with weights and unequal variance


From   Barbro Widerstedt <[email protected]>
To   [email protected]
Subject   Re: st: means compairison with weights and unequal variance
Date   Wed, 23 Nov 2011 14:07:31 +0100

Paul,

In this case, the sample is "average weighted" rather than population
weighted. Weights are used to compensate for differences in group
sizes, which is due to the number of twins found in the sample.


Each treated case has 1 -- n twins and estimates are compared with an
"average"  for the untreated. The paper (Iacus et al (2009), cem:
Coarsened Exact Matching in Stata, Stata Journal 9(4), pp 524-546)
recommends aweights or iweights (which I am not really sure what they
are) . I'm fairly confident about this ...

/Barbro



On Wed, Nov 23, 2011 at 11:29 AM, Seed, Paul <[email protected]> wrote:
> Barbro,
>
> With a weighted sample, -pweight- should be used, not -aweight-.
>
> The adjustment for -aweight- assumes that each given value is
> actually the average of several separate observations; for a weighted
> sample, this assumes too large a sample size, and too small standard errors.
> -pweight- gives the same estimates, but adjusts the standard errors appropriately.
>
> The section in the manuals about weightings make this all clear.
>
> However, there may be special circumstances surrounding -cem-.
>
> BW
>
> Paul T Seed, Senior Lecturer in Medical Statistics,
> King's College London, Division of Women's Health
>
>
> On Mon, Nov 21, 2011 at 7:45 PM, Ariel Linden, DrPH
> <[email protected]> wrote:
>> Why not simply use -regress- and the weight generated in -cem- (cem_weights)
>> as the aweight with robust se? This is the approach suggested by the
>> authors. See:
>>
>> Stefano M. Iacus, Gary King, and Giuseppe Porro, "Matching for Causal
>> Inference Without Balance Checking", copy at
>> <http://gking.harvard.edu/files/abs/cem-abs.shtml>
>>
>> Ariel
>>
>>
>>
>> Date: Sun, 20 Nov 2011 21:40:40 -0800
>> From: John Luke Gallup <[email protected]>
>> Subject: Re: st: means compairison with weights and unequal variance
>>
>> Barbro,
>>
>> A simple alternative is to calculate the means and standard deviations for
>> each group using -summarize- with weights, and then run -ttesti ...,
>> unequal-:
>>
>> sysuse auto, clear
>>
>> sum mpg if foreign [aw=weight]
>> local N1 = r(N)
>> local av1 = r(mean)
>> local sd1 = r(sd)
>>
>> sum mpg if !foreign [aw=weight]
>> local N2 = r(N)
>> local av2 = r(mean)
>> local sd2 = r(sd)
>>
>> ttesti `N1' `av1' `sd1' `N2' `av2' `sd2', unequal
>>
>> John
>>
>> John Luke Gallup
>> Department of Economics
>> Portland State University
>>
>> On Nov 20, 2011, at 2:13 AM, appoloniak wrote:
>>
>>> Hello statslisters,
>>>
>>> [caveat: sorry if this is a FAQ, but sometimes my imagination in
>>> creating queries for use in the archives gives me nothing... and it is
>>> more of a statistics that a Stata question, so please don't hit me too
>>> hard ... ]
>>>
>>> I have a dataset where I try to compare the means of a variable
>>> between two groups (treated and untreated).
>>> The data set used is a sample, drawn from the superpopulation by the
>>> ado-package cem (Iaucus et al Coarsened enhanced mathing), and
>>> subsequent estimations should be weighted.
>>>
>>> This means that a standard t-test cannot be used, and I searched a bit
>>> and found that <oneway> is an alternative with weighted data. However,
>>> the groups have unequal variance which is a problem for <oneway> (at
>>> least I think so, I know ANOVA mainly by name ...). I read one entry
>>> that suggests that oneway is robust to  groupwise unequal  variance if
>>> groupsize does not vary too much, but in my case they do (min
>>> groupsize=2 max groupsize=1273)
>>>
>>> ttest <outcome>, by(treatvar) unequal -> t = -2.43
>>> oneway <outcome> <treatvar> [aweight=cem_weight] -> F=4.06
>>>
>>> both bartlett's test for equality of variance,  a standard sdtest ,
>>> and robvar suggest that I have unequal variance between groups.
>>>
>>> Suggestion on alternatives would be greatly appreciated
>>>
>>> /Barbro Widerstedt
>>
>>
>> *
>> *   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/
>>
> *
> *   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/
>

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


© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index