How to draw only arrow in gnuplot

In gnuplot, draw an arrow as:

set arrow from 0,0 to 1,1 

I want to make a plot using arrows and other data. How can i do this. Right now, after installing the arrows, I need to give something to speak, since without this the arrows cannot be built. Is it possible to draw only an empty “plot” without any data?

I also saw online help for gnu , etc., but could not get an answer.

+6
source share
2 answers

If you set explicit axis ranges, you can build NaN to get a clean set of axes.

In addition, notitle or t '' must hide the key for NaN .

 set xrange [0:5] set yrange [0:5] set arrow from 0,0 to 1,1 plot NaN t '' 

chart output

+8
source

To build only an arrow with coordinates specified in units of ordinary axes, you can use the vectors construction style.

 # gnuplot 5 $data <<EOD 0 0 1 1 EOD plot $data u 1:2:3:4 w vectors 

or

 # gnuplot 4.x plot '-' u 1:2:3:4 w vectors 0 0 1 1 e 
0
source

All Articles