I'm creating some graphs for my thesis in a single .tex
file using the TikZ package in LaTeX.
I'm using the standalone document class so that my graphs are generated without whitespaces.
How can I export every graph in a separate PDF file so I can load them individually in another project?
The tikz library external does just what you want:
\usetikzlibrary{external}
\tikzexternalize
It will generate one PDF per tikzpicture
. You can define an output directory with:
\tikzexternalize[prefix=./dir]