|
"us " <us@neurol.unizh.ch> wrote in message <h7bg8j$afj$1@fred.mathworks.com>...
> "us "
> > > I would like to modify the code so that it can analyse and plot the music file both from .wav and from a music cd. Furthermore, I would also like to show a waterfall plot of the spectrogram. Can anyone help me or provide me with an example?
> > >
> > > Thanks a million!
> >
> > a hint:
> >
> > help waterfall;
>
> sorry, forgot the ...example... part...
>
> d=load('chirp');
> [ff,ff,tt,pxx]=spectrogram(d.y);
> subplot(2,1,1);
> spectrogram(d.y);
> subplot(2,1,2);
> arg={ff,tt,10*log10(abs([pxx.'])+eps)};
> waterfall(arg{:});
> colormap(jet(256));
>
> us
Hi us,
Tks for the prompt reply. However the above code does not allow me to analyse in term of a music cd. That mean, I would like the script to prompt the user to input in the file to analyse. Currently, my original code is only able to analyse .wav files. However, it wont work for .wma file.
Furthermore, it is possible for the waterfall plot to animate as a function of time when the music is being play?
Pls advise tks.
|