from
sifReader - Read Andor Newton .sif files into matlab.
by Todd Karin
Read sif files generated by an Andor Newton camera into matlab.
|
| increaseAxisResolution(v,n) |
%INCREASEAXISRESOLUTION
%
% increaseAxisResolution(v,n) returns a vector with (n-1) points interpolated
% between every two elements of v.
%
%
function w= increaseAxisResolution(v,n)
% Start out by setting every n'th point to being the same as the original
% vector.
setAx = 1:n:(n*length(v));
w(setAx)=v;
setAx = 1:n:( n*(length(v)-1));
% Set the middle points to linearly space.
d = diff(v);
for j=1:(n-1)
w(setAx+j) = v(1:(end-1))+d*j/n;
end
|
|
Contact us