| Products & Services | Solutions | Academia | Support | User Community | Company |
| Download Product Updates | | | Get Pricing | | | Trial Software |
| Documentation → MATLAB |
| Contents | Index |
| Learn more about MATLAB |
As an alternative to the dbtype function, you can see an M-file with line numbers by opening it in the Editor.
dbtype mfilename
dbtype mfilename start:end
The dbtype command is used to list an M-file with line numbers, which is helpful when setting breakpoints with dbstop.
dbtype mfilename displays the contents of the specified M-file, with the line number preceding each line. mfilename must be the full path name of an M-file, or a MATLAB relative partial path.
dbtype mfilename start:end displays the portion of the M-file specified by a range of line numbers from start to end.
You cannot use dbtype for built-in functions.
To see only the input and output arguments for a function, that is, the first line of the M-file, use the syntax
dbtype mfilename 1
For example,
dbtype fileparts 1
returns
1 function [path, fname, extension,version] = fileparts(name)
dbclear, dbcont, dbdown, dbquit, dbstack, dbstatus, dbstep, dbstop, dbup
![]() | dbstop | dbup | ![]() |

Includes the most popular MATLAB recorded presentations with Q&A sessions led by MATLAB experts.
| © 1984-2009- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |