The functions described in Section 14.5.1 can also find finds statistics for the columns of a matrix.
Let A be a matrix.
The output is a matrix, its first row is the minima of each column, its second row is the first quartiles of each column, its third row the medians of each column, its fourth row the third quartiles of each column and its last row the maxima of each column.
With
A:=[[3,4,2],[1,2,6]] |
input:
mean(A) |
|
stddev(A) |
|
stddevp(A) |
|
variance(A) |
|
With
B:=[[6,0,1,3,4,2,5],[0,1,3,4,2,5,6],[1,3,4,2,5,6,0], [3,4,2,5,6,0,1],[4,2,5,6,0,1,3],[2,5,6,0,1,3,4]] |
input:
median(B) |
|
To obtain the first quartiles of the columns:
quantile(B,0.25) |
|
To obtain the third quartiles of the columns:
quantile(B,0.75) |
|
quartiles(B) |
|
boxwhisker(B) |