graph-gcproperties: Properties of a generating class (for defining a graph).

Description Usage Arguments Details Value Author(s) See Also Examples

Description

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).

Usage

1
2
3

Arguments

x

A generating class given as right hand sided formula or a list; see 'examples' below.

Details

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.

Value

TRUE or FALSE

Author(s)

Søren Højsgaard, sorenh@math.aau.dk

See Also

mcs, rip

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
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 )

DataSciBurgoon/gRbase documentation built on March 25, 2020, 12:03 a.m.