MATLAB: Vectors need to be same length

plotvectors

%%Plotting
time = (0:fps:length(fz)-fps)';
figure(i);
plot (time,fz);
For some reason I cannot get this to work, I have tried to specify that the time has to be the same length as the variable fz starting at 0.
fps = frames per second which is a value of 0.001

Best Answer

time = fps*(0:(length(fz)-1))'