short_names {mclm}R Documentation

Shorten filenames

Description

Helper functions that make the paths to a file shorter.

Usage

drop_path(x, ...)

drop_extension(x, ...)

short_names(x, ...)

Arguments

x

An object of class fnames or a character vector.

...

Additional arguments.

Value

An object of the same class as x.

Functions

Examples

cwd_fnames <- as_fnames(c("folder/file1.txt", "folder/file2.txt", "folder/file3.txt"))
drop_path(cwd_fnames)
drop_extension(cwd_fnames)
short_names(cwd_fnames) # same as drop_path(drop_extension(cwd_fnames))

[Package mclm version 0.2.7 Index]