How to put wav file as input argument of a function ?

1 visualización (últimos 30 días)
Jimmy Wong See Woei
Jimmy Wong See Woei el 26 de Ag. de 2014
Respondida: W. Owen Brimijoin el 26 de Ag. de 2014
Hi everyone, my problem is how to put wav file as input argument of a function
function[]=down4up4_nofilt(Songbird.wav,Songbird.wav);
There is error in this line of code. The error is happened at the 2 dots in front of wav. And MATLAB error commend is "Possibly, a ) or } or } is missing."
Please help me solve this problem. Thank you,
Jimmy

Respuestas (1)

W. Owen Brimijoin
W. Owen Brimijoin el 26 de Ag. de 2014
You need to load the signal that's in the file 'Songbird.wav' into the Matlab workspace first:
stimulus = audioread('Songbird.wav');
output = down4up4_nofilt(stimulus,stimulus);

Categorías

Más información sobre Startup and Shutdown en Help Center y File Exchange.

Community Treasure Hunt

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

Start Hunting!

Translated by