| e.step {LCAextend} | R Documentation |
performs the E step of the EM algorithm for a single pedigree for both cases with and without familial dependence
Description
computes triplet and individual weights the E step of the EM algorithm for all pedigrees in the data, in both cases with and without familial dependence. This is an internal function not meant to be called by the user.
Usage
e.step(ped, probs, param, dens, peel, x = NULL, var.list = NULL,
famdep = TRUE)
Arguments
ped |
a matrix representing pedigrees and measurements: |
probs |
a list of probability parameters of the model, see below for more details, |
param |
a list of measurement distribution parameters of the model, see below for more details, |
dens |
distribution of the mesurements, used in the model (multinormal, multinomial,...) |
peel |
a list of pedigree peeling containing connectors by peeling order and couples of parents, |
x |
covariates, if any. Default is |
var.list |
a list of integers indicating which covariates (taken from |
famdep |
a logical variable indicating if familial dependence model is used or not. Default is |
Details
probs is a list of initial probability parameters:
For models with familial dependence:
pa probability vector, each
p[c]is the probability that an symptomatic founder is in classcforc>=1,p0the probability that a founder without symptoms is in class 0,
p.transan array of dimension
KtimesK+1timesK+1, whereKis the number of latent classes of the model, and is such thatp.trans[c_i,c_1,c_2]is the conditional probability that a symptomatic individualiis in classc_igiven that his parents are in classesc_1andc_2,p0connecta vector of length
K, wherep0connect[c]is the probability that a connector without symptoms is in class0, given that one of his parents is in classc>=1and the other in class 0,p.foundthe probability that a founder is symptomatic,
p.childthe probability that a child is symptomatic,
For models without familial dependence, all individuals are independent:
pa probability vector, each
p[c]is the probability that an symptomatic individual is in classcforc>=1,p0the probability that an individual without symptoms is in class 0,
p.affthe probability that an individual is symptomatic,
param is a list of measurement density parameters: the coefficients alpha (cumulative logistic coefficients see alpha.compute) in
the case of discrete or ordinal data, and means mu and variances-covariances matrices sigma in the case of continuous data,
Value
The function returns a list of 3 elements:
ww |
triplet posterior probabilities, an array of |
w |
individual posterior probabilities, an array of |
ll |
log-likelihood of the considered model and parameters. |
References
TAYEB et al.: Solving Genetic Heterogeneity in Extended Families by Identifying Sub-types of Complex Diseases. Computational Statistics, 2011, DOI: 10.1007/s00180-010-0224-2.
See Also
See also weight.famdep, lca.model.
Examples
#data
data(ped.cont)
data(peel)
#probs and probs
data(probs)
data(param.cont)
#the function
e.step(ped.cont,probs,param.cont,dens.norm,peel,x=NULL,var.list=NULL,
famdep=TRUE)