skewness
- property AssetList.skewness
Compute expanding skewness of the return time series for each asset returns.
Skewness is a measure of the asymmetry of the probability distribution of a real-valued random variable about its mean. The skewness value can be positive, zero, negative, or undefined.
For normally distributed returns, the skewness should be about zero. A skewness value greater than zero means that there is more weight in the right tail of the distribution.
- Returns:
- Dataframe
Expanding skewness time series for each asset.
See also
skewness_rollingCompute rolling skewness.
kurtosisCalculate expanding Fisher (normalized) kurtosis.
kurtosis_rollingCalculate rolling Fisher (normalized) kurtosis.
jarque_beraPerform Jarque-Bera test for normality.
kstestPerform Kolmogorov-Smirnov test for different types of distributions.
Examples
>>> import matplotlib.pyplot as plt
>>> al = ok.AssetList(["VFINX.US", "GC.COMM"], last_date="2021-01") >>> al.names {'VFINX.US': 'VANGUARD 500 INDEX FUND INVESTOR SHARES', 'GC.COMM': 'Gold'} >>> al.skewness.plot() >>> plt.show()