IRootLab
An Open-Source MATLAB toolbox for vibrational biospectroscopy
load_all_items.m
Go to the documentation of this file.
1 %>@ingroup ioio misc
2 %>@file
3 %>@brief Loads all MAT files in current directory (that contain a "r" variable inside) into the workspace
4 %
5 %> @param patt_match If specified, directories will have to match this pattern
6 %> @param patt_exclude If specified, directories will have NOT TO match this pattern
7 function load_all_items(patt_match, patt_exclude)
8 if nargin < 1
9  patt_match = [];
10 end;
11 if nargin < 2
12  patt_exclude = [];
13 end;
14 names = getfiles('*.mat', patt_match, patt_exclude);
15 n = numel(names);
16 
17 for i = 1:n
18  load_soitem(names{i});
19 end;
20 
21 evalin('base', 'global TEMP; clear TEMP;');
function load_soitem(in filename)
function load_all_items(in patt_match, in patt_exclude)
function getfiles(in wild, in patt_match, in patt_exclude)