gxhints - Graphics conversion hints Wiki
Hints for graphics conversion, gxhconvert script
Brought to you by:
kraused
← TOC | ↑ Home | Gnuplot | → | TeX | TeX | EPS | SVG | PNG | JPEG |
This page shows how to convert a Gnuplot file named x.gp to PDF.
set terminal ... set output ...in Gnuplot files you want to use with gxhconvert.
## width = 10cm ## height = 10cm set xrange [0:10] plot x*x title "\\(y=x^2\\)"The gxhconvert script uses the tikz terminal instead of the usual cairolatex pdf terminal if width and height are specified. Make sure you have installed the "gnuplot-lua-tikz" package for LaTeX.
## terminal = tikz ## terminal setup = solidFor the terminal you can choose either "tikz" or "cairolatex".
set xlabel "\\(\\frac{x}{x_0}\\rightarrow\\)" set ylabel "\\(\\overset{\\uparrow\\vspace{0.3em}}{y}\\)" rotate by 0Note: The \overset instruction requires a line
preamble line = \usepackage{amsmath}in the gxhconvert.conf file in the current working directory.
gxhconvert -o=pdf x.gp
Option | Purpose |
---|---|
--pgf | Use the Gnuplot tikz terminal to write PGF instructions into the *.tex output file instead of including a supplemental *-inc.pdf file. |
gnuplot -e "set terminal cairolatex pdf standalone ; set output 'x.tex'" x.gp pdflatex x
This choice allows to set the diagram width to 10cm and the height to 7cm.
gnuplot -e "set terminal tikz standalone plotsize 10cm,7cm ; set output 'x.tex'" x.gp pdflatex x
← TOC | ↑ Home | Gnuplot | → | TeX | TeX | EPS | SVG | PNG | JPEG |