Skip to content

Mixed effects model with a distance matrix as a random effect

3 messages · Roey Angel, Jonas Klasen, Steven J. Pierce

#
Hi Roey,
do you mean as Z-matrix or as var-covar relationship matrix? For the 
later see lmekin (coxme package). There you can specify a similarity 
matrix (K) for a random effect (u):
u ~ N(0, sigma_u^2 K)

or one of the following packages: regress, rrBLUP, EMMA 
(http://mouse.cs.ucla.edu/emma/)

Bests
Jonas
On Tue 04 Jun 2013 02:46:13 PM CEST, Roey Angel wrote:
--
__________________________________________________

 Jonas Klasen
 PhD student
 Genome Plasticity and Computational Genetics
 Max Planck Institute for Plant Breeding Research
#
You could also consider using a geostatistical model such as found in the
spBayes package. 

Steve 


-----Original Message-----
From: Roey Angel [mailto:angel at mpi-marburg.mpg.de] 
Sent: Tuesday, June 04, 2013 8:46 AM
To: r-sig-mixed-models at r-project.org
Subject: [R-sig-ME] Mixed effects model with a distance matrix as a random
effect

Hi,
I'm trying to build a mixed-effects model in which I'd like to include
either a distance matrix as a random effect.
The troubles I've had are that function lmer() in package lme4 only accepts
a data frame column as a random factor and not a distance matrix.

Is there a way around it?

Thanks in advance
Roey