From: gökan vural on 2 Feb 2010 19:45 Hi dear friends, I wanna take some '.wav' -uncompressed- samples from songs. However, to convert 200 .mp3 file to .wav will take too long time. Therefore, i want to read the files in mp3 format and use them in wav format in matlab. It'll be grateful if anyone helps me about the code..
From: Wayne King on 2 Feb 2010 20:32 "gökan vural" <vural.gkan(a)gmail.com> wrote in message <hkagv1$p1f$1(a)fred.mathworks.com>... > Hi dear friends, > > I wanna take some '.wav' -uncompressed- samples from songs. However, to convert 200 .mp3 file to .wav will take too long time. Therefore, i want to read the files in mp3 format and use them in wav format in matlab. > > It'll be grateful if anyone helps me about the code.. Hi, have you checked the file exchange? http://www.mathworks.com/matlabcentral/fileexchange/13852-mp3read-and-mp3write Wayne
From: gökan vural on 2 Feb 2010 23:53 Thanks for the thread, it's very useful :) If you know, could you tell me how to take the power spectrum of the wav file ?
From: Wayne King on 3 Feb 2010 01:20 "gökan vural" <vural.gkan(a)gmail.com> wrote in message <hkavfh$3ou$1(a)fred.mathworks.com>... > Thanks for the thread, it's very useful :) > > If you know, could you tell me how to take the power spectrum of the wav file ? If you have the Signal Processing Toolbox, you can use spectrum.periodogram, or spectrum.welch to obtain power spectral density (PSD) estimates: Fs=1000; t=0:1/Fs:.3; x=cos(2*pi*t*200)+randn(size(t)); Hper = spectrum.periodogram; HpsdPer = psd(Hper,x,'Fs',Fs); plot(HpsdPer); title('Periodogram'); Hwelch = spectrum.welch; HpsdWelch = psd(Hwelch,x,'Fs',Fs); figure; plot(HpsdWelch); title('Welch'); If you do not have the Signal Processing Toolbox, you can take the absolute value squared of the discrete Fourier transform (using fft() ). You will have to scale that appropriately to get a PSD estimate. Hope that helps, Wayne
From: gökan vural on 5 Feb 2010 14:20 Thanks for above code, but i couldn't obtain what i need exactly.. I'm trying apply stft to a .wav file and obtain such a graphic : http://upload.wikimedia.org/wikipedia/commons/9/9b/Short_time_fourier_transform.PNG Therefore, i'm gonna start my analysis on songs .. King Regards, Gökhan , Cs Student
|
Next
|
Last
Pages: 1 2 Prev: Android apps and Builder JA Next: output variables - GUIDE - varargout |