Next: fwrite() Up: MacAnova Help File Previous: formatpval()   Contents


fromclip([ncol]), ncol > 0 an integer

Keywords: character variables, input
y <- fromclip() does a vecread() from CLIPBOARD, creating a REAL vector

y <- fromclip(ncol) is equivalent to matrix(fromclip(),ncol)', where
ncol is an integer.  This creates a REAL matrix with ncol columns and
makes most sense if the contents of CLIPBOARD are arranged in ncol
columns as they would be after CLIPBOARD <- x, where x is a matrix with
ncol columns.

In the Macintosh, Windows and Motif versions, fromclip() allows easy
importing of data from other applications such as a spreadsheet. For
example, if you have Copied to the Clipboard a 10 by 5 rectangle of
spreadsheet cells containing numbers, or 10 lines of a 5 column
numerical table in a word processor or editor,
   x <- fromclip(5)
will create a 10 by 5 REAL matrix consisting of the data copied.

fromclip() is implemented as a pre-defined macro.

See also topic clipreaddata().

Gary Oehlert 2003-01-15