Cumulative standard deviation: Difference between revisions

Add Scilab section
(→‎{{header|360 Assembly}}: remove useless instructions)
(Add Scilab section)
Line 2,561:
(sqrt (- (/ (apply + (map (lambda (i) (* i i)) nums)) (length nums)) (expt (/ (apply + nums) (length nums)) 2))))
</lang>
 
=={{header|Scilab}}==
Scilab has the '''stdev''' to compute the standard deviation of a sample so it is straightforward to have the standard deviation of a sample with a correction of the bias.
<lang>
T=[2,4,4,4,5,5,7,9];
stdev(T)*sqrt((length(T)-1)/length(T))
</lang>
{{out}}
<pre>
-->T=[2,4,4,4,5,5,7,9];
-->stdev(T)*sqrt((length(T)-1)/length(T))
ans = 2.
</pre>
 
 
 
=={{header|Smalltalk}}==
1,392

edits