TITLE(identify @@ Identify Points in a Scatter Plot)
USAGE(
identify(x, y, labels=seq(along=x), 
         n=length(x), plot=TRUE, offset=0.5, 
         pos=FALSE, DOTS)
)
ALIAS(identify)
ARGUMENTS(
ARG(x,y @@ coodinates of points in a scatter plot.
Alternatively, any object which can defines coordinates
(a plotting structure, time series etc.) can be given as
LANG(x) and LANG(y) left undefined.)
ARG(labels @@ an optional vector, the same length as LANG(x)
and LANG(y), giving labels for the points.)
ARG(n @@ the maximum number of points to be identified.)
ARG(plot @@ if LANG(plot) is LANG(TRUE), the labels are
printed at the points and if LANG(FALSE) they are omitted.)
ARG(offset @@ the distance (in character widths) which
separates the label from identified points.)
ARG(pos @@ if LANG(pos) is LANG(TRUE), a component
is added to the return value which indicates where text
was plotted relative to each identified point (1=below,
2=left, 3=above and 4=right).)
ARG(DOTS @@ further arguments to LANG(par(.)).)
)
DESCRIPTION(
This function reads the position of the graphics pointer when
the (first) mouse button is pressed.  It then searches the coordinates
given in LANG(x) and LANG(y) for the point closest to the pointer.
If this point is close to the pointer, its index will be returned
as part of the value of the call.  
PARA
ITALIC(The following, and the LANG(n) and LANG(offset) arguments are
BOLD(NOT yet) implented):
BLANK
If in addition, LANG(plot) is LANG(TRUE) the point is labelled with the
corresponding element of LANG(text).
PARA
The labels are placed either below, to the left, above or to
the right of the identified point, depending on where the cursor was.
PARA
The identification process is terminated by
pressing any mouse button other than the first,
or by clicking outside the graphics window.
)
VALUE(
If LANG(labpos) is LANG(FALSE), LANG(identify) returns an integer
vector containing the indexes of the identified points.
If LANG(labpos) is LANG(TRUE), LANG(identify) returns a list
containing a component LANG(ind), indicating which
points were an identified and a component LANG(labpos),
indicating where the labels were placed relative to the
identified points.
)
