Export gnuplot png

How to "export" a graph to png or something pasted into Word? I know there are a dozen tutorials on the net, but I am having a hard time finding a simple example.

+2


a source to share


3 answers


Follow these;

Once you're happy with your plot, set the output terminal type to Postscript. ''

gnuplot> install postscript terminal

The graphics will be written in Postscript format, the language our printers understand, instead of the format understood by the windowing system. Then provide a filename for postscript output.

gnuplot> set output 'myfile.ps'

Then write your plot to a file by doing a relay.



gnuplot> replot

To send Postscript file to printer, use lpr shell command ( OPTIONAL )

$ lpr myfile.ps

If you want to continue working with the graph in the graphics window, you will need to return the output and terminal settings to normal by typing

gnuplot> install terminal x11

gnuplot> set output

Great tutorial here

+2


a source


In windows you can

install terminal windows

to output to the window. Further to output png,



install terminal png

This should work with native gnuplot binaries.

+3


a source


Recording

set terminal pngcairo
set output output.png

      

And gnuplot should be written to a file named output.png

.

0


a source







All Articles