GeneralUse Gnuplot with TeXnicCenter

General information and discussion about TeXnicCenter
Post Reply
srporter
Posts: 2
Joined: Mon Nov 14, 2011 2:22 am

Use Gnuplot with TeXnicCenter

Post by srporter »

I'm trying to get gnuplot to work with TeXnicCenter so that I can plot equations with tikz. The solution is probably obvious, but I am very new to latex.

Having installed gnuplot on my Windows computer, I believe I next need to set up a new output profile, or somehow tell TeXnicCenter where gnuplot is?
Last edited by srporter on Mon Nov 14, 2011 5:52 pm, edited 1 time in total.

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

Use Gnuplot with TeXnicCenter

Post by localghost »

srporter wrote:[…] Having installed gnuplot on my Windows computer, I believe I next need to set up a new output profile, or somehow tell TeXnicCenter where gnuplot is?
You need to make the system aware of Gnuplot, not TeXnicCenter (TXC). Therefore you need to add the path to the Gnuplot executables to the »Path« variable of your system. The help function of your operating system should help you on in this regard. Otherwise a search engine might list solutions.

The second part is related to TXC and the concerned build profile. You need to add the command line argument --enable-write18 to the settings for the compiler. The Forum Search should be able to list some related topics.


Best regards and welcome to the board
Thorsten
srporter
Posts: 2
Joined: Mon Nov 14, 2011 2:22 am

Use Gnuplot with TeXnicCenter

Post by srporter »

Thanks Thorsten, it was the path part that was screwing me up, works great now.

For anyone else who has this issue, instructions are here for changing the path in Windows 7: http://geekswithblogs.net/renso/archive ... ows-7.aspx

Just enter the directory where the gnuplot application was installed (should be in a sub-folder called 'bin' or 'binary').

In TeXnicCenter, under 'Define Output Profiles', open the "LaTeX -> PDF" profile, and under 'command line arguments to pass to the compiler', add a space and '--enable-write18' to whatever commands are already there, like this:

Code: Select all

-interaction=nonstopmode "%pm" --enable-write18

Cheers,
Steve
susi
Posts: 1
Joined: Tue Dec 06, 2011 7:58 pm

Re: Use Gnuplot with TeXnicCenter

Post by susi »

Thank you very much for that good and detailed explanations! After a restart it finally works :)
Post Reply