Average of numbers in two consequetive sequences using Matlab
问题 I have an array that is 13867 X 2 elements and stored in variable called "data". So, I want to do the following in Matlab: Average (row 1 -> row 21) ; i.e. take the average of first 21 elements Average (row 22 -> row 43) ; i.e. take the average of next 22 elements Average (row 44 -> row 64); i.e. take the average of the next 21 elements Average (row 65 -> row 86); i.e. take the average of the next 22 elements Repeat the process until the end of the matrix, so that we take the average of the