matlab - interp1 output not consistent -
Then I have this function that I have modified a bit which is the "main" vector and the "base" vector and the spread / base Compress the main vector in the dimensions of the vector.
function output = stretch (main, base) N = length (main) -1; X = 0: Not Applicable; Xi = 0: (length (main) / length (base)): not applicable; Production = interp1 (x, main, xi); End The base vector always has a length of 1620, so the goal is. It works most of the time, but for some "main" vector dimensions, the vectors of the spreading / compressed vector are 1619 or 1618. I have no idea how to improve it - any thoughts?
@ David wrote:
Use Linspace (intialValue, finalValue, numberOfElements) not initial value: increment: final value
Comments
Post a Comment