GetFromBase

Get a variable from base.

Syntax

vv = GetFromBase(varname,defval)

Inputs

varname
Variable name.
Type: char
Dimension: string
defval
Default value if variable name is not found.
Type: double | integer
Dimension: scalar

Outputs

vv
Variable that was retrieved from base.
Type: double | integer | char | log
Dimension: scalar | vector | matrix | struct | cell | Boolean | string

Example

Get q variable from the base. If not found, value 0 is used.

q = GetFromBase('q', 0);