paste_paths: Concatenate two paths

paste_pathsR Documentation

Concatenate two paths

Description

Concatenates two strings to a path string correctly.

Usage

paste_paths(path1 = "w", path2 = "d", os = "LiNuX")

Arguments

path1

A a character vector of length one specifying the left hand part of the resulting path.

path2

A a character vector of length one specifying the right hand part of the resulting path.

os

A a character vector of length one specifying the operating system you're operating on: windows or linux.

Value

A a character vector of length one containing the concatenated path.

Examples

paste_paths(path1 = "data", path2 = "patients")
paste_paths(path1 = "/data", path2 = "patients")
paste_paths(path1 = "/data/", path2 = "patients")
paste_paths(path1 = "/data", path2 = "/patients")
paste_paths(path1 = "/data/", path2 = "/patients/")
paste_paths(path1 = "data", path2 = "patients", os = "windows")

TPeschel/fhiR documentation built on April 14, 2024, 7:31 a.m.