2
我正在玩xgboost,附帶一些財務數據,並希望嘗試使用gamma迴歸作爲目標。R xgboost,gamma迴歸問題
cvs <- xgb.cv(data = sparse_matrix, label = target, nfold = 10, nthread = 4, nround = 16, objective = "reg:gamma", metrics = list("mae"))
但是,這似乎比使用線性迴歸作爲目標要花費更多的時間。
而且還拋出了很多以下警告:
In foldVector[which(y == dimnames(numInClass)$y[i])] <- sample(seqVector) :
number of items to replace is not a multiple of replacement length
此警告重複50次左右。
這是怎麼回事?我不應該使用reg:gamma作爲目標,因爲reg:線性工作得很好,我只是在玩耍,只是想嘗試各種目標
任何人都可以請指出爲什麼會發生這些警告?