fun_from_folder: Apply function within a folder

View source: R/additionalFunctions.R

fun_from_folderR Documentation

Apply function within a folder

Description

It executes the function fun by first switching directories temporarily to the folder folder and then returning to the working directory.

Usage

fun_from_folder(folder, fun, ...)

Arguments

folder

The folder of execution that the function is switched to before executing fun

fun

Function to be executed from the relative path

...

Options to be passed to fun

Value

The return value of fun(...)

Examples

list.files()
fun_from_folder(system.file("data", package = "TexExamRandomizer"), list.files)
list.files()

alexrecuenco/TexExamRandomizer documentation built on Jan. 31, 2024, 9:29 p.m.