MATLAB: Generation of similar vectors

similar

Hi every one,
I have a vector of points which represents a regressive form (as shown in the attached file). This vector containes 1112 samples and i want to generate similar vectors with the same trend (regressive). However, i want that these vectors have different length (=/= 1112) by knowing tha the threshold is equal to 1.
To summirize, i want to know how to generate vectors with the same trend of the original one bu with different length, exp: 2000, 500, 400, etc. and the final amplitude of each vector is equal to the threshold (1).
Thank you very much for our attention and your help.
Best regards

Best Answer

What about interp1()?
load data.mat
y = data;
x = 1:length(y);
x1 = linspace(x(1),x(end),1000);
y1 = interp1(x,y,x1);
plot(x,y,x1,y1,'r')
Look also for spline()