Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

all points y2 value undefined!

359 views
Skip to first unread message

Peekay Ex

unread,
May 9, 2012, 5:24:12 PM5/9/12
to
Hello, I am using Gnuplot 4.6 Patchlevel 0 on Ubuntu, I am new to
Gnuplot but can create simple plots.

I am struggling though to understand why a 'two co-ordinate' plot I
have returns an error 'all points y2 value undefined!'

My plot is (I think) is quite simple.

--snip--

set xtics nomirror
set ytics nomirror
set y2tics
plot "-" u 1:2 t "Foo" axes x1y1 with boxes, "" u 1:3 t "Bar" axes
x1y2 w lines

1996 21 1
1997 161 2
1998 138 5
1999 225 6
2000 344 9
2001 276 5
2002 991 7
2003 995 7

--snip--

And I cannot work out what the error is referring to. Isn't 'y2'
implied by the third column?

Thank you for any help.

Regards

James

Lee

unread,
May 15, 2012, 11:18:18 AM5/15/12
to
You can't reuse unline data, either with your attempt at using "" or
by specifying "-" a second time. Save the data in a file if you can.
If it's a big dataset that's streaming and you don't want to store it,
you should be able to use a named pipe or something like that.



Lee Phillips
----------------------------
gnuplot Cookbook:
http://www.amazon.com/gp/product/184951724X?tag=leephillipsor-20

Hans-Bernhard Bröker

unread,
May 15, 2012, 12:57:14 PM5/15/12
to
On 09.05.2012 23:24, Peekay Ex wrote:

> I am struggling though to understand why a 'two co-ordinate' plot I
> have returns an error 'all points y2 value undefined!'

In a nutshell: because that's supposed to be a two-dataset plot, but you
only supplied one dataset. Please consult "help datafile special" again
to learn the details.

> And I cannot work out what the error is referring to. Isn't 'y2'
> implied by the third column?

No. gnuplot doesn't care which column you use as 'x' and which as 'y',
'y2' or whatever.
0 new messages