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 / edit < prev    next >
Encoding:
Text File  |  1997-04-23  |  1.7 KB  |  52 lines

  1.     
  2.     _I_n_v_o_k_e _a _T_e_x_t _E_d_i_t_o_r
  3.     
  4.          edit(name=NULL, file="", editor = "vi")
  5.          vi(name=NULL, file="")
  6.          emacs(name=NULL, file="")
  7.          xemacs(name=NULL, file="")
  8.          xedit(name=NULL, file="")
  9.     
  10.     _A_r_g_u_m_e_n_t_s:
  11.     
  12.             name : a named object that you want to edit. If name
  13.                    is missing then the file specified by file is
  14.                    opened for editing.
  15.     
  16.             file : a string naming the file to write the edited
  17.                    version to.
  18.     
  19.           editor : a string naming the text editor you want to
  20.                    use.
  21.     
  22.     _D_e_s_c_r_i_p_t_i_o_n:
  23.     
  24.          edit invokes the text editor specified by editor with
  25.          the object name to be edited. data.entry can be used to
  26.          edit data.  It is important to realize that edit does
  27.          not change the object called name.  Instead, a copy of
  28.          name is made and it is that copy which is changed.
  29.          Should you want the changes to apply to the object name
  30.          you must assign the result of edit to name.
  31.     
  32.          In the form edit(name), edit deparses name into a tem-
  33.          porary file and invokes the editor editor on this file.
  34.          Quiting from the editor causes file to be parsed and
  35.          that value returned.  Should an error occur in parsing,
  36.          possibly due to incorrect syntax, no value is returned.
  37.          Calling edit(), with no arguments, will result in the
  38.          temporary file being reopened for further editing.
  39.     
  40.     _S_e_e _A_l_s_o:
  41.     
  42.          data.entry, fix.
  43.     
  44.     _E_x_a_m_p_l_e_s:
  45.     
  46.          # use xedit on the function mean and assign the changes
  47.          mean <- edit(mean, editor="xedit")
  48.     
  49.          # use vi on mean and write the result to file mean.out
  50.          vi(mean, file="mean.out")
  51.     
  52.