Description Usage Arguments Examples
The function returns the LaTeX code to create an article containing a figure that represents the Hasse diagram obtained form a set of profiles (prof
), an incidence matrix (Z
) or a cover matrix (C
). The code can be copied and pasted to a tex
file. The tex
source requires the tikz
package,
1 2 3 4 5 6 7 |
y |
an object of S3 class |
label |
the label of the LaTeX figure. |
caption |
the caption of the LaTeX figure. |
scale |
a vector of two elements to control the scale of the X-axis and the scale of the Y-axis in the LaTeX output. |
... |
any of above. |
1 2 |
Loading required package: igraph
Attaching package: 'igraph'
The following objects are masked from 'package:stats':
decompose, spectrum
The following object is masked from 'package:base':
union
Loading required package: netrankr
Attaching package: 'parsec'
The following objects are masked from 'package:igraph':
transitivity, vertices
\documentclass{article}
\usepackage{tikz}
\tikzstyle{node}=[circle, draw, fill=white, inner sep=1pt, minimum width=1pt]
\begin{document}
\begin{figure}[!h]
\label{fg:hasse}
\centering
\begin{tikzpicture}[scale=1.2]
\node(1) at (0,-2)[node]{11};
\node(2) at (1.33333333333333,-0.666666666666667)[node]{21};
\node(3) at (-1.33333333333333,-0.666666666666667)[node]{12};
\node(4) at (1.33333333333333,0.666666666666667)[node]{22};
\node(5) at (-1.33333333333333,0.666666666666667)[node]{13};
\node(6) at (0,2)[node]{23};
\draw[-, very thin] (1) to (2);
\draw[-, very thin] (1) to (3);
\draw[-, very thin] (2) to (4);
\draw[-, very thin] (3) to (4);
\draw[-, very thin] (3) to (5);
\draw[-, very thin] (4) to (6);
\draw[-, very thin] (5) to (6);
\end{tikzpicture}
\caption{Hasse diagram}
\end{figure}
\end{document}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.