plot.poset | R Documentation |
plot
produces an igraph
object and shows the Hasse diagram.
## S3 method for class 'poset' plot( x, vertex.color = rgb(1, 1, 1, 1), vertex.label = x$pointer$elements(), vertex.label.color = rgb(0, 0, 0, 1), vertex.label.family = "sans", edge.color = rgb(0, 0, 0, 1), edge.label = NA, edge.arrow.mode = "-", asp = 0, ..., equispaced = FALSE, show = TRUE )
x |
an S4 object of class |
vertex.color |
argument of the |
vertex.label |
argument of the |
vertex.label.color |
argument of the |
vertex.label.family |
argument of the |
edge.color |
argument of the |
edge.label |
argument of the |
edge.arrow.mode |
argument of the |
asp |
argument of the |
... |
additional plotting parameters, see |
equispaced |
logical, if |
show |
logical, if |
plot.poset
computes the cover relation and produces the corresponding Directed Acyclic Graph (DAG), as an igraph
object, returned as invisible output.
Function layout_with_sugiyama
generates the DAG layout with edges oriented from top to bottom. When equispaced=TRUE
, nodes on the same Hasse diagram level are horizontally equispaced.
The Hasse diagram is displayed by a call to plot.igraph
(some default argument values are set to get a cleaner plot, by exploiting Hasse diagram properties.
Setting show = FALSE
produces the igraph
object, without showing the Hasse diagram.
Note that
an igraph
object.
poset
, igraph
, igraph.plotting
dom <- matrix(c( "a", "b", "c", "b", "b", "d" ), ncol = 2, byrow = TRUE) p <- poset(x = dom) hasse <- plot(p) class(hasse)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.