Learn R Programming

fhircrackr (version 2.1.1)

paste_paths: Concatenate two paths

Description

Concatenates two strings to a path string correctly.

Usage

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

Value

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

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.

Examples

Run this code
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")

Run the code above in your browser using DataLab