| dg.Block-class {dynamicGraph} | R Documentation |
The class for the blocks.
stratum:"numeric",
the stratum of the block. index:"numeric"
with (minus) the index of the block,
the position of the block in a block list. parent:"numeric"
with the single parent of the block.
The slots children, ancestors,
and descendants are computed from parent.
When conflicts between these four slots in
dynamicGraphMain
the tree other slots are computed from parent. children:"numeric"
Integer vector for the children blocks of the block. ancestors:"numeric".
Integer vector for the ancestor blocks of the block.
The slots with the children and descendant blocks is set
after the creation of the block (in setTreeBlocks). descendants:"numeric".
Integer vector for the descendants blocks of the block.
The slot with the descendant blocks
is set after the creation of the block. position:"matrix",
the position of the block, the two diagonal opposite corners. closed:"logical",
if TRUE then the block is closed, e.i. drawn as a "vertex". visible:"logical",
if TRUE then the block is drawn, else it is hidden in a closed block. color:"character",
see "dg.Node". label:"character",
see "dg.Node". label.position:"numeric",
see "dg.Node".
Class "dg.Node", directly.
signature(x = "dg.Block"): ... signature(object = "dg.Block"): ... signature(x = "dg.Block"): ... signature(object = "dg.Block"): ... signature(x = "dg.Block"): ... signature(object = "dg.Block"): ... signature(x = "dg.Block"): ... signature(object = "dg.Block"): ... signature(object = "dg.Block"):
Method for drawing the closed block. signature(x = "dg.Block"): ... signature(object = "dg.Block"): ... signature(.Object = "dg.Block"): ... signature(object = "dg.Block"):
Extract the label of the block. signature(x = "dg.Block"): ... signature(object = "dg.Block"): ... signature(x = "dg.Block"): ... signature(object = "dg.Block"): ... signature(x = "dg.Block"): ... signature(object = "dg.Block"): ... signature(x = "dg.Block"): ... signature(object = "dg.Block"): ...
The dg.Block class has the methods
name, label, labelPosition,
position, color, stratum,
index, visible, closed,
parent, children,
ancestors, and descendants,
for extracting values
and the replacement methods
label<-, labelPosition<-,
position<-, color<-, stratum<-,
index<-, visible<-, closed<-,
parent<-, children<-,
ancestors<-, and descendants<-.
Items are added to the pop up menu of a block
by the method addToPopups.
The methods draw,
and propertyDialog is also avaliable.
Jens Henrik Badsberg
setBlocks,
setTreeBlocks,
dg.Node-class.
b <- new("dg.Block")
str(b)
color(b)
label(b)
labelPosition(b)
name(b)
index(b)
position(b)
stratum(b)
ancestors(b)
descendants(b)
visible(b)
color(b) <- "grey"
label(b) <- "NameAndLabel"
labelPosition(b) <- c(1, 2, 3)
# name(b) <- "NameAndLabel" # Not possible!!!
index(b) <- 3
position(b) <- matrix(c( 10, 20, 30, 40,
110, 120, 130, 140), byrow = TRUE, ncol = 4)
stratum(b) <- 1
ancestors(b) <- c(1, 2)
descendants(b) <- c(4, 5)
visible(b) <- FALSE
str(b)