Installation guide
3 Running Functions — Command Window and History
one entry for magic(5). If you then run magic(10), the command history file
saves both entries,
magic(5) followed by magic(10).
Saving
Use Saving preferences to s pecify how often to automatically save the
history.m file during a M ATLAB session.
Save History File On Quit
Select this option to save the history.m file when you end the MATLAB
session. If the sessio n does not end via a normal termination, that is, via the
exit or quit functions, File > Exit MA TLAB, or the MATLAB desktop Close
box, the history file is not saved for that s ession.
Save After n Commands
Select this option to save the history.m file after n statements are added to
the file. For example, when you select the option and set
n to 10, after every
10 statements are added, the history file is automatically saved. Use this
option if you don’t want to risk losing entries to the saved history because of
an abnormal termination, such as a power failure.
Don’t Save History File
Select this option if you do not want to save the history.m file. Thi s feature is
useful when multiple users share the same machine and do n ot want other
users to view the statements they have run.
Note that any entries already in the
history.m fi le remain. Prior to setting
this preference, you might want to remove any existing entries. Follow the
instructions in “Deleting Entries from the Command History Window” on
page 3-57.
See Also
Additional preferences that relate to the Command History are
• “Fonts Preferences for Desktop Tools” on page 2-62
• “C onfirmation Dialogs Preferences” on page 2-81
3-60