1. Installation guide¶
1.1. Dependencies¶
The following software and modules are required to run dot2tex:
- Python 2.7 or 3.x.
- pyparsing. Version 1.4.8 or later is recommended.
- Graphviz. A recent version is required.
- preview. A LaTeX package for extracting parts of a document. A free-standing part of the preview-latex/AUCTeX bundle.
- PGF/TikZ version 2.0 or later.
Users have reported problems using dot2tex with old versions of pyparsing and Graphviz.
A natural companion to dot2tex is the dot2texi LaTeX package for embedding graphs directly in your LaTeX source code.
1.2. Using pip or easy_install¶
The easiest way to install dot2tex is to use pip (recommended) or easy_install:
$ pip install dot2tex
or easy_install:
$ easy_install dot2tex
If you are on Linux or Mac OS X you may have to call pip or easy_install using sudo
:
$ sudo pip install dot2tex
The commands will locate dot2tex and download it automatically. Note that documentation and examples are not installed by default. Pip and easy_install will also create a wrapper script or EXE file for you and install dependencies if necessary.
1.4. From source¶
Download a zip or a tarball from the download page. Unpack the file to a directory and run python
on the setup.py
file:
$ python setup.py install
This will create a dot2tex module in your Python modue directory and a wrapper script in your SCRIPTS
directory. Note that a few warnings will be displayed. You can safely ignore them. The warnings are shown because there is some extra information in the setup.py
file that distutils does not understand.
1.5. Development version¶
The development version of dot2tex
is hosted on GitHub. To get the code you can use the following command:
git clone https://github.com/kjellmf/dot2tex.git