dg.BlockEdge-class {dynamicGraph}R Documentation

Class "dg.BlockEdge"

Description

The class for edges between blocks and for edges between vertices and blocks.

Usage

newBlockEdge(node.indices, nodes = NULL, width = 2,
             color = "DarkOliveGreen", oriented = TRUE, type = NULL,
             label = ifelse(is.null(nodes), "",
                            paste(Labels(nodes), collapse = "~")),
             dash = "")

Arguments

node.indices Vector with abs(node.indices) the indices of the nodes of the block edge. If the index is positiv then the node is a vertex, else it is a block.
nodes List with the nodes of the block edge. Used for setting the default label.
width Numeric for the width of the block edge.
color Text string with the color of the block edge.
oriented Logical. If TRUE then the block edge is oriented.
type Text string with the type of the block edge.
label Text string with the label of the block edge.
dash Text string for the color pattern of the edge.

Details

The function is used in returnBlockEdgeList. dynamicGraphMain will automatic update block edges when vertices are moved between blocks.

Slots

oriented:
Object of class "logical", see "dg.VertexEdge".
vertex.indices:
Object of class "numeric", see "dg.Edge".
width:
Object of class "numeric", see "dg.Edge".
dash:
Object of class "character", see "dg.Edge".
color:
Object of class "character", see "dg.Edge".
label:
Object of class "character", see "dg.Edge".
label.position:
Object of class "numeric", see "dg.Edge".

Extends

Class "dg.Edge", directly. Class "dg.Node", by class "dg.Edge".

Methods

nodeTypesOfEdge
signature(object = "dg.BlockEdge"): Extract the types ("super classes": "Vertex" or "Block") of the vertices (nodes) of the edge.
oriented<-
signature(x = "dg.BlockEdge"): ...
oriented
signature(object = "dg.BlockEdge"): ...

Note

The methods of dg.Edge also applies for dg.BlockEdge.

Author(s)

Jens Henrik Badsberg

See Also

returnBlockEdgeList, dg.Edge-class.

Examples

 
vertices <- returnVertexList(paste("V", 1:4, sep = ""))
block <- newBlock(stratum = 1)
blockedge <- newBlockEdge(c(4, -1), 
                          new("dg.VertexList", list(vertices[[1]], block)))

str(blockedge)

color(blockedge)
label(blockedge)
labelPosition(blockedge)
width(blockedge)
nodeIndicesOfEdge(blockedge)
nodeTypesOfEdge(blockedge)

color(blockedge) <- "Black"
label(blockedge) <- "V1~1"
labelPosition(blockedge) <- c(0, 1, 2)
width(blockedge) <- 1
nodeIndicesOfEdge(blockedge) <- c(1, -1)

str(blockedge)

[Package dynamicGraph version 0.1.7.0 Index]