The Command Window

About the Command Window

The Command Window is one of the main tools you use to enter data, run MATLAB functions and other M-files, and display results. If you have an active Internet connection, you can Working in the Development Environment video demo for an overview of the major functionality.

Opening the Command Window

When the Command Window is not open, access it by selecting Command Window from the Desktop menu. Alternatively, open the Command Window with the commandwindow function.

If you prefer a simple command line interface without the other MATLAB desktop tools, select Desktop > Desktop Layout > Command Window Only. For more information, see Arranging the Desktop.

Image of empty MATLAB Command Window

Command Window Prompt

The Command Window prompt, >>, is where you enter statements. For example, you can enter a MATLAB function with arguments, or assign values to variables. The prompt indicates that MATLAB is ready to accept input from you. When you see the prompt, you can enter a variable or run a statement. This prompt is also known as the command line.

When MATLAB displays the K>> prompt in the Command Window, MATLAB is in debug mode. Type dbquit to return to normal mode. For more information, see Editing and Debugging M-Files

MATLAB displays the EDU>> prompt for the MATLAB Student Version.

Changing the Way the Command Window Looks

The Command Window is a desktop tool so you can move it, resize it, and change its font the same way you would any desktop tool. For more information, see Arranging the Desktop. and Fonts Preferences for Desktop Tools.

There are other ways you can change the display of the Command Window, including hiding the message bar and the Function Browser button. To make changes, select File > Preferences > Command Window and use the Display options. For more information, click the Help button in the Preferences dialog box.

  


 © 1984-2008- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS