Arrow

Arbitrary arrows can be placed on a plot using the set arrow command.

Syntax:

         set arrow {<tag>} {from <position>} \
                           {to <position>} {{no}head} \
                           {<linestyle>}
         set noarrow {<tag>}
         show arrow

Unspecified co-ordinates default to 0. The endpoints can be specified in one of four co-ordinate systems—first or second axes, graph or screen. See set co-ordinates for details. Arrows outside the screen boundaries are permitted but may cause device errors.

<tag> is an integer that identifies the arrow. If no tag is given, the lowest unused tag value is assigned automatically. The tag can be used to delete or change a specific arrow. To change any attribute of an existing arrow, use the set arrow command with the appropriate tag and specify the parts of the arrow to be changed.

Specifying nohead produces an arrow drawn without a head—a line segment. This gives you yet another way to draw a line segment on the graph. By default, arrows have heads.

linestyle allows specification of the line style to be used for the arrow.

Examples:

To set an arrow pointing from the origin to (1,2), use:

         set arrow to 1,2
To set an arrow from bottom left of plotting area to (-5,5,3), and tag the arrow number 3, use:
         set arrow 3 from graph 0,0 to -5,5,3
To change the preceding arrow to end at 1,1,1, without an arrow head, use:
         set arrow 3 to 1,1,1 nohead
To draw a vertical line from the bottom to the top of the graph at x=3, use:
         set arrow from 3, graph 0 to 3, graph 1 nohead
To delete arrow number 2 use:
         set noarrow 2
To delete all arrows use:
         set noarrow
To show all arrows (in tag order) use:
         show arrow