Class dg.graph

Description

The representation of a graph for dynamicGraph. Vertices, blocks, viewType, edges, etc. are here the dynamicGraph objects.

Usage

1
2
3
dg(object, 

   ...)

Arguments

object

The graph.

...

Additional arguments.

Objects from the Class

Objects can be created by calls of the form new("dg.graph", ...).

Slots

vertexList:

Object of class "dg.VertexList": List of vertices (each of class containing the class dg.Vertex) created by returnVertexList or exported from dynamicGraphMain.

blockList:

Object of class "dg.BlockList": List of blocks (each of class dg.Block) created by setBlocks or exported from dynamicGraphMain.

viewType:

Object of class "character", See dg.graphedges-class.

visibleVertices:

Object of class "numeric", See dg.graphedges-class.

visibleBlocks:

Object of class "numeric", See dg.graphedges-class.

oriented:

Object of class "logical", See dg.graphedges-class.

edgeList:

Object of class "dg.VertexEdgeList", See dg.graphedges-class.

blockEdgeList:

Object of class "dg.BlockEdgeList", See dg.graphedges-class.

factorVertexList:

Object of class "dg.FactorVertexList", See dg.graphedges-class.

factorEdgeList:

Object of class "dg.FactorEdgeList", See dg.graphedges-class.

extraList:

Object of class "dg.VertexList", See dg.graphedges-class.

extraEdgeList:

Object of class "dg.ExtraEdgeList", See dg.graphedges-class.

Extends

Class "dg.graphedges", directly.

Methods

coerce

signature(from = "dg.simple.graph", to = "dg.graph"): ...

dg

signature(object = "dg.graph"): ...

addModel

signature(object = "dg.graph"): ...

addView

signature(object = "dg.graph"): ...

replaceModel

signature(object = "dg.graph"): ...

replaceView

signature(object = "dg.graph"): ...

Author(s)

Jens Henrik Badsberg

See Also

dg.simple.graph-class, and dynamicGraphMain.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
from <- c("contry", "contry", "race", "race",       "sex",  "sex")
to   <- c(   "sex",   "race", "hair",  "eye", "education",  "age")
vertexnames <- unique(sort(c(from, to)))
vertices <- returnVertexList(vertexnames)
edge.list <- vector("list", length(to))
for (j in seq(along = to)) edge.list[[j]] <- c(from[j], to[j])
edges <- returnEdgeList(edge.list, vertices, color = "red", oriented = TRUE)

graph <- new("dg.graph", vertexList = vertices, edgeList = edges); str(graph)
dg(graph)

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.