NCCOOS Trac Projects: Top | Web | Platforms | Processing | Viz | Sprints | Sandbox | (Wind)

root/gliderproc/trunk/MATLAB/opnml/FCAST_1.2/matlab_cen/loadname.m

Revision 495 (checked in by cbc, 11 years ago)

Initial import of Stark code.

Line 
1 % [array]=loadname(filename)
2 % load filename and save data back with name array.
3 function [array]=loadname(filename)
4 %
5 load(filename);
6 %
7 slashes=find(filename(1,:)=='/');
8 if isempty(slashes)==1;
9    is=1;
10 else
11    is=slashes(length(slashes))+1;
12 end
13 %
14 dots=find(filename(1,is:length(filename))=='.');
15 if isempty(dots)==1;
16    ie=length(filename);
17 else
18    ie=is+dots(1)-2;
19 end
20 %
21 array=eval(filename(is:ie));
Note: See TracBrowser for help on using the browser.