pandas.core.series.Series 没有 reshape .
pandas.core.series.Series
reshape
也许:
mpg_matrix = mpg.values.reshape(-1,1)
即获取底层 numpy 排列并重新塑形。
numpy