Professional Documents
Culture Documents
...
In [9]: mba
...
Standardization
In [11]: from sklearn import preprocessing
# scaler is function using to create the standard function
scaler = preprocessing.StandardScaler()
In [12]:
mba1 = scaler.fit(mba) # applied on the data set
mba1 = scaler.transform(mba) # it wil conver the values into scaled data
In [13]: mba1
[ 1.80853813, -2.42709832],
[-0.01833968, 0.98345794],
...,
[-1.07792881, -3.4502652 ],
[-1.73560482, -3.4502652 ],
[-0.20102746, -3.10920957]])
In [14]: mba1 = pd.DataFrame(mba1, columns=names)
In [15]: mba1
...
In [17]: mba2
...
...
In [26]: mba3
[0.36296296, 0.22222222],
[0.17777778, 0.77777778],
...,
[0.07037037, 0.05555556],
[0.0037037 , 0.05555556],
[0.15925926, 0.11111111]])
In [27]: mba3 = pd.DataFrame(mba3, columns=names)
In [28]: mba3
...
In [30]: mba4
...
In [ ]: