【发布时间】:2019-09-08 04:40:30
【问题描述】:
在使用 python 将数据拆分为训练和测试时,我收到以下错误
" too many values to unpack (expected 3)"
这是我的代码:
from sklearn.model_selection import train_test_split
X_train, X_test, y_train = train_test_split(features,prices, test_size=0.2, random_state=10)
print("Training and testing split was succesful")
这是预期的输出:'Training and testing split was successful'。
【问题讨论】:
-
能否提供更完整的错误日志?
-
我已经解决了,谢谢
标签: python logistic-regression