e(0,Fs,2*Nf - 1);

figure;
plot(freq,Sx,<span class="string">'-.b'</span>,freq,Sxest,<span class="string">'r'</span>,<span class="string">'linewidth'</span>,2);
xlabel(<span class="string">'Frequency (Hz)'</span>);ylabel(<span class="string">'Spectrum'</span>);
grid <span class="string">on</span>; axis <span class="string">tight</span>;
legend(<span class="string">'True spectrum'</span>,<span class="string">'Estimated spectrum'</span>);
V=axis; axis([300 1600 0 V(4)]);
</pre><img vspace="5" hspace="5" src="