home *** CD-ROM | disk | FTP | other *** search
/ Big Green CD 8 / BGCD_8_Dev.iso / NEXTSTEP / UNIX / Educational / R-0.49-MI / R-0.49-I / help / base / identify < prev    next >
Encoding:
Text File  |  1997-04-23  |  2.3 KB  |  60 lines

  1.     
  2.     _I_d_e_n_t_i_f_y _P_o_i_n_t_s _i_n _a _S_c_a_t_t_e_r _P_l_o_t
  3.     
  4.          identify(x, y, labels=seq(along=x), n=length(x),
  5.                  plot=TRUE, offset=0.5, labpos=FALSE)
  6.     
  7.     _A_r_g_u_m_e_n_t_s:
  8.     
  9.              x,y : coodinates of points in a scatter plot.
  10.                    Alternatively, any object which can defines
  11.                    coordinates (a plotting structure, time
  12.                    series etc.) can be given as x and y left
  13.                    undefined.
  14.     
  15.           labels : an optional vector, the same length as x and
  16.                    y, giving labels for the points.
  17.     
  18.                n : the maximum number of points to be identi-
  19.                    fied.
  20.     
  21.             plot : if plot is TRUE, the labels are printed at
  22.                    the points and if FALSE they are omitted.
  23.     
  24.           offset : the distance (in character widths) which
  25.                    separates the label from identified points.
  26.     
  27.           labpos : if labpos is TRUE, a component is added to
  28.                    the return value which indicates where text
  29.                    was plotted relative to each identified point
  30.                    (1=below, 2=left, 3=above and 4=right).
  31.     
  32.     _D_e_s_c_r_i_p_t_i_o_n:
  33.     
  34.          This function reads the position of the graphics
  35.          pointer when the (first) mouse button is pressed.  It
  36.          then searches the coordinates given in x and y for the
  37.          point closest to the pointer.  If this point is close
  38.          to the pointer, its index will be returned as part of
  39.          the value of the call.  If in addition, plot is TRUE
  40.          the point is labelled with the corresponding element of
  41.          text.
  42.     
  43.          The labels are placed either below, to the left, above
  44.          or to the right of the identified point, depending on
  45.          where the cursor was.
  46.     
  47.          The identification process is terminated by pressing
  48.          any mouse button other than the first, or by clicking
  49.          outside the graphics window.
  50.     
  51.     _V_a_l_u_e:
  52.     
  53.          If labpos is FALSE, identify returns an integer vector
  54.          containing the indexes of the identified points.  If
  55.          labpos is TRUE, identify returns a list containing a
  56.          component ind, indicating which points were an identi-
  57.          fied and a component labpos, indicating where the
  58.          labels were placed relative to the identified points.
  59.     
  60.