Re: [R] Sample or Probability Weights in LM4, NLME (and PLM) package

From: Thomas Lumley <tlumley_at_uw.edu>
Date: Fri, 11 Mar 2011 11:58:23 +1300

On Fri, Mar 11, 2011 at 11:07 AM, Arne Jonas Warnke <arne.warnke_at_googlemail.com> wrote:
> Dear all,
>
>
>
> First, I would like to thank you for your immense work. My question is
> about a frequent topic which I am not able to solve - even after hours
> of search in the mailing lisy.
>
> I would like to analyse random-effects (and fixed-effects)models of
> longitudinal / panel data with sampling weights. I have an unbalanced
> panel of different individuals in 5 years and income data as well as
> their age and I would like to analyse age-earnings profiles with
> longitudinal data to controll for cohort effects.

This is doable in theory, since the random effects structure is nested in the sampling design, but not in any R package I am aware of. The problem is that you can't just put in one set of weights -- in order to get the variance components correct, you need to put in separate weights for each level of sampling and random effect. So whatever lme() does can't be correct for sampling weights, since it allows for only one set of weights

<snip>
> Are you aware of any other packages in R which provide the opportunity
> to examine longitudinal data with sample weights?

If you aren't specifically interested in estimating the variance components, just in using longitudinal data to estimate the regression, you can just use design-based inference for a linear regression model, with svyglm() in the 'survey' package.

If you want estimates of the variance components you may be out of luck.

    -thomas

-- 
Thomas Lumley
Professor of Biostatistics
University of Auckland

______________________________________________
R-help_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Received on Thu 10 Mar 2011 - 23:00:54 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Fri 11 Mar 2011 - 00:20:21 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive