# tkz-fct not creating a visible graph

I've tried copying a pasting code from various examples posted on this site and in the manual, but the graph is never visible.

MWE: (this MWE comes from this posting)

\documentclass[tikz]{standalone}
\usepackage{tkz-fct}
\begin{document}
\begin{tikzpicture}[>=stealth']
\tkzInit[xmin=-15,xmax=25,
ymin=-250,ymax=50,
xstep=5,ystep=50]
\tkzAxeXY
\tkzFct[domain=-10:24,color=blue,very thick,<->]{14*\x-\x**2}
\end{tikzpicture}
\end{document}


Results in:

• A couple notes that may be relevant are: I'm running TeXLive on Mac OSx. I'm compiling the documentn using pdflatex. – A.Ellett Nov 8 '14 at 6:14
• I get the curve with latest miktex. – user11232 Nov 8 '14 at 10:12

Note that tkz-fct doesn't do the calculations itself, they are performed by Gnuplot (I think). Therefore, you need to allow for execution of external programs by compiling with the --shell-escape flag, i.e.

pdflatex -shell-escape filename.tex


There will be a warning in the log related to this, saying something like

Package pgf Warning: Plot data file filename.tkzfct.table' not found. on input line 32.


The .table file is generated by Gnuplot, and read by tkz-fct, without -shell-escape you wont get that file.

• T I'd like to thank you for this posted answer. – David Jan 10 '17 at 2:04
• I just tried the latest version of MikTeX and it still doesn't work, I get the same result as the one shown in the question. I tried to add --enable-write18 as indicated in the manual, but it didn't work. I installed gnuplot on Windows 10 and the environment variable is correct. What's going on? – AndréC Oct 23 '18 at 9:26
• @AndréC Don't know. Did you try with shell-escape? Did you look in the log file for any info? Ask a new question if you can't figure it out. – Torbjørn T. Oct 23 '18 at 9:29
• Yes, I tried your solution, without any effect on me. I have this error: Package pgf Warning: Plot data file test-media.tkzfct.table not found. on input line 9` – AndréC Oct 23 '18 at 9:40
• @AndréC That message indicates Gnuplot wasn't run. But as I said, ask a new question and describe in detail your setup, I don't know what's wrong. – Torbjørn T. Oct 23 '18 at 10:06