Cannot set a frame with no defined index and a value that cannot be converted to a Series

  • ValueError: Cannot set a frame with no defined index and a value that cannot be converted to a Series
  • 不能設置沒有定義的索引的frame對象和沒有被轉換爲Series的值
  • 錯誤代碼:
df['PREDICT'] = df.apply(self.__predict, axis=1)
  • 錯誤原因:df對象是空值Empty DataFrame
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章