View source: R/e_file_first_last.R
e_file_first_last | R Documentation |
List of filenames as the first or last n by filename or file time matching a regular expression within a path
e_file_first_last(
name = NULL,
path = ".",
sw_first_last = c("first", "last")[2],
n_file = 1,
sw_sort = c("filename", "mtime", "ctime", "atime")[1],
sw_rev_order = c(TRUE, FALSE)[1],
...
)
name |
filename regular expression for which to search |
path |
path |
sw_first_last |
first (oldest) or last (newest) set of files |
n_file |
number of filenames to return |
sw_sort |
sort by filename, or by time from |
sw_rev_order |
default sort starting with first (oldest) or reverse to start with last (newest)? |
... |
additional arguments passed to |
fn_out filename list with path
## Not run:
# last filename by name in getwd()
e_file_first_last()
# newest 3 files in getwd()
e_file_first_last(n_file = 3, sw_sort = "mtime")
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.