Anonymous user
Cumulative standard deviation: Difference between revisions
m
Added small COBOL example. Corrected PL/I and R lang tags.
(Added COBOL example.) |
m (Added small COBOL example. Corrected PL/I and R lang tags.) |
||
Line 472:
Using an intrinsic function:
<lang cobol>FUNCTION STANDARD-DEVIATION(2, 4, 4, 4, 5, 5, 7, 9)</lang>
The implementation of this based of the standard's implementation:
<lang cobol>FUNCTION SQRT(FUNCTION VARIANCE(2, 4, 4, 4, 5, 5, 7, 9))</lang>
=={{header|CoffeeScript}}==
Line 1,771 ⟶ 1,774:
=={{header|PL/I}}==
<lang
declare A(200) float;
declare ap fixed binary;
Line 1,991 ⟶ 1,994:
=={{header|R}}==
===Built-in Std Dev fn===
<lang
#If na.rm is true, missing data points (NA values) are removed.
reverseBesselCorrection <- function(x, na.rm=FALSE)
Line 2,003 ⟶ 2,006:
reverseBesselCorrection(testdata)*sd(testdata) #2</lang>
===From scratch===
<lang
uncorrectedsd <- function(x, na.rm=FALSE)
{
|