from
functionsclass
by Mihai Moldovan
A class that exposes MATLAB subfunctions as public methods of the primary functions.
|
| samplelib2(varargin) |
function varargout = samplelib2(varargin)
% sample library function
% --------------------------------------------------------------------
% Primary function of the library
% --------------------------------------------------------------------
dir
% --------------------------------------------------------------------
% Library subfunctions
% --------------------------------------------------------------------
function f1
% test1
disp('first test')
% --------------------------------------------------------------------
function o=echo3(i)
% it will echo the double of the input string
if ischar(i)
o=strcat(i,i,i);
end
% --------------------------------------------------------------------
function f2
% something
disp('something')
% --------------------------------------------------------------------
function f3
% something
disp('something')
% --------------------------------------------------------------------
function f4
% something
disp('something')
% --------------------------------------------------------------------
function f5
% something
disp('something')
% --------------------------------------------------------------------
function f6
% something
disp('something')
|
|
Contact us at files@mathworks.com