R - file manipulation with list.files() and file.<...>() functions

27 Dec 2018

Various functions for direct file manipulation (e.g. avoid use of system(<…command…>))

See ?files for more information

list.files() to listing files

file.create() to create filesystem

file.exists() to test existence of file(s)

file.remove() to delete file(s)

file.rename() to rename file(s)

file.append() to append the file(s) named by its second argument to those named by its first

file.copy() similar to file.append() but with arguments in the natural order for copying

file.symlink() to create symbolic links

file.link() to create hard links

file.create(..., showWarnings = TRUE)
file.exists(...)
file.remove(...)
file.rename(from, to)
file.append(file1, file2)
file.copy(from, to, overwrite = recursive, recursive = FALSE,
          copy.mode = TRUE, copy.date = FALSE)
file.symlink(from, to)
file.link(from, to)
[ R  function  files  ]