Gnuplot Generates Display Error When Generating PNG - Graphics

This is a discussion on Gnuplot Generates Display Error When Generating PNG - Graphics ; Here is my script (Gnuplot4.2, Debian Sarge): set terminal png nocrop enhanced size 420,320 set output "graph.png" set title "Measurements" set view map rgb(r,g,b) = int(r)*65536 + int(g)*256 + int(b) splot "data" using 1:2 0):3 rgb($1,$2,0)) with points pt 7 ...

+ Reply to Thread
Results 1 to 3 of 3

Gnuplot Generates Display Error When Generating PNG

  1. Default Gnuplot Generates Display Error When Generating PNG

    Here is my script (Gnuplot4.2, Debian Sarge):

    set terminal png nocrop enhanced size 420,320
    set output "graph.png"
    set title "Measurements"
    set view map
    rgb(r,g,b) = int(r)*65536 + int(g)*256 + int(b)
    splot "data" using 1:20):3rgb($1,$2,0)) with points pt 7 ps
    variable lc rgb variable

    Here is some sample data:

    10 20 3
    4 6 7

    When I run this on my headless server I get the following error and no
    graph is generated:

    gnuplot: unable to open display ''
    gnuplot: X11 aborted.

    So I did:

    export DISPLAY = 0:0

    Now gnuplot will generate the graph, but about 5 seconds later it
    prints to stdout:

    gnuplot: unable to open display '0:0'
    gnuplot: X11 aborted.

    How can I tell gnuplot that I don't want to use the display and just
    generate a PNG file?

    thanks, Andy


  2. Default Re: Gnuplot Generates Display Error When Generating PNG

    In article <1184957601.564221.300210@e16g2000pri.googlegroups.com>,
    Andy <ajayre@gmail.com> wrote:
    >
    >When I run this on my headless server I get the following error and no
    >graph is generated:
    >
    >gnuplot: unable to open display ''
    >gnuplot: X11 aborted.


    Heh. Another bug fix that will be in the incremental 4.2.1
    The bug is that on linux systems the default terminal is X11,
    regardless of whether you actually have x11 installed.

    To fix it permanently, set an environmental variable on this
    machine to change the default terminal to something else.
    For example:

    tcsh:
    setenv GNUTERM dumb
    bash:
    export GNUTERM=dumb

    --
    Ethan A Merritt

  3. Default Re: Gnuplot Generates Display Error When Generating PNG

    On Jul 20, 12:24 pm, merr...@u.washington.edu (Ethan Merritt) wrote:
    >
    > To fix it permanently, set an environmental variable on this
    > machine to change the default terminal to something else.
    > For example:
    >
    > tcsh:
    > setenv GNUTERM dumb
    > bash:
    > export GNUTERM=dumb
    >


    Worked like a charm! Once again, may thanks for your FAST help!

    Andy


+ Reply to Thread

Similar Threads

  1. Generating EPS-file using Gnuplot: How to make crosses?
    By Application Development in forum Graphics
    Replies: 3
    Last Post: 10-30-2007, 12:16 PM
  2. Generating Gnuplot graphs from Perl - and keeping them open
    By Application Development in forum Perl
    Replies: 2
    Last Post: 05-30-2007, 05:28 PM
  3. mimic gnuplot logscale in a c function for openGL display
    By Application Development in forum Graphics
    Replies: 2
    Last Post: 03-13-2007, 05:32 PM
  4. GNUPLOT / CGI: Generating Plots for web browsers
    By Application Development in forum Graphics
    Replies: 2
    Last Post: 11-15-2005, 12:29 PM
  5. Mismatch in postscript file display generated by Gnuplot
    By Application Development in forum Graphics
    Replies: 11
    Last Post: 10-15-2005, 07:47 AM