How to resample a data file using specific indices? And not using the resample function
3 views (last 30 days)
Show older comments
The resampling index goes from [1:2:70000]. How do I incorporate this into data file (70000x1) to resample it?
Because of this problem I'm having difficulty creating a function to resample any general data that lets the user change the factor of steps in which the signal is resampled (in this case 2) with resampled signal and resampled Sr as output. Any leads on that also?
So far I have something messy... And it also includes the resample function which I need to change
% manufactures steps for resampling a clip
function [newclip, Sr] = generateresample (levels, Nsteps, Nsamples, originalsteps, originalSr, timeformeasurement)
levels = [1:Nsteps:Nsamples];
resampleclip = resample(data,1,Nsteps);
timeformeasurement = originalsteps/originalSr;
Sr = Nsteps/timeformeasurement;
end
end
But I think this needs too much input and I also don't know how to link it all together under the function
0 Comments
Answers (0)
See Also
Categories
Find more on Multirate Signal Processing in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!