maketikz | R Documentation |
Generate Latex tikz code for plotting a temporal DAG or PDAG.
maketikz( model, xjit = 2, yjit = 2, markperiods = TRUE, xpgap = 4, annotateEdges = NULL, addAxis = TRUE, varLabels = NULL, periodLabels = NULL, annotationLabels = NULL, clipboard = TRUE, colorAnnotate = NULL )
model |
|
xjit |
How much should nodes within a period be jittered horizontally. |
yjit |
Vertical distance between nodes within a period. |
markperiods |
If |
xpgap |
Horizontal gap between different periods. |
annotateEdges |
If |
addAxis |
If |
varLabels |
Optional labels for nodes (variables). Should be given as a named list, where
the name is the variable name, and the entry is the label, e.g. |
periodLabels |
Optional labels for periods. Should be given as a named list, where
the name is the period name (as stored in the |
annotationLabels |
Optional labels for edge annotations. Only used if |
clipboard |
If |
colorAnnotate |
Named list of colors to use to mark edge annotations instead of labels. This
overrules |
Note that it is necessary to read in relevant tikz libraries in the
Latex preamble. The relevant lines of code are (depending a bit on parameter settings):
\usepackage{tikz}
\usetikzlibrary{arrows,shapes,snakes,automata,backgrounds,petri}
\usepackage{pgfplots}
Silently returns a character vector with lines of tikz code. The function
furthermore has a side-effect. If clipboard = TRUE
, the side-effect is that the tikz
code is also copied to the clipboard. If clipboard = FALSE
, the tikz code is instead printed
in the console.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.