Learn R Programming

qdap (version 2.4.6)

delete: Easy File Handling

Description

delete - Deletes files and directories.

folder - Create a folder/directory.

Usage

delete(file = NULL)

folder(..., folder.name = NULL)

Value

delete permanently removes a file/directory.

folder creates a folder/directory.

Arguments

file

The name of the file in the working directory or the path to the file to be deleted. If NULL provides a menu of files from the working directory.

folder.name

A character vector of the name(s) of the folder to be created. Default NULL (if the ... is NULL too) creates a file in the working directory with the creation date and time stamp. Use this argument only if the directory names contain spaces.

...

The name(s) of the folder to be created. If both ... and folder.name are NULL creates a file in the working directory with the creation date and time stamp.

See Also

Examples

Run this code
if (FALSE) {
(x <- folder("DELETE.ME"))
which(dir() == "DELETE.ME")
delete("DELETE.ME")
which(dir() == "DELETE.ME")

folder("the/next/big/thing", "hello world", "now/is/the/time")

folder(cat, dog)
lapply(c("cat", "dog"), delete)
}

Run the code above in your browser using DataLab