-
Notifications
You must be signed in to change notification settings - Fork 0
/
SaveESN.m
30 lines (23 loc) · 788 Bytes
/
SaveESN.m
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
function SaveESN(esn,file_name,varargin)
% SAVE_ESN save an Esn structure to disk. It's saved under the name
% file_name.
%
% inputs:
% esn - our Esn structure we want to save
% file_name - a string containing the file we want
% option - string containing further options that will be forwarded to
% the matlab save instruction
%
% usages:
% save_esn(our_trained_esn, 'esn_28_apr_2006', '-V6')
% save_esn(our_trained_esn, 'esn_28_apr_2006')
% Created April 30, 2006, D. Popovici
% Copyright: Fraunhofer IAIS 2006 / Patent pending
if length(varargin) > 0
option = char(varargin{1}) ;
else
option = '' ;
end
eval([file_name , '=' , 'esn ; '])
eval(['save ',file_name,' ',file_name , ' ', option ])
%TODO: check if file_name is a valid string, i.e. starts with a letter