path_get_label: splitting path and returning just one item in the vector

View source: R/io.R

path_get_labelR Documentation

splitting path and returning just one item in the vector

Description

This is useful for merging tables in which the individual table ID is within the file path.

Usage

path_get_label(file_path, index)

Arguments

file_path

File path(s). If vector or list of paths provided, then a list will be returned

index

Which item in the path to return? 1-indexing. If <1, samples selected from the end. "O" will select the file name.

Value

string if 1 path, else list


leylabmpi/LeyLabRMisc documentation built on Nov. 3, 2022, 3:45 p.m.