0 values in glm binomial family with link=logit => do not treat them correctly

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP



0 values in glm binomial family with link=logit => do not treat them correctly



I have this model that run well:


glm(formula = cbind(Number_F, Nbre_dead) ~ Temperature + Population +
Size + Number_I, family = binomial(link = logit), data = marine_data_T2)



Number_F (total of individuals at the end of the experiment) = Number_I (total of individuals at the beginning of the experiment) - Nbre_dead (number of individuals that died). So, data look like this : 6=6-0 (if all individuals survived); 5=7-2 (if two of them died); 8=7-1 (if only one died).



However, when I run the summary of this model and look at the p-values, I think that the model does not work 'correctly':


summary


Call:
glm(formula = cbind(Number_F, Nbre_dead) ~ Temperature + Population +
Size + Number_I, family = binomial(link = logit), data = marine_data_T2)

Deviance Residuals:
Min 1Q Median 3Q Max
-2.56056 0.00008 0.27646 0.63662 1.75879

Coefficients:
Estimate Std. Error z value Pr(>|z|)
(Intercept) -4.0006 1.8824 -2.125 0.033565 *
Temperature20 20.0504 2125.4089 0.009 0.992473
Temperature22.5 2.8416 0.5617 5.059 4.22e-07 ***
Temperature25 3.8333 0.7880 4.865 1.15e-06 ***
Temperature27.5 2.9741 0.5992 4.964 6.92e-07 ***
Temperature30 1.9170 0.5044 3.800 0.000145 ***
PopulationPAC 0.9571 0.6115 1.565 0.117536
PopulationSAR -0.1583 0.5259 -0.301 0.763443
Size6-7mm 2.5652 0.8782 2.921 0.003489 **
Number_I 0.6097 0.2675 2.280 0.022636 *
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1

(Dispersion parameter for binomial family taken to be 1)

Null deviance: 154.626 on 89 degrees of freedom
Residual deviance: 61.112 on 80 degrees of freedom
AIC: 125.82

Number of Fisher Scoring iterations: 18



Indeed, I am completely sure I have a significative difference between 15°C and 20°C (temperature treatments) as I have a 50% mortality at 15°C and 0% at 20°C but I think that because at 20°C I did not have any individual of my experiment that died (consequently, I have Number_dead = 0), the model does not know how to 'react'. I have 6 temperature treatments (15, 20, 22.5, 25, 27.5 and 30°C).



Histogram of mortality



Do you a way to make it work fine ?



I have the same model for another transect (I studied two transects of three populations) and for that one, there was no problem because there were individuals that died in all treatments.



Here are my data:



