[R-sig-ME] incorporating a kinship matrix
Pelle Ingvarsson
par.ingvarsson at emg.umu.se
Thu Mar 11 16:55:09 CET 2010
Hi,
I'm trying to replicate the behavior of the lmekin function from the
kinship package with lmer. So far I have arrived at the pedigreemm
function, but I'm still not at the point where I want to go.
My basic problem is as follows:
With lmekin I can incorporate an arbitrary kinship matrix into the
calculations (ie. not based on a known pedigree, but estimates using
genetic markers) , which is useful if you're working with species where
you don't have pedigree information (which I happen to do).
The "problem" right now is that I have multiple observations from the
same (cloned) genotype that I would like to include into my modeling
effort. I have previously handled this by calculating BLUPs for each
genotype and have used these BLUPs in the lmekin analyses. However,
treating the BLUPs observed variables seems a little like cheating since
a potentially substantial source of variation (variation among
replicate measures of each clone) just gets "eliminated" in the process
of calculating the BLUPs.
However, including multiple observations of the same genotype is not
possible in lmekin, where only a single observation is allowed per entry
in the kinship matrix. Running a model with multiple observations per
genotype results in:
lmekin(budset~year+site+pos,data=bs,random=~1|clone,varlist=list(2*K),rescale=TRUE)
Error in lmekin(budset ~ year + site + pos, data = bs, random = ~1 |
clone, : The random effect must be 1 per subject
(note: where K is the nxn kinship matrix, where n in the number of
observed genotypes):
I have tried to fit such a model using lmer/pedigreemm, which I hoped
would be able to do that, but I have not succeeded yet. It appears that
including a kinship matrix directly is not an option in pedigreemm, have
I understood that correctly? I know I can fit a model like this using
ASREML, but I would prefer to stick to open source software (and R) if
possible.
Any ideas or helpful pointers would be very much appreciated.
Sincerely,
-Pelle
More information about the R-sig-mixed-models
mailing list