Description Usage Arguments Details Author(s) See Also Examples
From given directory dir.in
, copies files into dir.out
. Either list of file names in fname
, or all files from dir.in
that start from given prefix
and end with ending
and contain keyword key
. If during copying uncompressing files ending with ".txt.bz2" is needed, set untarbz
to TRUE.
1 2 | get.file.copy(dir.in, dir.out, fname = "", prefix = "", key = "", ending = "",
untarbz=FALSE, verbal = TRUE)
|
dir.in |
The name of directory which contains files that need to be copied. |
dir.out |
The name of directory to which files should be copied. |
fname |
The list of file names (should be empty if you want it to find files itself given specifications of |
prefix |
The beginning of the file names that need to be copied. |
key |
Any keyword that uniquely distinguishes the files from others. |
ending |
The ending of the file names that need to be copied. |
untarbz |
Flag whether or not to untar encountered compressed files with ".tar.bz2" ending. |
verbal |
Flag whether or not to print error messages if files with |
This function can be used in two ways:
1. Either user provides a list of filenames that need to be copied over to dir.out
directory, in which case all prefix
, key
and ending
will be ignored.
2. Or fname
="" and some of the 3 parameters prefix
, key
and ending
are set. In which case the program will search for files in dir.in
that fulfill the specifications.
This function is basically file.copy, only it allows to pass in a list instead of a single file, and takes input in format that is similar to all other preprocessing functions in GenMOSS.
Olia Vesselova
1 | print("See the demo 'gendemo'.")
|
[1] "See the demo 'gendemo'."
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.