| MATLAB® | ![]() |
toolboxdir('tbxdirname')
s = toolboxdir('tbxdirname')
s = toolboxdir tbxdirname
toolboxdir('tbxdirname') returns a string that is the absolute path to the specified toolbox, tbxdirname, where tbxdirname is the directory name for the toolbox.
s = toolboxdir('tbxdirname') returns the absolute path to the specified toolbox to the output argument, s.
s = toolboxdir tbxdirname is the command form of the syntax.
toolboxdir is particularly useful for MATLAB Compiler software. The base directory of all toolboxes installed with MATLAB software is:
matlabroot/toolbox/tbxdirname
However, in deployed mode, the base directories of the toolboxes are different. toolboxdir returns the correct root directory, whether running from MATLAB or from an application deployed with the MATLAB Compiler software.
To obtain the path for the Control System Toolbox software, run
s = toolboxdir('control')
MATLAB returns
s = \\myhome\r2008b\matlab\toolbox\control
ctfroot (in the MATLAB Compiler product), fullfile, matlabroot, partialpath, path,
Managing Files and Working with the Current Directory
![]() | toeplitz | trace | ![]() |
| © 1984-2008- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |