function [data] = averageLFP( wave );

s1 = wave(1:1000,2:65);
s2 = wave(1001:2000,2:65);
s3 = wave(2001:3000,2:65);
s4 = wave(3001:4000,2:65);
s5 = wave(4001:5000,2:65);
s6 = wave(5001:6000,2:65);
s7 = wave(6001:7000,2:65);
s8 = wave(7001:8000,2:65);
s9 = wave(8001:9000,2:65);
s10 = wave(9001:10000,2:65);

%LFP=(s1+s2+s3+s4+s5+s6+s7+s8+s9+s10);

t = wave(1:1000,1);
for n= 1:64
    subplot (8,8,n); averLFP = mean(s1+s2+s3+s4+s5+s6+s7+s8+s9+s10); plot (t,averLFP(n)); %axis([0 1000 -0.2 0.2]);
end