我在努力利用自动数据集扩大数据。
import matplotlib.pyplot as plt
import pandas as pd
import numpy as np
import seaborn as sns
%matplotlib inline
data = pd.read_csv( data.csv , nrows=50000)
data.head()
from sklearn.preprocessing import StandardScaler
scaler = StandardScaler()
scaler.fit(data)
scaled_data = scaler.transform(data)
scaled_data.head()
一如操作守则,总是有同样的错误。
---------------------------------------------------------------------------
AttributeError Traceback (most recent call last)
~AppDataLocalTemp/ipykernel_13244/2182372482.py in <module>
----> 1 scaled_data.head()
AttributeError: numpy.ndarray object has no attribute head
Anyone know how I can fix this?