marine_data_T2 <-
structure(list(Population = c("PAC", "MOR", "SAR", "PAC", "MOR",
"SAR", "PAC", "MOR", "SAR", "PAC", "MOR", "SAR", "PAC", "MOR",
"SAR", "PAC", "MOR", "SAR", "PAC", "MOR", "SAR", "PAC", "MOR",
"SAR", "PAC", "MOR", "SAR", "PAC", "MOR", "SAR", "PAC", "MOR",
"SAR", "PAC", "MOR", "SAR", "PAC", "MOR", "SAR", "PAC", "MOR",
"SAR", "PAC", "MOR", "SAR", "PAC", "MOR", "SAR", "PAC", "MOR",
"SAR", "PAC", "MOR", "SAR", "PAC", "MOR", "SAR", "PAC", "MOR",
"SAR", "PAC", "MOR", "SAR", "PAC", "MOR", "SAR", "PAC", "MOR",
"SAR", "PAC", "MOR", "SAR", "PAC", "MOR", "SAR", "PAC", "MOR",
"SAR", "PAC", "MOR", "SAR", "PAC", "MOR", "SAR", "PAC", "MOR",
"SAR", "PAC", "MOR", "SAR"), Temperature = structure(c(1L, 1L,
1L, 1L, 1L, 1L, 2L, 2L, 2L, 2L, 2L, 2L, 3L, 3L, 3L, 3L, 3L, 3L,
4L, 4L, 4L, 4L, 4L, 4L, 5L, 5L, 5L, 5L, 5L, 5L, 6L, 6L, 6L, 6L,
6L, 6L, 1L, 1L, 1L, 1L, 1L, 1L, 2L, 2L, 2L, 2L, 2L, 2L, 3L, 3L,
3L, 3L, 3L, 3L, 4L, 4L, 4L, 4L, 4L, 4L, 5L, 5L, 5L, 5L, 5L, 5L,
6L, 6L, 6L, 6L, 6L, 6L, 3L, 3L, 3L, 3L, 3L, 3L, 4L, 4L, 4L, 4L,
4L, 4L, 5L, 5L, 5L, 5L, 5L, 5L), .Label = c("15", "20", "22.5",
"25", "27.5", "30"), class = "factor"), Size = c("4-5mm", "4-5mm",
"4-5mm", "6-7mm", "6-7mm", "6-7mm", "4-5mm", "4-5mm", "4-5mm",
"6-7mm", "6-7mm", "6-7mm", "4-5mm", "4-5mm", "4-5mm", "6-7mm",
"6-7mm", "6-7mm", "4-5mm", "4-5mm", "4-5mm", "6-7mm", "6-7mm",
"6-7mm", "4-5mm", "4-5mm", "4-5mm", "6-7mm", "6-7mm", "6-7mm",
"4-5mm", "4-5mm", "4-5mm", "6-7mm", "6-7mm", "6-7mm", "4-5mm",
"4-5mm", "4-5mm", "6-7mm", "6-7mm", "4-5mm", "4-5mm", "4-5mm",
"4-5mm", "6-7mm", "6-7mm", "6-7mm", "4-5mm", "4-5mm", "4-5mm",
"6-7mm", "6-7mm", "6-7mm", "4-5mm", "4-5mm", "4-5mm", "6-7mm",
"6-7mm", "6-7mm", "4-5mm", "4-5mm", "4-5mm", "6-7mm", "6-7mm",
"6-7mm", "4-5mm", "4-5mm", "4-5mm", "6-7mm", "6-7mm", "4-5mm",
"4-5mm", "4-5mm", "4-5mm", "6-7mm", "6-7mm", "4-5mm", "4-5mm",
"4-5mm", "4-5mm", "6-7mm", "6-7mm", "4-5mm", "4-5mm", "4-5mm",
"4-5mm", "6-7mm", "6-7mm", "4-5mm"), Number_I = c(6, 8, 6, 4,
3, 4, 6, 8, 6, 4, 3, 4, 5, 7, 6, 5, 3, 4, 4, 7, 6, 5, 4, 4, 6,
7, 7, 4, 4, 3, 6, 7, 6, 4, 3, 4, 5, 7, 5, 2, 3, 5, 6, 8, 6, 4,
3, 4, 5, 7, 6, 5, 4, 4, 5, 7, 6, 5, 4, 4, 6, 7, 7, 4, 4, 3, 5,
6, 5, 2, 4, 5, 5, 6, 5, 3, 4, 5, 5, 6, 5, 3, 4, 5, 5, 6, 5, 3,
4, 5), Number_F = c(2, 4, 4, 3, 2, 4, 6, 8, 6, 4, 3, 4, 5, 7,
6, 5, 3, 4, 4, 7, 6, 5, 4, 4, 6, 7, 6, 4, 4, 3, 6, 7, 6, 4, 3,
3, 3, 4, 1, 1, 3, 1, 6, 8, 6, 4, 3, 4, 5, 7, 6, 5, 4, 4, 5, 7,
6, 5, 4, 4, 6, 7, 7, 4, 4, 3, 4, 6, 3, 2, 2, 3, 5, 4, 5, 3, 4,
2, 5, 6, 4, 3, 4, 4, 5, 6, 4, 3, 3, 4), Nbre_dead = c(4, 4, 2,
1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 4, 1, 0, 4, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
1, 0, 2, 0, 2, 2, 0, 2, 0, 0, 0, 3, 0, 0, 1, 0, 0, 1, 0, 0, 1,
0, 1, 1)), .Names = c("Population", "Temperature", "Size", "Number_I",
"Number_F", "Nbre_dead"), row.names = c(NA, -90L), class = "data.frame")



This question came from our site for professional and enthusiast programmers.





Could you explain why you include the number of individuals in the experiment among the explanatory factors?
– whuber
Aug 7 at 11:58









By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Popular posts from this blog

Firebase Auth - with Email and Password - Check user already registered

Dynamically update html content plain JS

Creating a leaderboard in HTML/JS