Reputation: 3694
Suppose I have the file table.tex
\begin{tabular}{|c|c|}
\hline
1 & 2 \\ \hline
3 & 4 \\ \hline
\end{tabular}
This basically is a 2 by 2 table with some numbers.
I can compile it like that, and see borders on any side of the table
\documentclass{article}
\begin{document}
\input{table.tex}
\end{document}
Now I have the following gnuplot
script (tested with 4.6.2 and 4.6.5)
set terminal epslatex standalone solid
set output "out.tex"
set label '\input{table.tex}' at 1,1
plot x
Then I get the following
In other words, my borders have disappeared. How can I solve that?
Upvotes: 2
Views: 298
Reputation: 48430
That is a limitation of the minimal
documentclass which is used by the epslatex
terminal in standalone
mode. The following works fine:
Main file out-main.tex
:
\documentclass{standalone}
\usepackage{graphicx}
\begin{document}
\input{out}
\end{document}
and the gnuplot script
set terminal epslatex solid
set output "out.tex"
set label at 1,1 '\begin{tabular}{|c|c|} \
\hline \
1 & 2 \\ \hline \
3 & 4 \\ \hline \
\end{tabular}'
plot x
set output
system("latex out-main && dvips out-main && ps2pdf out-main.ps")
gives
Upvotes: 2