
Ways to Edit, Evaluate, a nd Debug M-Files
Ways to Edit, Evaluate, and D ebug M-Files
There are several methods for creating, editing, evaluating, and debugging
files with MATLAB.
Creating and Editing Files —
Options Instructions
MATLAB Editor/Debugger See “Starting, Customizing, and Closing the
Editor/Debugger” on pag e 6-7, and “Saving, P rintin g,
and Closing Files in the Editor/Debugger” on page 6-62.
You can create, open, edit and save M-files as well a s
other file types in the MATLAB Editor/Debugger — see
“Creating and Editing Other Text File T ypes” on page
6-12.
Any text editor, such as Emacs or vi To specify another editor as the
default for use with M ATLAB, select
File>Preferences>Editor/Debugger,andfor
Editor,specifytheText editor.ClicktheHelp button
in the Preferences dialog box for details. Use that editor
by default, o r use any other e ditor you open. Re gardless
of the editor you use, you can debug M-files using the
MATLAB Editor/Debugger or debugging functions.
Debugging M-Files – Options Instructions
General debugging tips See “Finding Errors, Debugging, and Correcting
M-Files” on page 6-84.
MATLAB Editor/Debugger See
• “M-Lint Code Analyzer” on page 6-87 to identify
errors and make improvements.
• “Debugging Process and Features” on page 6-103 to
help you isolate run-time problems.
MATLAB d
ebugging functions (for use
in the Co
mmand Window)
See function alternatives in “Debugging Process and
Features” on page 6-103.
6-5
Commenti su questo manuale