14.3.4 Addition of elements of a column of a matrix
The sum command (see also Section 13.3.3) can add the
elements of the columns of a matrix.
-
sum takes
A, a matrix.
- sum(A) returns the list whose elements are the sum
of the elements of each column of the matrix A.
Example