Generate path string
p = genpath
p = genpath(folderName)example
p = genpath returns a path string,
that includes all the folders and subfolders below
including empty subfolders.
p = genpath( returns
a path string that includes
folderName and multiple
levels of subfolders below
folderName. The path
string does not include folders named
folders that begin with the
@ character (class
folders), folders that begin with the
(package folders), or subfolders within any of these.
genpath in conjunction
addpath to add a folder and its subfolders
to the search path.
Generate a path that includes
all folders below it.
folderName = fullfile(matlabroot,'toolbox','images','colorspaces'); p = genpath(folderName);
Add the folder and its subfolders to the search path.