Global 

Global


variable

A character string that satisfies the naming conventions for variables.

This argument should not be an expression. If you really need to update a variable of which the name can only be constructed at run time, then use a construction like the following:

For i From 1 To n Do
   Global {`M`/string(i)}=i
Enddo

Note that this will considerably slow down execution of the loop since the expression will be translated at every iteration rather than just once.


value

The value you wish to give to your global variable must have one of the following formats:

To enter a set of numbers into a Matrix, one would normally use the Vector statement even though one can also use the Global command as illustrated in one of the examples below.

Examples:

Global abc `abc`              // Assigns a string to ABC
Global abc 2<3                // Assigns a logical to ABC
Global abc string(2+3)/abc    // Updates the ABC string
Global abc 1 & 5 & 7          // Assigns a vector to ABC

Go to the top level, to Global, to the topic index, to the table of contents, or to the full text.

Formatted on 21/01/18 at 16:55.