how to do this Python interpolation in MATLAB?

3 views (last 30 days)
I need to convert this piece of Python code in MATLAB, but I can't seem to figure out how to do this.
T = 1968, F = 1025, used_freq = 22050, freqs = 1621 x 1 vector, log_scale_spec = 1968 x 1025 matrix, cent_spec was initialized with zeros = 1968 x 1621 matrix, and the "linspace(0, used_freq, F)" operation gives a 1025 x 1 vector
The interpolation seems to be a cubic (k = 3).
I just don't know how to structure all of this together as a for loop in MATLAB. I tried something like this so far:
The f represents the operation " linspace(0, used_freq, F)' " Notice in Matlab, it has to be transposed with ' .

Answers (0)

Community Treasure Hunt

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

Start Hunting!