Development Environment    

Preferences for Command History

Using Command History preferences, you can choose to exclude statements from the Command History and specify how often to save the Command History.

To set preferences for the Command History, select Preferences from the File menu in the Command History window. The Preferences dialog box opens showing Command History Preferences.

You can set preferences for

Settings

Set the following options. Note that if you choose to exclude statements from the Command History, you cannot access them using Command Window features such as Recalling Previous Lines.

Save exit/quit commands.   Select the check box if you want exit and quit commands to be saved to the Command History.

Save consecutive duplicate commands.   Select the check box if you want consecutive executions of the same statement to be saved to the Command History.

For example, with this option selected, if you run magic(5), and the next statement you run is also magic(5), the Command History saves two consecutive entries for magic(5). With this option cleared, for the same example, the Command History saves one entry for magic(5). If you then run magic(10), the Command History saves two entries, magic(5) followed by magic(10).

Save commands entered at input prompt.   Select the check box if you want input supplied at the prompt following the input function to be included in the Command History. For example, with this option selected, if you type

MATLAB displays

If you then enter 500, the Command History saves two statements

With the check box cleared, the Command History saves only one statement, input('Enter maximum: ').

Allow Drag and Drop editing.   If you select this check box, you can drag selected statements from the Command History to the Command Window or other windows docked in the desktop. If you clear this check box, when you click on a selected entry, it becomes cleared.


  Printing the Command History Saving