Package for multiple membership model?

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Package for multiple membership model?

Brian Perron
Hello all:  
 
I am interested in computing what the multilevel modeling literature calls a multiple membership model.  More specifically, I am working with a data set involving clients and providers.  The clients are the lower-level units who are nested within providers (higher-level).  However, this is not nesting in the usual sense, as clients can belong to multple providers, which I understand makes this a "multiple membership model."  Right now, I would like to keep this simple, using only a continuous dependent variable, but would like to also extend this to a repeated measures design.  This doesn't seem to be possible with the lme package.  Is there something else I could consider?  
Thanks,
Brian
 

NIMH Training Fellow
GWB School of Social Work, PhD Program
Washington University in St. Louis
One Brookings Drive
St. Louis, MO  63130

        [[alternative HTML version deleted]]

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Reply | Threaded
Open this post in threaded view
|

Re: Package for multiple membership model?

Shige Song
Souds like a model with cross-classified random effects. Lme4 can handle
this easily.

Shige

On 1/3/06, Brian Perron <[hidden email]> wrote:

>
> Hello all:
>
> I am interested in computing what the multilevel modeling literature calls
> a multiple membership model.  More specifically, I am working with a data
> set involving clients and providers.  The clients are the lower-level units
> who are nested within providers (higher-level).  However, this is not
> nesting in the usual sense, as clients can belong to multple providers,
> which I understand makes this a "multiple membership model."  Right now, I
> would like to keep this simple, using only a continuous dependent variable,
> but would like to also extend this to a repeated measures design.  This
> doesn't seem to be possible with the lme package.  Is there something else I
> could consider?
> Thanks,
> Brian
>
>
> NIMH Training Fellow
> GWB School of Social Work, PhD Program
> Washington University in St. Louis
> One Brookings Drive
> St. Louis, MO  63130
>
>         [[alternative HTML version deleted]]
>
> ______________________________________________
> [hidden email] mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide!
> http://www.R-project.org/posting-guide.html
>

        [[alternative HTML version deleted]]

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Reply | Threaded
Open this post in threaded view
|

Re: Package for multiple membership model?

Thomas Lumley
In reply to this post by Brian Perron

On Tue, 3 Jan 2006, Brian Perron wrote:

> Hello all:
>
> I am interested in computing what the multilevel modeling literature
> calls a multiple membership model.  More specifically, I am working with
> a data set involving clients and providers.  The clients are the
> lower-level units who are nested within providers (higher-level).
> However, this is not nesting in the usual sense, as clients can belong
> to multple providers, which I understand makes this a "multiple
> membership model."  Right now, I would like to keep this simple, using
> only a continuous dependent variable, but would like to also extend this
> to a repeated measures design.  This doesn't seem to be possible with
> the lme package.  Is there something else I could consider? Thanks,

I think you want lmer() in the lme4 & Matrix packages. It allows crossed
random effects.

  -thomas

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Reply | Threaded
Open this post in threaded view
|

Re: Package for multiple membership model?

Peter Dalgaard
In reply to this post by Brian Perron
"Brian Perron" <[hidden email]> writes:

> Hello all:  
>  
> I am interested in computing what the multilevel modeling literature
> calls a multiple membership model. More specifically, I am working
> with a data set involving clients and providers. The clients are the
> lower-level units who are nested within providers (higher-level).
> However, this is not nesting in the usual sense, as clients can
> belong to multple providers, which I understand makes this a
> "multiple membership model." Right now, I would like to keep this
> simple, using only a continuous dependent variable, but would like
> to also extend this to a repeated measures design. This doesn't seem
> to be possible with the lme package. Is there something else I could
> consider? Thanks, Brian

You could take a look at the lmer() function in the lme4/Matrix
packages - see the Rnews 2005/1 article. One potential problem is that
for repeated measurements, it is not (currently?) as strong on
correlation structure as lme().

You can actually deal with crossed random effects in lme() too, it
just gets a little more complicated, involving things like

library(nlme)
data(Assay)
as1 <- lme(logDens~sample*dilut, data=Assay,
           random=pdBlocked(list(
                     pdIdent(~1),
                     pdIdent(~sample-1),
                     pdIdent(~dilut-1))))

as2 <- lme(logDens~sample*dilut, data=Assay,
           random=list(Block=pdBlocked(list(
                     pdIdent(~1),
                     pdIdent(~sample-1))),dilut=~1))

as3 <- lme(logDens~sample*dilut, data=Assay,
           random=list(Block=~1,
                     Block=pdIdent(~sample-1),
                     dilut=~1))

which all fit the same model (but get the DF wrong in three different
ways...)

This is slightly different from your example because the crossed
factors are nested in "Block", but you can always fake a nesting using

one <- rep(1, length(logDens)) #or whatever
lme(...., random=list(one=~....))

--
   O__  ---- Peter Dalgaard             Ă˜ster Farimagsgade 5, Entr.B
  c/ /'_ --- Dept. of Biostatistics     PO Box 2099, 1014 Cph. K
 (*) \(*) -- University of Copenhagen   Denmark          Ph:  (+45) 35327918
~~~~~~~~~~ - ([hidden email])                  FAX: (+45) 35327907

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html