mirror of
https://github.com/josdejong/mathjs.git
synced 2025-12-08 19:46:04 +00:00
1.0 KiB
1.0 KiB
Function std
Compute the standard deviation of a list of values, defined as the square root of the variance: std(A) = sqrt(var(A)). In case of a (multi dimensional) array or matrix, the standard deviation over all elements will be calculated.
std(a, b, c, ...) std(A) std(A, normalization)
Where normalization is a string having one of the following values:
Parameters
| Parameter | Type | Description |
|---|---|---|
array |
Array | Matrix | A single matrix or or multiple scalar values |
normalization |
String | Default value: 'unbiased' Determines how to normalize the standard deviation: - 'unbiased' (default) The sum of squared errors is divided by (n - 1) - 'uncorrected' The sum of squared errors is divided by n - 'biased' The sum of squared errors is divided by (n + 1) |
Returns
| Type | Description |
|---|
- | res