Use row and column matrices of ones to extract totals
The data matrix \(Q\) gives the numbers of results recorded by several sports teams, with one row for each team and one column for each result type
Row order: Wallabies, Kookaburras, Eagles, Falcons. Column order: Bonus points, Draws
\[Q = \begin{bmatrix} 1 & 10 \\ 6 & 6 \\ 11 & 1 \\ 4 & 11 \end{bmatrix}\]
The following row and column matrices of 1s are available
\[R = \begin{bmatrix} 1 & 1 & 1 & 1 \end{bmatrix}, \qquad C = \begin{bmatrix} 1 \\ 1 \end{bmatrix}\]