📜  pandas 规范化列 - Python 代码示例

📅  最后修改于: 2022-03-11 14:45:23.380000             🧑  作者: Mango

代码示例2
import pandas as pd
from sklearn import preprocessing

x = df.values #returns a numpy array
min_max_scaler = preprocessing.MinMaxScaler()
x_scaled = min_max_scaler.fit_transform(x)
df = pd.DataFrame(x_scaled)