关于解决“泰坦尼克船员获救数据分析”的KFold()报错问题。
报错信息:
TypeError: __init__() got an unexpected keyword argument 'n_folds'
报错代码主体如下:
#Import the linear regression class
from sklearn.linear_model import LinearRegression
#Sklearn also has a helper that makes it easy to do cross validation
from sklearn.cross_validation import KFold
#The columns we'll use to predict the target
predictors = ["Pclass",