Installation guide
Entering Statements in the Edito r/Debugger
• Reverse Case to change the case of each letter
This is useful, for example, when copying syntax from help in an M-file, where
function and variable names are distinguished by the use of uppercase. But
becauseofthat,thecodewillnotruninMATLAB.Inthisexample,thetext
was copied and pasted from the output of
help get.
V = GET(H, 'Default')
Select all of the text. Select Text > Change to Lower Case.Thetext
becomes
v = get(h, 'default')
If instead you select Reverse Case for
V = GET(H, 'Default')
thecasechangesto
v = get(h, 'dEFAULT')
Undo and Redo
Yo u can undo many of the Editor/Debugger actions listed in Edit and Text
menus. Select Ed it > Undo. You can undo multiple times in succession
until there are no remaining actions to undo. Select Edit > Redo to reverse
an undo.
Adding Comments
Comments in an M-file are strings or statements that do not execute. Add
comments in an M-file to describe the code or how to use it. Comments
determinewhattextdisplayswhenyourun
help for a filename. U se
comments when testing your files or looking for errors—temporarily turn
lines of code into comments to see how the M-file runs without those lines.
These topics provide details:
• “Commenting in M-Files Using the MATLAB Editor/Debugger” on page
6-16
6-15