cc Licensed under the Creative Commons attribution-noncommercial license. Please share & remix noncommercially, mentioning its origin.

what does it do?

how does it work?

speed (negative binomial model)

example

library(glmmTMB)
data("Owls", package="glmmTMB")
owls_nb1 <- glmmTMB(SiblingNegotiation ~ FoodTreatment*SexParent +
                      (1|Nest)+offset(log(BroodSize)),
                    family = nbinom1(), zi = ~FoodTreatment,
                    data=Owls)
summary(owls_nb1)
##  Family: nbinom1  ( log )
## Formula:          
## SiblingNegotiation ~ FoodTreatment * SexParent + (1 | Nest) +  
##     offset(log(BroodSize))
## Zero inflation:                      ~FoodTreatment
## Data: Owls
## 
##      AIC      BIC   logLik deviance df.resid 
##   3362.1   3397.2  -1673.0   3346.1      591 
## 
## Random effects:
## 
## Conditional model:
##  Groups Name        Variance Std.Dev.
##  Nest   (Intercept) 0.07494  0.2738  
## Number of obs: 599, groups:  Nest, 27
## 
## Overdispersion parameter for nbinom1 family (): 4.15 
## 
## Conditional model:
##                                     Estimate Std. Error z value Pr(>|z|)
## (Intercept)                          0.77414    0.10092   7.671  1.7e-14
## FoodTreatmentSatiated               -0.46446    0.15175  -3.061  0.00221
## SexParentMale                       -0.04554    0.10071  -0.452  0.65115
## FoodTreatmentSatiated:SexParentMale  0.17456    0.17104   1.021  0.30745
##                                        
## (Intercept)                         ***
## FoodTreatmentSatiated               ** 
## SexParentMale                          
## FoodTreatmentSatiated:SexParentMale    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Zero-inflation model:
##                       Estimate Std. Error z value Pr(>|z|)    
## (Intercept)            -2.3761     0.2823  -8.416  < 2e-16 ***
## FoodTreatmentSatiated   1.5839     0.3133   5.056 4.28e-07 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
tidy(owls_nb1)
## # A tibble: 7 x 8
##   effect  component group term       estimate std.error statistic   p.value
##   <chr>   <chr>     <chr> <chr>         <dbl>     <dbl>     <dbl>     <dbl>
## 1 fixed   cond      <NA>  (Intercep…   0.774      0.101     7.67   1.70e-14
## 2 fixed   cond      <NA>  FoodTreat…  -0.464      0.152    -3.06   2.21e- 3
## 3 fixed   cond      <NA>  SexParent…  -0.0455     0.101    -0.452  6.51e- 1
## 4 fixed   cond      <NA>  FoodTreat…   0.175      0.171     1.02   3.07e- 1
## 5 fixed   zi        <NA>  (Intercep…  -2.38       0.282    -8.42   3.89e-17
## 6 fixed   zi        <NA>  FoodTreat…   1.58       0.313     5.06   4.28e- 7
## 7 ran_pa… cond      Nest  sd__(Inte…   0.274     NA        NA     NA

what to worry about?