Properties of a generating class (for defining a graph).
A set of generators define an undirected graph, here called a dependence graph. Given a set of generators it is checked 1) if the dependence dependence graph is in 1-1-correspondance with the genrators (such that the corresponding model is graphical) and 2) if the dependence graph is chordal (triangulated) (such that the corresponding model is decomposable).
isGraphical(x) isDecomposable(x)
x |
A generating class given as right hand sided formula or a list; see 'examples' below. |
A set of sets of variables, say A_1, A_2, ... A_K is called a generating class for a graph with vertices V and edges E. If two variables a,b are in the same generator, say A_j, then a and b are vertices in the graph and there is an undirected edge between a and b.
The graph induced by g1 = ~a:b + a:c + b:c + c:d
has
edges ab, ac, bc, cd
. The
cliques of this graph are abc, cd
. Hence there is not a
1-1-correspondance between the graph and the generators.
On the other hand, g2 <- ~a:b:c + c:d
induces the same
graph in this case there is a 1-1-correspondance.
The graph induced by g3 <- ~a:b + b:c + c:d + d:a
is in
1-1-correspondance with its dependence graph, but the graph is
not chordal.
TRUE or FALSE
Søren Højsgaard, sorenh@math.aau.dk
g1 <- ~a:b + a:c + b:c + c:d g2 <- ~a:b:c + c:d g3 <- ~a:b + b:c + c:d + d:a isGraphical( g1 ) # FALSE isGraphical( g2 ) # TRUE isGraphical( g3 ) # TRUE isDecomposable( g1 ) # FALSE isDecomposable( g2 ) # TRUE isDecomposable( g3 ) # TRUE ## A generating class can be given as a list: f <- list(c("a","b"), c("b","c"), c("a","c")) isGraphical( f ) isDecomposable( f )
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.