Run-time substitution of LabTalk variables and variable expressions occurs routinely during Origin graphing and analysis operations. It also a cornerstone of any repetitive batch operation (import, analysis, graphing and graph export).
Substitution in Origin occurs in these four important places:
When a script is executed, it is sent to the LabTalk interpreter. Among other tasks, the interpreter searches for special substitution notations, which are identified by their initial characters, % or $. When such substitution notation is found, the interpreter replaces the original string with another string. The value of the substituted string is unknown until the statement is actually executed. Thus, this procedure is called a run-time string substitution.
There are four types of run-time substitutions: