clg
clear
data=getspeech('0af1s1t0.wav');
Fs=12500;
plot(data)
end1=input('end1?')
end2=input('end2?')
datar=data(end1:end2);
clear data
plot(datar)
[d,dsize]=size(datar);
deltaf=Fs/8192;
freq=-Fs/2:deltaf:Fs/2-deltaf;
dftdatar=abs(fftshift(fft(datar,8192)));
plot(freq,dftdatar)
axis([-Fs/2 Fs/2 0 max(dftdatar)])
xlabel('Analog Frequency (Hz)')
ylabel('Spectral Magnitude')
clear freq dftdatar
pause
sound(datar,Fs)
pause
plot(datar)
end1=input('end1?')
end2=input('end2?')
datar2=datar(end1:end2);
plot(datar2)
clear datar2
input('wideband spectrogram')
specgram(datar,512,12500,65,45)
title('wideband spectrogram')
input('narrowband spectrogram')
specgram(datar,1024,12500,650,550)
title('narrowband spectrogram')



