Navigation

Operators and Keywords

Function List:

C++ API

: val = PS2 ()
: old_val = PS2 (new_val)
: PS2 (new_val, "local")

Query or set the secondary prompt string.

The secondary prompt is printed when Octave is expecting additional input to complete a command. For example, if you are typing a for loop that spans several lines, Octave will print the secondary prompt at the beginning of each line after the first. The default value of the secondary prompt string is "> ".

When called from inside a function with the "local" option, the variable is changed locally for the function and any subroutines it calls. The original variable value is restored when exiting the function.

See also: PS1, PS4.

Package: octave