IRootLab
An Open-Source MATLAB toolbox for vibrational biospectroscopy
irootlab_restart.m
Go to the documentation of this file.
1 %> @file
2 %> @ingroup misc usercomm introspection
3 
4 %> @brief Changes to irootlab root directory and runs startup again
5 function irootlab_restart()
6 
7 irst_p = pwd();
8 irst_d = get_rootdir();
9 
10 irst_pa = regexp(path(), ':', 'split');
11 
12 % Changes to IRoot root directory
13 cd(irst_d);
14 
15 % Removes all current irootlab directories from MATLAB path
16 for i = 1:numel(irst_pa)
17  if any(strfind(irst_pa{i}, irst_d))
18  rmpath(irst_pa{i});
19  end;
20 end;
21 
22 % Runs startup
23 startup();
24 
25 % Goes back to initial directory
26 cd(irst_p);
27 
function get_rootdir()
function irootlab_restart()
Changes to irootlab root directory and runs startup again.