From fb72c2abcb64dccbeb7108c74486a3375cd2523c Mon Sep 17 00:00:00 2001 From: Alyssa Frazee Date: Fri, 29 Jan 2021 12:10:29 -0800 Subject: [PATCH 1/2] round predictions to 3 digits --- R/model-xgboost.R | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/R/model-xgboost.R b/R/model-xgboost.R index cb8ada38..0d838a00 100644 --- a/R/model-xgboost.R +++ b/R/model-xgboost.R @@ -116,7 +116,7 @@ get_xgb_case <- function(path, prediction, digits = NA) { get_xgb_case_tree <- function(tree_no, parsedmodel, digits = NA) { purrr::map( parsedmodel$trees[[tree_no]], - ~ get_xgb_case(.x$path, .x$prediction, digits) + ~ get_xgb_case(.x$path, round(.x$prediction, 3), digits) ) } From fc9c1a47a9bbab5c803623546ce155a44850db36 Mon Sep 17 00:00:00 2001 From: Alyssa Frazee Date: Fri, 29 Jan 2021 12:12:28 -0800 Subject: [PATCH 2/2] the tiniest version bump --- DESCRIPTION | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index 9bb0e0da..ffc5407f 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,12 +1,12 @@ Package: tidypredict -Version: 0.4.8.9000 +Version: 0.4.8.9001 Title: Run Predictions Inside the Database Description: It parses a fitted 'R' model object, and returns a formula in 'Tidy Eval' code that calculates the predictions. It works with several databases back-ends because it leverages 'dplyr' and 'dbplyr' for the final 'SQL' translation of the algorithm. It currently supports lm(), glm(), randomForest(), ranger(), earth(), xgb.Booster.complete(), - cubist(), and ctree() models. + cubist(), and ctree() models. Authors@R: person("Max", "Kuhn", email = "max@rstudio.com", role = c("aut", "cre")) Depends: