how to insert an audio file in matlab 2014-a student version?
1 view (last 30 days)
Show older comments
clc;
clear all;
close all;
message = audioread(Macintosh Users , kaushik , Music , ringtonesMetroGnome m4r);
message = message.';
message = message(1,:);
message = resample(message,12000,22868);
size = length(message);
pure_signal = message;
snr = input('enter the SNR value for noise :');
noise = wgn(1,size,snr);
noise_signal = pure_signal + noise;
step_size = input('Enter step size :');
order = input('Enter Order of the filter :');
[weights,final_signal] = lms(noise,noise_signal,step_size,order);
sound(final_signal);
0 Comments
Answers (1)
Geoff Hayes
on 7 Mar 2015
nalajala - what is the problem or error that you are observing? Your line of code that reads the audio data is incorrect
message = audioread(Macintosh Users , kaushik , Music , ringtonesMetroGnome m4r);
You need to pass a string into this function. Try the following instead
message = audioread('~/Music/ringtonesMetroGnome.m4r');
Does the above work or are you still observing an error?
0 Comments
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!