我将 scikit 库中的内置 boston 数据集加载为:
from sklearn.datasets import load_boston
bdata = load_boston()
我想提取第一列中的所有值,称为 CRIM。我写了这样一行:
plt.scatter(bdata.CRIM,bdata.target,color='blue')
但是我收到一个错误,因为“AttributeError:'Bunch'对象没有属性'CRIM'”
如何访问标题为 'CRIM' 的列的元素?