AgEdge-class: Class "AgEdge": A class to describe an edge for a Ragraph...

AgEdge-classR Documentation

Class "AgEdge": A class to describe an edge for a Ragraph object

Description

This class is used to represent edges for the Ragraph class. One can retrieve various pieces of information as well as draw them.

Objects from the Class

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

Slots

arrowhead:

Object of class "character" The style of arrowhead for this edge.

arrowsize:

Object of class "character" A scale factor for the length of the arrow heads & tails

arrowtail:

Object of class "character" The style of arrowtail for this edge.

color:

Object of class "character" The edge color.

dir:

Object of class "character" The edge direction.

ep:

Object of class "xyPoint" The end point of the edge.

head:

Object of class "character" The head node for this edge.

lty:

Object of class "character" The edge line type.

lwd:

Object of class "numeric" The edge line width.

sp:

Object of class "xyPoint" The starting point of the edge.

splines:

Object of class "list" A list of BezierCurve objects

tail:

Object of class "character" The tail node for this edge.

txtLabel:

Object of class "character" The edge text label.

Methods

splines

Returns the splines slot

sp

Returns the sp slot

ep

Returns the ep slot

numSplines

Returns the number of splines

getSpline

Convenience method to retrieve a specific spline

show

Displays a concise description of the object

lines

Draws the edge

head

Gets the head slot

tail

Gets the tail slot

txtLabel

Returns any label for this edge

arrowhead

Retrieves the arrowhead slot.

arrowtail

Retrieves the arrowtail slot.

arrowsize

Retrieves the arrowsize slot.

Author(s)

Jeff Gentry

See Also

Ragraph, BezierCurve, xyPoint

Examples

V <- letters[1:10]
M <- 1:4
g1 <- randomGraph(V, M, .2)
z <- agopen(g1,name="foo")
x <- AgEdge(z)  ## list of AgEdge objects

vv <- x[[1]]
vv
## Demonstrate the methods of this class
splines(vv)
sp(vv)
ep(vv)
numSplines(vv)
getSpline(vv, 1)
head(vv)
tail(vv)
txtLabel(vv)
arrowhead(vv)
arrowtail(vv)
arrowsize(vv)


kasperdanielhansen/Rgraphviz documentation built on Nov. 4, 2022, 4:14 a.m.