% single cell tracking XY09

clear all

b(1:100,1:2,1:10)=0;

for k=1:10
for i=1:100

    figure(1)
    datafile=strcat('190113_NHBE_distributed_DQ_T0',num2str(2*i-1,'%03g'), '_XY09_CH4.tif');
    imdata=imread(datafile);
    image(imdata);
    b(i,:,k)=ginput(1);
    
end
    for j=2:100
    figure(3)
    quiver(b(j-1,1,k),(b(j-1,2,k)),(b(j,1,k)-b(j-1,1,k)),(b(j,2,k)-b(j-1,2,k)),1, 'color','r', 'linewidth',1.5, 'maxheadsize', 0);hold on
    axis([0 680 0 480])
    end

end


k=10;
    for j=2:100
    figure(3)
    quiver(b(j-1,1,k),(b(j-1,2,k)),(b(j,1,k)-b(j-1,1,k)),(b(j,2,k)-b(j-1,2,k)),1, 'color',[0.8500 0.3250 0.0980], 'linewidth',1.5, 'maxheadsize', 0);hold on
    axis([0 680 0 480])
    end
