%Question 1
y=dtmfsig(150006260);
%a
t= linspace(0,0.9,7200)
plot(t,y)
title(\'DTMF time signal\')
xlabel(\'t (sec)\')
ylabel(\' y(t)\' )
% Part B
fLH= [697
The command publish
executes the script whose name is given, and records the output. Your mistake is inserting this command into the script itself. This results in an infinite loop: the script runs, then at the end encounters publish
command, which means it has to run again, so it does, and then encounters publish
, etc.
You should invoke
publish('lab2question1.m','pdf')
from the command window, not from the script itself.