Chris Stride
2018-Jun-16 11:00 UTC
[R] specifying random effects covariance structure in nlme
Hi I'm trying to fit a mixed effects exponential decay model, in which I have random effects for the initial value (init), the asymptote (asymp), and the rate (rate). The catch is that I'd also like to estimate the correlation between init and asymp, but not between init and rate, or asymp and rate. Now using? random = pdDiag(init + asymp + rate ~ 1) has none of the random effects correlated And using? random = pdSymm(init + asymp + rate ~ 1) has all three of the random effects correlated How do I specify just the correlation I want? cheers Chris
Peter Dalgaard
2018-Jun-16 13:18 UTC
[R] specifying random effects covariance structure in nlme
I haven't played with this for a decade or so, but I believe you can do something with pdBlocked(). Possibly ask over on R-sig-ME as this quickly gets beyond the R-help level. (Also, you are aware that it is not about what you want to estimate, but whether you believe the correlations are nonzero?) -pd> On 16 Jun 2018, at 13:00 , Chris Stride <c.b.stride at sheffield.ac.uk> wrote: > > Hi > > I'm trying to fit a mixed effects exponential decay model, in which I have random effects for the initial value (init), the asymptote (asymp), and the rate (rate). > > The catch is that I'd also like to estimate the correlation between init and asymp, but not between init and rate, or asymp and rate. > > Now using random = pdDiag(init + asymp + rate ~ 1) has none of the random effects correlated > > And using random = pdSymm(init + asymp + rate ~ 1) has all three of the random effects correlated > > How do I specify just the correlation I want? > > cheers > > Chris > > ______________________________________________ > R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see > 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.-- Peter Dalgaard, Professor, Center for Statistics, Copenhagen Business School Solbjerg Plads 3, 2000 Frederiksberg, Denmark Phone: (+45)38153501 Office: A 4.23 Email: pd.mes at cbs.dk Priv: PDalgd at gmail.com