function out = sliding(data, T)
K = size(data,1) - T;   % Number of repetitions

out = zeros(K,2);
for i = 1:K    
window = data(i:i+T-1,:);
out(i,1) = mean(window);
out(i,2) = var(window);
end
