In descriptive statistics, summary statistics are used to summarize a set of observations, in order to communicate the largest amount of information as simply as possible. Statisticians commonly try to describe the observations in
- a measure of location, or central tendency, such as the arithmetic mean.
- a measure of statistical dispersion like the standard deviation.
- a measure of the shape of the distribution like skewness or kurtosis.
- if more than one variable is measured, a measure of statistical dependence such as a correlation coefficient.
NumPy has quite a few useful statistical functions for calculating sum, mean, standard deviation and variance, etc. from the given elements in the array.
import sys import numpy as np
a = np.array([1, 2, 3, 4])
A = np.array([ [1, 2, 3], [4, 5, 6], [7, 8, 9] ])