read.clipboard {psych} | R Documentation |
input from the keyboard is easy but a bit obscure, particularly for Mac users. This is just an easier mnemonic to do so.
read.clipboard(header = TRUE, ...) #my.data <- read.clipboad() #assumes headers and tab delimited #my.data <- read.clipboard.csv() #assumes heades and comma delimited
header |
Does the first row have variable labels |
... |
Other parameters to pass to read |
A typical session of R might involve data stored in text files, generated on line, etc. Although it is easy to just read from a file (particularly if using file.locate(), copying from the file to the clipboard and then reading from the clipboard is also very convenient (and somewhat more intuitive to the naive user.)
Based upon a suggestion by Ken Knoblauch to the R-help listserve.
the contents of the clipboard.
William Revelle
#my.data <- read.clipboad() #my.data <- read.clipboard.csv() #my.data <- read.clipboad(header=FALSE)