On this page, we will learn how to use Octave from the command line without the GUI window. Sometimes, it’s handy to use the command line to run commands instead of the Octave GUI.
How to launch
To launch Octave, open the Terminal window and Type Octave.
To display Hello World, we can use the disp() function.
For example, to display a string www.TestingDocs.com
Clear command output:
We can type the clc command to clear the previous command’s output on the command window.
Run plot command
We can even run the plot commands from the command line. For example, to display the sombrero hat we can run the following command.
How to Exit
We can use the exit command to exit the Octave command line. The regulat terminal prompt would appear on the screen.