pub fn std_dev<T, D>(
array: &ArrayView<'_, T, D>,
axis: Option<Axis>,
ddof: usize,
) -> Result<Array<T, Ix1>, &'static str>
Expand description
Calculate the standard deviation of array elements
§Arguments
array
- The input arrayaxis
- Optional axis along which to compute the std dev (None for global std dev)ddof
- Delta degrees of freedom (default 0)
§Returns
The standard deviation of the array elements
§Errors
Returns an error if the array is empty or variance calculation fails.
§Panics
Panics if variance calculation panics.