remove_spaces: Remove spaces from all files within a directory

Description Usage Arguments

View source: R/remove_spaces.R

Description

remove_spaces removes paces from file names, which is required to run MLWIC2 functions on these images. Note: use this function with caution as you are essentially renaming files. In the future, it is good practice to avoid putting spaces in any folder or file name.

Usage

1
remove_spaces(path = getwd(), pattern = c(".JPG", ".jpg"), copy = FALSE)

Arguments

path

The path to the image files whose names need to be changed. The default is to use your current working directory.

pattern

A vector containing the file name suffixes for which you want to change the name.

copy

logical. If TRUE, the function will create new files with spaces absent from the name. If FALSE, the function will delete the orginial files and create new files without spaces in names. If FALSE, you are deleting your original files, but saving storage space on your drive.


mikeyEcology/MLWIC2 documentation built on Feb. 18, 2021, 11:46 a.m.