diff --git a/R-package/DESCRIPTION b/R-package/DESCRIPTION index 33258bf5c..e57ccc451 100644 --- a/R-package/DESCRIPTION +++ b/R-package/DESCRIPTION @@ -18,7 +18,7 @@ License: Apache License (== 2.0) | file LICENSE URL: https://github.com/tqchen/xgboost BugReports: https://github.com/tqchen/xgboost/issues Depends: - R (>= 2.0.2) + R (>= 2.10) Imports: Matrix (>= 1.1-0), methods diff --git a/R-package/R/xgboost.R b/R-package/R/xgboost.R index a08ca3fa8..bf8cd96a6 100644 --- a/R-package/R/xgboost.R +++ b/R-package/R/xgboost.R @@ -33,9 +33,14 @@ #' Number of threads can also be manually specified via "nthread" parameter #' #' @examples -#' data(iris) -#' bst <- xgboost(as.matrix(iris[,1:4]),as.numeric(iris[,5]=='setosa'), nrounds = 2) -#' pred <- predict(bst, as.matrix(iris[,1:4])) +#' data(agaricus.train, package='xgboost') +#' data(agaricus.test, package='xgboost') +#' train <- agaricus.train +#' test <- agaricus.test +#' bst <- xgboost(data = train$data, label = train$label, max.depth = 2, +#' eta = 1, nround = 2,objective = "binary:logistic") +#' pred <- predict(bst, test$data) +#' #' @export #' xgboost <- function(data = NULL, label = NULL, params = list(), nrounds, diff --git a/R-package/data/README.md b/R-package/data/README.md deleted file mode 100644 index d2d63ec11..000000000 --- a/R-package/data/README.md +++ /dev/null @@ -1,2 +0,0 @@ -This folder contains processed example dataset used by the demos. -Copyright of the dataset belongs to the original copyright holder