Learn R Programming

matlab (version 1.0.2)

fullfile: MATLAB fullfile function

Description

Contructs path to a file from components in platform-independent manner

Usage

fullfile(...)

Arguments

...
character strings representing path components

Value

Returns character vector of arguments concatenated term-by-term and separated by file separator if all arguments have a positive length; otherwise, an empty character vector.

Details

Builds a full filename from the directories and filename specified. This is conceptually equivalent to

paste(dir1, dir2, dir3, filename, sep=filesep)

with care taken to handle cases when directories begin or end with a separator.

See Also

fileparts, filesep

Examples

Run this code
fullfile("", "etc", "profile")	# /etc/profile

Run the code above in your browser using DataLab