Questions tagged [gbm]

R package gbm, implementing Generalized Boosted Regression Models library.

R package gbm, implementing Generalized Boosted Regression Models library.

This package implements extensions to Freund and Schapire’s AdaBoost algorithm and Friedman’s gradient boosting machine.

Includes regression methods for least squares,absolute loss, t-distribution loss, quantile regression,logistic, multinomial logistic, Poisson, Cox proportional hazards partial likelihood, AdaBoost exponential loss, Huberized hinge loss, and Learning to Rank measures (LambdaMart).

Who's using gbm?

The gbm package is used in examples in Software for Data Analysis by John Chambers.

gbm is also used in Elements of Statistical Learning by Hastie, Tibshirani and Friedman.

Richard A. Berk also uses gbm in his book, Statistical Learning from a Regression Perspective.

Source: gradientboostedmodels

330 questions
0
votes
1 answer

DeprecationWarning: `h2o.gbm` is deprecated. Use the estimators sub module to build an H2OGradientBoostedEstimator

When running a gbm model using h2o 3.6.0.8 in Python I get the following warning: DeprecationWarning: h2o.gbm is deprecated. Use the estimators sub module to build an H2OGradientBoostedEstimator. I have been looking for an example on how to build…
somesingsomsing
  • 3,182
  • 4
  • 29
  • 46
0
votes
0 answers

Meaning of Null weights for GBM

I have a question about the weights parameter in gbm. It appears that setting weights to NULL and leaving it missing produce different results. If you consider the first example from the gbm documenation: library(gbm) set.seed(1986) N <- 1000 X1 <-…
Carl
  • 5,569
  • 6
  • 39
  • 74
0
votes
1 answer

call gbm model from C++

I've got a gbm object and I want to use it from C++. For example, use the predict.gbm() in C++ with new data. At first I tried to translate the if-else rule in C++ and just output the tree to a file. However, I found that the gbm result doesn't…
Wei Li
  • 35
  • 5
0
votes
1 answer

Output 'h2o' function results to a vector

I have a question similar to this (link) except that my question refers to the java tool 'h2o' and its connection to 'r'. In particular I want to assign a "h2o" object to part of a vector (or structure or array. I want to loop through and store…
EngrStudent
  • 1,924
  • 31
  • 46
0
votes
2 answers

Bernoulli vs Adaboost GBM?

I don't really understand the difference in practical terms of distribution = Adaboost or bernoulli library(MASS) library(gbm) data=Boston data$chas = factor(data$chas) ada_model = gbm(chas~ . , data, distribution ='adaboost') …
runningbirds
  • 6,235
  • 13
  • 55
  • 94
0
votes
1 answer

Using a 'gbm' model created in R package 'dismo' with functions in R package 'gbm'

This is a follow-up to a previous question I asked a while back that was recently answered. I have built several gbm models with dismo::gbm.step, which relies on the gbm fitting functions found in R package gbm, as well as cross validation tools…
GNG
  • 239
  • 2
  • 11
0
votes
0 answers

Error message " input must be grobs!" ( when combining different gbm plots)

I was trying to combine gbm.plot.fit and plot.gbm from different gbm models. Here is my example code: #----------------------ask on stackexchange----------------------------# mydata <-…
0
votes
0 answers

Run gbm in a loop and calculate predicted values for each model in r

I'm trying to make gbm models in a loop in R with different learning rates. I want to calculate a few statistics for each model and combine them with the original data set. But I' having an error due to the fact that each time a statistic is…
0
votes
1 answer

Producing graph of training and validation sets using caret's train function

I am using caret's train function in R to produce a model using GBM. I have used repeated cross-validation with 5 repititions meaning there will be 50 samples. I want to ask if there is a way to plot the results in a different way such that the plot…
syebill
  • 543
  • 6
  • 23
0
votes
2 answers

how to extract coefficients in logistic regression using gbm?

I am using the gbm package for generalized boosted regression models, and would like to be able to extract the coefficients produced for storage in a database. I am already using R to automatically generate formulas that I can export to a…
eunivy
  • 1
  • 1
0
votes
0 answers

Error with the train function in caret when using gbm with custom weights

I am trying to perform parameter tunning for gbm using train function in caret package (RStudio) using custom weights argument and receiving an error. The error is Error in {: task 1674 failed - inputs must be factors The original dataset consists…
syebill
  • 543
  • 6
  • 23
0
votes
2 answers

How to define weights in gbm package & Kappa statistic for class imbalanced data set (gbm)

I would like to find a way to define weights for gbm in caret package. There is a parameter "weights" in the "train" function for "caret" package but the description says "This argument will only affect models that allow case weights". As per my…
syebill
  • 543
  • 6
  • 23
0
votes
1 answer

Does "gbm" package in R has basis functions other than decision tree?

if not, which packages implement multiple basis functions for boosting methods. Thanks a lot.
qegg
  • 33
  • 7
0
votes
0 answers

Choosing a sample rate for GBM models

I've created several GBM models to tune the parameters (trees, shrinkage and depth) to my data and the model performs well on the out-of-time sample. The data is credit card transactions (running into 100s of millions) so I sampled 1% of the good…
Karan
  • 31
  • 1
  • 3
0
votes
1 answer

Error while running varImp(gbm_model)

I'm running gbm model for a classification problem.Below is my code & output library(gbm) library(caret) set.seed(123) train=read.csv("train.csv") gbm_model= gbm(DV~., data=train, distribution = "bernoulli", …
Nim J
  • 993
  • 2
  • 9
  • 15
1 2 3
21
22