Calculates -2*log-likelihood, AIC, and BIC for a triangulated graph (decomposable model).
Usage
fit(model=NULL, edges=NULL, dataset, homog=NULL)
Arguments
model
gRapHD object.
edges
matrix with 2 columns, each row representing one edge, and each
column one of the vertices in the edge.
dataset
matrix or data frame (nrow(dataset) observations and
ncol(dataset) variables).
homog
only used in the mixed model case. TRUE if the model is
homogeneous. The default is NULL, indicating that the
attribute homog of the model parameter must be
used (or TRUE if only edges is provided).
Value
Vector with: model dimension (no of free parameters), -2*log-likelihood, AIC, and BIC. Note that
all parameters are assumed to be estimable in the dimension calculation.
References
Lauritzen, S.L. (1996) Graphical Models, Oxford University Press.