evstrevaluates Scilab expressions and concatenates their resultsSyntax
H = evstr(M)
H = evstr(list(M, subExpr))
[H, ierr] = evstr(..)
ArgumentsM
single or vector or matrix of character strings: Scilab expressions to be
evaluated and results to be concatenated.
subExpr
vector of character strings: sub-expressions to be pre-evaluated, defining
quantities used in M expressions.
H
single element, vector, or matrix of concatenated results.
ierran integer, error indicator.Description
Evaluates expressions set in M. Then, concatenates their results
to build H.
All expressions are assumed to yield results of compatible types and sizes with respect
to their concatenation.
If the evaluation of M expressions or the concatenation of their
results leads to an error, H = evstr(M) yields the error as usual.
To avoid stopping to run next Scilab instructions,
[H, ierr] = evstr(M) can be used to catch the error.
H is then set to [] and ierr
returns 999 or another non-null positive code.
If M is provided through a list, Scilab expressions set in
subExpr are evaluated before evaluating M.
The results of these subexpressions must be referred to as %(k)
in M, where k is the subexpression's index in
subExpr.
Assignments like "a = 1" are not accepted as expressions,
neither in M nor in subExpr.
execstr must be used instead to evaluate such expressions.
Continuation marks ".." are forbidden in expressions
in M as well as in subExpr.
Special aliases:
"Nan" and "NaN" are parsed as
%nan.
"Inf" and "INF" are parsed as
%inf.
ExamplesSee also
execstr
sci2exp
strtod
concatenation
History5.3.0"Nan" and "NaN" are now parsed as %nan.
"Inf" and "INF" are now parsed as %inf.
6.0.1
Simple comments are now supported in almost all possible input expressions,
whatever is the shape of M.