IRootLab
An Open-Source MATLAB toolbox for vibrational biospectroscopy
Main Page
Related Pages
Modules
Classes
Files
File List
File Members
iif.m
Go to the documentation of this file.
1
%> @ingroup misc maths
2
%> @brief in-line
"IF"
3
%> @file
4
%>
5
%> This
function
takes three parameters. The first parameter is a condition. If the condition is
true
,
6
%> returns the second argument, otherwise the third.
7
%>
8
%> @param condition
9
%> @param out1
10
%> @param out2
11
%> @
return
out
12
function
out =
iif
(cond, x1, x2)
13
if cond
14
out = x1;
15
else
16
out = x2;
17
end;
iif
function iif(in cond, in x1, in x2)
m
misc
misc
iif.m
Generated on Tue May 19 2015 20:46:05 for IRootLab by
1.8.9.1