25 lines
408 B
Matlab
25 lines
408 B
Matlab
function[obj] = importData(obj, varargin)
|
|
if (nargin == 1)
|
|
if (isempty(obj.filename))
|
|
error(' Filename has not been set')
|
|
end
|
|
else
|
|
obj.datafile = varargin{1};
|
|
end
|
|
|
|
[base filename ext] = fileparts(obj.datafile);
|
|
|
|
if strcmp(lower(ext), '.edf');
|
|
obj.readEDF;
|
|
end
|
|
|
|
if strcmp(lower(ext), '.asc');
|
|
obj.read_ASC;
|
|
end
|
|
|
|
if strcmp(lower(ext), '.gazedata');
|
|
obj.read_gazedata;
|
|
end
|
|
|
|
end
|