Display file with line numbers
the contents of
filename with line numbers preceding
each line. This is helpful when setting breakpoints in a program file
dbstop. You cannot use
display the source code of built-in functions.
Display the example file
buggy.m with line numbers preceding each line.
1 function z = buggy(x) 2 n = length(x); 3 z = (1:n)./x;
View the input and output arguments for an example function,
buggy, by displaying the first line of the file. Since
end are the same in this case, you can omit the
dbtype buggy 1
1 function z = buggy(x)
filename— File name
File name, specified as a character vector or string scalar. The file name can be a partial path, but it must be in a folder on the search path or in the current folder. Otherwise, specify the full path name.
start— Starting line number
Starting line number, specified as a positive integer.
end— Ending line number
Ending line number, specified as a positive integer.