Set root folder of support packages
sets the root folder of the current support packages. MATLAB® installs all support packages to this location.
You must have administrative privileges on the folder that you
set the root to. You must also have administrative privileges to modify
because the root folder of the support package is recorded under
When you change the root folder, support packages installed in the new location become available on the MATLAB path. Any previously installed support packages are removed from the MATLAB path, but the files are still available.
Set and Get Custom Support Package Root
to change the installation folder for support packages. You need administrative
privileges to use this function.
getSupportPackageRoot to check
that the change was successful.
ans = C:\MATLAB\CustomSupportPackageRoot
installDir — Root folder of support packages
Root folder of support packages, specified as a character vector. The folder path cannot contain any spaces.
The default location of the root folder is platform specific:
Linux® and macOS –
current MATLAB release and
is your Linux and macOS user
If a folder exists at the default location and is not empty, MATLAB sets the root folder location to the default location appended
_n. For example, on a Windows system running MATLAB R2021a, if the folder
and is not empty, MATLAB sets the root folder to