function [kinPerSec]=shiftingPos(kin, windowEEG, shift)
    kinPerSec=zeros(fix((max(kin(:,1))-windowEEG*1000)/(shift*1000)),3);
    for j=1:size(kinPerSec,1)
        tmp=mean(kin(kin(:,1)>(j-1)*shift*1000 & kin(:,1)<=(j-1)*shift*1000+windowEEG*1000,2:4));
        i=j;
        while isnan(tmp) %interval is empty
            tmp=mean(kin(kin(:,1)>i*shift*1000 & kin(:,1)<=i*shift*1000+windowEEG*1000,2:4));
            i=i+1;
        end
        kinPerSec(j,:)=tmp;
    end
end