Epslatex stand alone does not add \end{document}

61 Views Asked by At

I'm trying to use epslatex to create a standalone but the file .tex created can't be compiled because \end{document} and \end{picture} are missing, why is this ? Sample code

    set terminal epslatex standalone
    set output "sample.tex" 
    plot "data.txt" using 1:2  pointtype 1 pointsize 1 

I'm plotting data from a text file maybe is this the problem ? Anyway the figure is created only the .tex file is not working

1

There are 1 best solutions below

0
On BEST ANSWER

Add

unset output

to the end to get a complete TeX file. Otherwise, the file is not written completely to disk.

The terminal pdfcairo allows to have several plot commands, each resulting in an own page in the pdf file. I first thought epslatex may do something similar, but it doesn't