Filter specific frequencies in an audio file

20 visualizaciones (últimos 30 días)
William Osborne
William Osborne el 12 de En. de 2019
Comentada: Kavy Jain el 7 de Sept. de 2020
Hello,
First time asking a question on here as I have hit that brick wall now.
I am trying to filer an audio signal that I have, for example I only want to know between 100 and 1000 Hz, instead of the whole thing. I can try a limit of the axis, but of course the data is still there when I further process it.
I have read through many, many, many examples on here and can't seem to figure it out at all. I have looked at bandpass filtering, something to do with butter....
My code uses a FFT to look at the full frequency spectrum, with the audio clip available at http://bit.ly/2RlPl6p . This is just the FFT, I haven't included any filering bits.
File = 'Loud.wav';
[x,fs] = audioread(File);
lpad = 8*length(x);
xdft = fft(x,lpad);
xdft = xdft(1:lpad/2+1);
xdft = xdft/length(x);
xdft(2:end-1) = 2*xdft(2:end-1);
freq = 0:fs/lpad:fs/2;
plot(freq,(abs(xdft)));
hold on
xlabel('Hz')
xlim([0,16000])
ylim([0,3e-3])
ylabel('Amplitude')
hold off
Any help at all would be greatly appreciatied!
(I am not a student doing homework)
P.s.
This is the wav file stats.
SampleRate: 48000
TotalSamples: 513984
Duration: 10.7080
Title: []
Comment: []
Artist: []
BitRate: 63.1170

Respuesta aceptada

Star Strider
Star Strider el 12 de En. de 2019
If you have R2018a or later, use the bandpass (link) function.
If you want to filter it in the frequency domain, see the documentation for the fftfilt (link) function.
  14 comentarios
dulanga
dulanga el 17 de Abr. de 2019
sorry i will
Kavy Jain
Kavy Jain el 7 de Sept. de 2020
can somebody plz help me how to extract a given audio signal from set of audio signals

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Audio Processing Algorithm Design en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by