scipy.stats.sem (arr, axis = 0, ddof = 0) is used to compute the standard error of the mean of the input data.
Parameters:
arr: [array_like] Input array or object having the elements to calculate the standard error.
axis: Axis along which the mean is to be computed. By default axis = 0.
ddof: Degree of freedom correction for Standard Deviation.Results: standard error of the mean of the input data.
Example :
|
Output:
arr1: [[20, 2, 7, 1, 34], [50, 12, 12, 34, 4]] arr2: [50, 12, 12, 34, 4] sem ratio for arr1: [10.60660172 3.53553391 1.76776695 11.66726189 10.60660172] sem ratio for arr1: [5.62423328 7.61892381] sem ratio for arr1: 7.618923808517841 <>