4 mlock; % Protect function against clear
5 persistent ROBO; if isempty(ROBO), ROBO = false;
end % Initialize ROBO on creation
14 if ~ROBO || resetFlag % Check
if previous initialization was successful
15 root = mfilename(
'fullpath');
16 root = root(1:find(root==filesep,1,
'last')-1); % Get directory of
this file
17 setpref(
'robochameleon',
'roboRootFolder',root);
19 fprintf(1,
'Initializing Robochamelon. Adding directories to path:\n');
20 fprintf(
'-> %s\n',root);
23 dirs = {
'addons',
'base',
'files',
'library',
'utils',
'devel',
'lab',
'view'};
24 % Add user defined directories to path
25 if ispref(
'robochameleon',
'extrapathdirs')
27 dirs = [dirs extradirs];
32 add = [root filesep dirs{i}];
33 fprintf(
'-> %s\\*\n',add);
34 addpath(genpath(add));
37 if verLessThan(
'matlab',
'8.1.0')
38 fprintf(1, 'Adding compatibility layer for MATLAB releases before 8.1.0 (R2013a).\n');
39 addpath(genpath(fullfile(root, 'compatibility', '8.1')));
42 if verLessThan('matlab', '8.5.0')
43 fprintf(1, 'Adding compatibility layer for MATLAB releases before 8.5.0 (R2015a).\n');
44 addpath(genpath(fullfile(root, 'compatibility', '8.5')));
48 fprintf(1, 'Adding compatibility layer bioinfo_lite.\n');
49 addpath(genpath(fullfile(root, 'compatibility', 'bioinfo_lite')));
53 fprintf(1, 'Adding compatibility layer stats_lite.\n');
54 addpath(genpath(fullfile(root, 'compatibility', 'stats_lite')));
58 warning('off','
catstruct:DuplicatesFound');
function catstruct(in varargin)
Concatenate or merge structures with different fieldnames.
function robochameleon(in varargin)
Add robochameleon related directories to the MATLAB path.
function end(in obj, in k, in n)
Overload of indexing end statement.