View source: R/parsec2igraph.R
parsec2igraph | R Documentation |
igraph
.
The function turns a cover matrix to an igraph
object, so as to allow using the graphical power of igraph
to plot Hasse diagrams. Objects of class cover
are boolean matrices where element ij is equal to 1 if element i is covered by element j. This makes the cover matrix the transpose of the adjacency matrix of a graph, describing the cover relation in igraph
.
parsec2igraph(p, ...)
## S3 method for class 'cover'
parsec2igraph(p, ...)
## S3 method for class 'incidence'
parsec2igraph(p, ...)
p |
an object of class |
... |
additional arguments of the function |
The function returns an object of class igraph
, representing the directed graph defined by the cover relation.
The function adds to the graph a layout generated through function vertices
, so as to plot the graph according to the conventions used for Hasse diagrams.
Arcagni, A.
Csardi G, Nepusz T: The igraph software package for complex network research, InterJournal, Complex Systems 1695. 2006. http://igraph.org
igraph
, vertices
example(merge.wprof)
poset <- getzeta(distribution)
incidence2cover(poset)
G <- parsec2igraph(poset, noise = TRUE)
get.adjacency(G)
# tkplot(G, vertex.size = distribution$freq, vertex.color = "white")
G <- parsec2igraph(poset, noise = 10)
# tkplot(G, vertex.size = distribution$freq, vertex.color = "white")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.