Skip to content
Permalink
7e21b7a1e3
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
 
 
Cannot retrieve contributors at this time
13 lines (10 sloc) 251 Bytes
function [T] = average_c(A, b)
%% obtain the average vector on bth column of each cell A's.
maxiter = size(A, 2);
T = zeros(maxiter, 1);
for i = 1 : maxiter
temp = A{1,i};
sz = size(temp(:, b), 1);
T(i, 1) = sum(temp(:, b))/sz;
end
end