blob: 0ff5b2527a9bff801b242c62ae88e603434cb873 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
function nan_stdev()
x=[%nan 0.121 %nan 0.5 0.8; 21.9 %nan 1 0.9812 %nan; 0.12 0.65 1.08 12 0.1621; %nan 12 24 1 12]
disp('Double')
disp(nanstdev(x))
disp('')
disp(nanstdev(x , 'r'))
disp('')
disp(nanstdev(x, 'c'))
disp('')
y= float(x)
disp('Float')
disp(nanstdev(y))
disp('')
disp(nanstdev(y , 'r'))
disp('')
disp(nanstdev(y, 'c'))
disp('')
endfunction
|