-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathmildatapath.m
More file actions
executable file
·51 lines (46 loc) · 1.19 KB
/
Copy pathmildatapath.m
File metadata and controls
executable file
·51 lines (46 loc) · 1.19 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
% MILDATAPATH Path to MIL datasets
%
% DPATH = MILDATAPATH(NEWPATH)
%
% INPUT
% NEWPATH Path to MIL datasets
%
% OUTPUT
% DPATH Path to MIL datasets
%
% DESCRIPTION
% Define the directory name where all MIL dataset are stored.
% When you supply it a path, a global variable is created that stores
% the location of the MIL datasets. In the functions GENDATMIL* this
% path is retrieved by a call to MILDATAPATH.
%
% SEE ALSO
% gendatmilmusk, gendatbirds, gendatdrive, ...
% Copyright: D.M.J. Tax, D.M.J.Tax@prtools.org
% Faculty EWI, Delft University of Technology
% P.O. Box 5031, 2600 GA Delft, The Netherlands
function dpath = mildatapath(newpath)
persistent MILDATAPATH;
if nargin<1
if isempty(MILDATAPATH)
% the path has to be derived for the machine
if strncmp(computer,'MAC',3)
dpath = '/data/mil/';
else
if strcmp(computer,'GLNXA64')
dpath = '/tudelft.net/staff-groups/ewi/insy/PRLab/data/mil/';
else
dpath = '/data/pr/home/davidt/data/mil/';
end
end
MILDATAPATH = dpath;
else
% here it should already be given in the global var:
dpath = MILDATAPATH;
end
else
% the path was already given by the user
MILDATAPATH = newpath;
dpath = newpath;
end
return