clear; clc;

a = [1,2,3,4,5];

% returns the median of matrix b. b  3
b = median(a);

c = [1,2,3;4,5,6;7,8,9];

% median of each column of matrix c. d   [4,5,6]
d = median(c,1);

% median of each row of matrix c.   e   [2;5;8]
e = median(c,2);

% standrad deviation of matrix a. f   1.581138830084190
f = std(a);

% standrad deviation column wise. g 1.414213562373095
g = std(a,1);

% standrad deviation row wise. h  1.581138830084190
h = std(a,[],2);

% max element of matrix B. i 3
i = max(b);

results matching ""

    No results matching ""