fix save.raw doc

This commit is contained in:
hetong007 2015-02-09 13:43:32 -08:00
parent 8c16491b42
commit ea5860d574

View File

@ -20,7 +20,7 @@ train <- agaricus.train
test <- agaricus.test test <- agaricus.test
bst <- xgboost(data = train$data, label = train$label, max.depth = 2, bst <- xgboost(data = train$data, label = train$label, max.depth = 2,
eta = 1, nround = 2,objective = "binary:logistic") eta = 1, nround = 2,objective = "binary:logistic")
raw <- xgb.save(bst) raw <- xgb.save.raw(bst)
bst <- xgb.load(raw) bst <- xgb.load(raw)
pred <- predict(bst, test$data) pred <- predict(bst, test$data)
} }