MATLAB: Input Variable storage audio file

errorif statementinput variablestoragestorevariablevariable storagevariables

I would like to store the audio file in the "input_Signal so it can be modulated . any ideas ?
load gong;
[y,Fs]=audioread('gong.wav');
Input_Signal=
%
beginFreq = 1000 / (Fs/2);
endFreq = 4000 / (Fs/2);
[b,a] = butter(Order, [beginFreq, endFreq], 'bandpass');
% Bandpass
Signal = filter(b, a, Input_Signal);

Best Answer

Starting with:
v = load('gong.mat');
audiowrite('gong.wav',v.y,v.Fs);
I would do either:
[y,Fs]=audioread('gong.wav');
Input_Signal = y;
or:
[Input_Signal,Fs]=audioread('gong.wav');
Both of these should work.
With respect to the rest, see the buttord and filtfilt function documentation for some valuable hints on how to filter a signal correctly.
.
Related Question