Description Usage Arguments Details Value Note Author(s) References See Also Examples
Create an object of class "mathgraph"
which represents a
mathematical graph.
1 2 3 4 5 6 7 | mathgraph(formula, directed = FALSE, data = sys.parent())
## S3 method for class 'mathgraph'
length(x)
## S3 method for class 'mathgraph'
c(...)
is.mathgraph(x)
|
formula |
a formula containing just the right-side. |
directed |
logical flag: if |
data |
the frame in which to find objects referenced in the formula. This can be either the number of a memory frame, or a list or data frame containing the data. |
... |
objects to be concatenated. |
x |
object of class |
Mathematical graphs consist of a set of nodes (vertices) and edges. Edges go between two nodes. An edge that is directed is often called an arc.
Terms in the formula (delimited by +
)
may be either calls to *
or /
, or objects that
are already of class "mathgraph"
.
Two other representations of graphs are adjacency matrices and incidence
matrices.
The functions to convert "mathgraph"
objects to these
are adjamat
and incidmat
, respectively.
Most algorithms for mathematical graphs are in terms of incidence matrices
or adjacency matrices.
The generic functions that have a method for class "mathgraph"
include:
[
, c
, length
, names
, plot
, print
,
unique
.
is.mathgraph
is the membership function for this class.
an object of class mathgraph
which is a two-column matrix of nodes
along with an additional attribute called "directed"
which is a
logical vector stating whether or not each edge is directed.
An edge (row of the matrix) that is directed goes from the node in the first
column to the node in the second column.
S Poetry, Patrick J. Burns, http://www.burns-stat.com/pages/spoetry.html
Nick Efthymiou
Chachra, V., Ghare, P. M. and Moore, J. M. (1979). Applications of Graph Theory Algorithms. Elvesier North Holland, New York.
1 2 3 4 5 6 7 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.