Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NBinomial and Hurdle broken for highly skewed data #88

Closed
hofnerb opened this issue Dec 28, 2017 · 0 comments
Closed

NBinomial and Hurdle broken for highly skewed data #88

hofnerb opened this issue Dec 28, 2017 · 0 comments

Comments

@hofnerb
Copy link
Member

@hofnerb hofnerb commented Dec 28, 2017

For highly skewed data, NBinomial cannot compute the offset:

x <- rnorm(100)
y <- rnbinom(length(x), size = 2, mu = exp(x * 5))
mod <- glmboost(y ~ x, family = NBinomial())
## Error in basefit(u, m) : 
##   could not fit any base-learner in boosting iteration 1
## In addition: There were 50 or more warnings (use warnings() to see the first 50)

warnings()
## Warning messages:
## 1: In optimize(risk, interval = range(y), y = y, w = w) :
##   NA/Inf replaced by maximum positive value
## ...

Same for Hurdle:

x <- x[y > 0]
y <- y[y > 0]
mod <- glmboost(y ~ x, family = Hurdle())
## Error in basefit(u, m) : 
##   could not fit any base-learner in boosting iteration 1
## In addition: There were 50 or more warnings (use warnings() to see the first 50)

warnings()
## Warning messages:
## 1: In optimize(riskS, interval = range(y), y = y, w = w) :
##   NA/Inf replaced by maximum positive value
## ...
@hofnerb hofnerb closed this in 4972f8f Dec 28, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
1 participant
You can’t perform that action at this time.