-
Notifications
You must be signed in to change notification settings - Fork 0
/
Pandas_Stats.py
56 lines (40 loc) · 910 Bytes
/
Pandas_Stats.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
import pandas as pd
from pandas import DataFrame
import matplotlib.pyplot as plt
from mpl_toolkits.mplot3d import Axes3D
df = pd.read_csv('Lite_Coin_12_Mos.csv')
print(df.head())
print(df.tail())
print(df.index)
print(df.columns)
print("-----")
print(df.describe())
#print mediuan
print('median')
print(df.median())
print("-----")
#Mode
print('mode')
print(df.mode())
print("-----")
#Variance
##In probability theory and statistics, variance is the expectation of the squared deviation of a random variable from its mean.
##Informally, it measures how far a set of numbers are spread out from their average value.
print('variance')
print(df.var())
print("-----")
#Co-Variance
print('co-variance')
print(df.cov())
#Cumsum
#print('Cumsum')
#print(df.cumsum())
#Scalar Map
#print('Map')
#print(df.applymap())
#Multiply
#print('Multiply')
#print(df.mul())
#Modulo
#print('Modulo')
#print(df.mod())