1 Packages and Working Directory

#setwd("C:/Users/Ludov/Desktop/mémoire/statistiques")
library(tidyverse)
## ── Attaching packages ─────────────────────────────────────── tidyverse 1.3.2 ──
## ✔ ggplot2 3.4.0     ✔ purrr   1.0.1
## ✔ tibble  3.1.8     ✔ dplyr   1.1.0
## ✔ tidyr   1.3.0     ✔ stringr 1.5.0
## ✔ readr   2.1.3     ✔ forcats 1.0.0
## ── Conflicts ────────────────────────────────────────── tidyverse_conflicts() ──
## ✖ dplyr::filter() masks stats::filter()
## ✖ dplyr::lag()    masks stats::lag()
library(visreg)
library(emmeans)
library(EMSaov)
library(ade4)
library(ggResidpanel)
library(car)
## Le chargement a nécessité le package : carData
## 
## Attachement du package : 'car'
## 
## L'objet suivant est masqué depuis 'package:dplyr':
## 
##     recode
## 
## L'objet suivant est masqué depuis 'package:purrr':
## 
##     some
library(readxl)
library(lme4)
## Le chargement a nécessité le package : Matrix
## 
## Attachement du package : 'Matrix'
## 
## Les objets suivants sont masqués depuis 'package:tidyr':
## 
##     expand, pack, unpack
library(lmerTest)
## 
## Attachement du package : 'lmerTest'
## 
## L'objet suivant est masqué depuis 'package:lme4':
## 
##     lmer
## 
## L'objet suivant est masqué depuis 'package:stats':
## 
##     step
library(knitr)

2 Importation des données

Data <- read_excel("data/Data_full.xlsx")
#View(Data)
Data_logger_3_Dark <- read.csv2("data/Data_logger_3_Dark.csv")
Data_logger_3_Smart <- read.table("data/3_Smart.csv", header = T, sep = "\t", dec = ".")
Data_logger_3_Full <- read.table("data/3_Full.csv", header = T, sep = "\t", dec = ".")
Data_logger_4_Dark <- read.table("data/4_Dark.csv", header = T, sep = "\t", dec = ".")
Data_logger_4_Smart <- read.table("data/4_Smart.csv", header = T, sep = "\t", dec = ".")
Data_logger_4_Full <- read.table("data/4_Full.csv", header = T, sep = "\t", dec = ".")

2.1 Modifications des colonnes

2.1.1 Data_logger

colnames(Data_logger_3_Dark) <- c("Sample", "Date_time", "Temperature","Humidity","Dew_point_temperature")
Data_logger_3_Dark <- Data_logger_3_Dark[2:nrow(Data_logger_3_Dark),]
Data_logger_3_Dark$Treatment <- "Dark"
Data_logger_3_Dark$Sample <- as.numeric(Data_logger_3_Dark$Sample)
Data_logger_3_Dark$Temperature <- as.numeric(Data_logger_3_Dark$Temperature)
Data_logger_3_Dark$Humidity <- as.numeric(Data_logger_3_Dark$Humidity)
Data_logger_3_Dark$Dew_point_temperature <- as.numeric(Data_logger_3_Dark$Dew_point_temperature)
Data_logger_3_Dark$Treatment <- as.factor(Data_logger_3_Dark$Treatment)
Data_logger_3_Dark$Room <- as.factor("3")
Data_logger_3_Dark$Section <- as.factor("3_Dark")
colnames(Data_logger_3_Smart) <- c("Sample", "Date_time", "Temperature","Humidity","Dew_point_temperature")
Data_logger_3_Smart$Treatment <- as.factor("Smart")
Data_logger_3_Smart$Room <- as.factor("3")
Data_logger_3_Smart$Section <- as.factor("3_Smart")
colnames(Data_logger_3_Full) <- c("Sample", "Date_time", "Temperature","Humidity","Dew_point_temperature")
Data_logger_3_Full$Treatment <- as.factor("Full")
Data_logger_3_Full$Room <- as.factor("3")
Data_logger_3_Full$Section <- as.factor("3_Full")
colnames(Data_logger_4_Dark) <- c("Sample", "Date_time", "Temperature","Humidity","Dew_point_temperature")
Data_logger_4_Dark$Treatment <- as.factor("Dark")
Data_logger_4_Dark$Room <- as.factor("4")
Data_logger_4_Dark$Section <- as.factor("4_Dark")
colnames(Data_logger_4_Smart) <- c("Sample", "Date_time", "Temperature","Humidity","Dew_point_temperature")
Data_logger_4_Smart$Treatment <- as.factor("Smart")
Data_logger_4_Smart$Room <- as.factor("4")
Data_logger_4_Smart$Section <- as.factor("4_Smart")
colnames(Data_logger_4_Full) <- c("Sample", "Date_time", "Temperature","Humidity","Dew_point_temperature")
Data_logger_4_Full$Treatment <- as.factor("Full")
Data_logger_4_Full$Room <- as.factor("4")
Data_logger_4_Full$Section <- as.factor("4_Full")
Data_logger <- rbind(Data_logger_3_Dark, Data_logger_3_Smart, Data_logger_3_Full, Data_logger_4_Dark, Data_logger_4_Smart, Data_logger_4_Full)
summary(Data_logger)
##      Sample       Date_time          Temperature       Humidity     
##  Min.   :    1   Length:100613      Min.   :13.64   Min.   : 21.87  
##  1st Qu.: 4193   Class :character   1st Qu.:20.84   1st Qu.: 52.00  
##  Median : 8385   Mode  :character   Median :24.17   Median : 88.64  
##  Mean   : 8385                      Mean   :23.16   Mean   : 75.75  
##  3rd Qu.:12577                      3rd Qu.:25.11   3rd Qu.: 97.23  
##  Max.   :16769                      Max.   :27.19   Max.   :100.00  
##  Dew_point_temperature Treatment     Room         Section     
##  Min.   :-3.621        Dark :33537   3:50307   3_Dark :16769  
##  1st Qu.:13.059        Smart:33538   4:50306   3_Smart:16769  
##  Median :19.627        Full :33538             3_Full :16769  
##  Mean   :17.752                                4_Dark :16768  
##  3rd Qu.:23.596                                4_Smart:16769  
##  Max.   :26.758                                4_Full :16769

2.1.2 Data

Data$Room <- as.factor(Data$Room)
Data$Mother <- as.factor(Data$Mother)
Data$Treatment <- as.factor(Data$Treatment)
Data$Treatment_bis <- as.factor(Data$Treatment_bis)
Data$ID <- as.factor(Data$ID)
Data$Sex <- as.factor(Data$Sex)
Data$Species <- as.factor(Data$Species)
Data$Region <- as.factor(Data$Region)
Data$Site <- as.factor(Data$Site)

Data$M0 <- as.numeric(Data$M0)
Data$M1 <- as.numeric(Data$M1)
Data$M2 <- as.numeric(Data$M2)
Data$M3 <- as.numeric(Data$M3)
Data$M4 <- as.numeric(Data$M4)
Data$M5 <- as.numeric(Data$M5)
Data$M6 <- as.numeric(Data$M6)
Data$M7 <- as.numeric(Data$M7)
Data$M8 <- as.numeric(Data$M8)
Data$M9 <- as.numeric(Data$M9)
Data$M10 <- as.numeric(Data$M10)
Data$M11 <- as.numeric(Data$M11)
Data$M12 <- as.numeric(Data$M12)
Data$M13 <- as.numeric(Data$M13)
Data$M14 <- as.numeric(Data$M14)
Data$M15 <- as.numeric(Data$M15)
Data$M16 <- as.numeric(Data$M16)
Data$M17 <- as.numeric(Data$M17)
Data$M18 <- as.numeric(Data$M18)
Data$M19 <- as.numeric(Data$M19)
Data$M20 <- as.numeric(Data$M20)

Data$Time_alive <- as.numeric(Data$Time_alive)
Data$Pupa_mass <- as.numeric(Data$Pupa_mass)

Data$Did_pupated <- as.factor(Data$Did_pupated)
Data$Did_emerged <- as.factor(Data$Did_emerged)
Data$Larva_survival <- as.factor(Data$Larva_survival)
Data$Diapause <- as.factor(Data$Diapause)

Data$Treatment_FTL <- as.factor(Data$Treatment_FTL)
Data$Light_orientation <- as.factor(Data$Light_orientation)
Data$Did_move <- as.factor(Data$Did_move)
Data$Did_FTL <- as.factor(Data$Did_FTL)

Data$Treatment_bis <- factor(Data$Treatment_bis, levels = c("Dark", "Full", "Smart", "Mixt_smart"))

2.2 Création des colonnes “Total_eaten” et “Eaten_per_day”

Mise en place de Total_eaten

Vecteur_total_eaten <- numeric()
for ( Y in (1:450) ) {
  

  B <- 0
  for ( X in (seq(73,403, by = 3)) ) {
    A <- as.numeric(unname(Data[ Y , X ]))
    B <- sum( A , B )
  
  }
  
  Vecteur_total_eaten <- c(Vecteur_total_eaten, B)
  
}

Data$Total_eaten <- Vecteur_total_eaten

Mise en place de Eaten_per_day

Data <- Data %>% mutate(Eaten_per_day = Total_eaten / Time_alive )

2.3 Speed_to_light

Afin de résoudre prendre en compte tout les individus qui ont n’ont pas voler mais participer à l’expérience (ils ont aucun score dans le temps mis pour voler mais ne participent pas au test stat (car ils ont rien dans la colonne Flight_to_light))

Vecteur_speed <- numeric()
for (X in (1:nrow(Data))) {
  A <- ifelse(Data$End_FTL_experiment[X] == 1800, 0, ( 4.5 / (Data$Flight_to_light[X] / 60) ))
  Vecteur_speed <- c(Vecteur_speed, A)
}

Data$Speed_to_light <- Vecteur_speed

2.4 Ordre des facteurs différents

Data_ref_smart <- Data
Data_ref_smart$Treatment <- relevel(Data$Treatment, ref = "Smart")
Data_ref_smart$Treatment_bis <- relevel(Data$Treatment_bis, ref = "Smart")

Data_ref_full <- Data
Data_ref_full$Treatment <- relevel(Data$Treatment, ref = "Full")
Data_ref_full$Treatment_bis <- relevel(Data$Treatment_bis, ref = "Full")

Data_ref_mixt_smart <- Data
Data_ref_mixt_smart$Treatment_bis <- relevel(Data$Treatment_bis, ref = "Mixt_smart")

Data_refFTL_Night <- Data
Data_refFTL_Night$Treatment_FTL <- relevel(Data$Treatment_FTL, ref = "Night")
Data_refFTL_Night$Treatment_FTL <- relevel(Data$Treatment_FTL, ref = "Night")

Data_refFTL_Mix <- Data
Data_refFTL_Mix$Treatment_FTL <- relevel(Data$Treatment_FTL, ref = "Mix")
Data_refFTL_Mix$Treatment_FTL <- relevel(Data$Treatment_FTL, ref = "Mix")

2.5 Séparation des jeux de données en fonction par espèce

Data_OP <- Data %>% filter(Species == "OP")
Data_OP_ref_smart <- Data_ref_smart %>% filter(Species == "OP")
Data_OP_ref_full  <- Data_ref_full  %>% filter(Species == "OP")

Data_AE <- Data %>% filter(Species == "AE")
Data_AE_ref_smart <- Data_ref_smart %>% filter(Species == "AE")
Data_AE_ref_full  <- Data_ref_full  %>% filter(Species == "AE")
Data_AE_ref_mixt_smart  <- Data_ref_mixt_smart  %>% filter(Species == "AE")

3 Data logger

summary(Data_logger)
##      Sample       Date_time          Temperature       Humidity     
##  Min.   :    1   Length:100613      Min.   :13.64   Min.   : 21.87  
##  1st Qu.: 4193   Class :character   1st Qu.:20.84   1st Qu.: 52.00  
##  Median : 8385   Mode  :character   Median :24.17   Median : 88.64  
##  Mean   : 8385                      Mean   :23.16   Mean   : 75.75  
##  3rd Qu.:12577                      3rd Qu.:25.11   3rd Qu.: 97.23  
##  Max.   :16769                      Max.   :27.19   Max.   :100.00  
##  Dew_point_temperature Treatment     Room         Section     
##  Min.   :-3.621        Dark :33537   3:50307   3_Dark :16769  
##  1st Qu.:13.059        Smart:33538   4:50306   3_Smart:16769  
##  Median :19.627        Full :33538             3_Full :16769  
##  Mean   :17.752                                4_Dark :16768  
##  3rd Qu.:23.596                                4_Smart:16769  
##  Max.   :26.758                                4_Full :16769

3.1 Température par pièce

Anova_Data_logger_temp_room <- aov(Temperature ~ Room, data = Data_logger)
summary(Anova_Data_logger_temp_room)
##                 Df Sum Sq Mean Sq F value Pr(>F)    
## Room             1   9232    9232    1546 <2e-16 ***
## Residuals   100611 600679       6                   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
kable(TukeyHSD(Anova_Data_logger_temp_room)$Room,caption = "Test post-hoc de Tukey pour la température en fonction des différentes pièces")
Test post-hoc de Tukey pour la température en fonction des différentes pièces
diff lwr upr p adj
4-3 0.6058174 0.5756213 0.6360134 0
write.csv2( TukeyHSD(Anova_Data_logger_temp_room)$Room , file = "output/Data_logger_temp_room.csv" )

3.2 Température par traitement

Anova_Data_logger_temp_treatment <- aov(Temperature ~ Treatment, data = Data_logger)
summary(Anova_Data_logger_temp_treatment)
##                 Df Sum Sq Mean Sq F value Pr(>F)    
## Treatment        2   1717   858.4     142 <2e-16 ***
## Residuals   100610 608194     6.0                   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
kable(TukeyHSD(Anova_Data_logger_temp_treatment)$Treatment,caption = "Test post-hoc de Tukey pour la température en fonction des différents traitements")
Test post-hoc de Tukey pour la température en fonction des différents traitements
diff lwr upr p adj
Smart-Dark -0.1199718 -0.1644711 -0.0754726 0
Full-Dark -0.3168704 -0.3613696 -0.2723712 0
Full-Smart -0.1968986 -0.2413975 -0.1523997 0
write.csv2( TukeyHSD(Anova_Data_logger_temp_treatment)$Treatment , file = "output/Data_logger_temp_treatment.csv" )

3.3 Température par section

Anova_Data_logger_temp_section <- aov(Temperature ~ Section, data = Data_logger)
summary(Anova_Data_logger_temp_section)
##                 Df Sum Sq Mean Sq F value Pr(>F)    
## Section          5  12576  2515.1   423.6 <2e-16 ***
## Residuals   100607 597335     5.9                   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
kable(TukeyHSD(Anova_Data_logger_temp_section)$Section,caption = "Test post-hoc de Tukey pour la température en fonction des différentes sections")
Test post-hoc de Tukey pour la température en fonction des différentes sections
diff lwr upr p adj
3_Smart-3_Dark -0.3961415 -0.4719741 -0.3203088 0.0000000
3_Full-3_Dark -0.5797694 -0.6556021 -0.5039367 0.0000000
4_Dark-3_Dark 0.2464425 0.1706087 0.3222763 0.0000000
4_Smart-3_Dark 0.4026330 0.3268003 0.4784656 0.0000000
4_Full-3_Dark 0.1924637 0.1166310 0.2682964 0.0000000
3_Full-3_Smart -0.1836279 -0.2594606 -0.1077953 0.0000000
4_Dark-3_Smart 0.6425840 0.5667502 0.7184178 0.0000000
4_Smart-3_Smart 0.7987744 0.7229417 0.8746071 0.0000000
4_Full-3_Smart 0.5886052 0.5127725 0.6644378 0.0000000
4_Dark-3_Full 0.8262119 0.7503781 0.9020457 0.0000000
4_Smart-3_Full 0.9824023 0.9065697 1.0582350 0.0000000
4_Full-3_Full 0.7722331 0.6964004 0.8480658 0.0000000
4_Smart-4_Dark 0.1561904 0.0803566 0.2320242 0.0000001
4_Full-4_Dark -0.0539788 -0.1298126 0.0218550 0.3260046
4_Full-4_Smart -0.2101692 -0.2860019 -0.1343366 0.0000000
write.csv2( TukeyHSD(Anova_Data_logger_temp_section)$Section , file = "output/Data_logger_temp_section.csv" )

3.4 Humidité par pièce

Anova_Data_logger_hum_room <- aov(Humidity ~ Room, data = Data_logger)
summary(Anova_Data_logger_hum_room)
##                 Df   Sum Sq Mean Sq F value Pr(>F)    
## Room             1   558908  558908   950.2 <2e-16 ***
## Residuals   100611 59178188     588                   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
kable(TukeyHSD(Anova_Data_logger_hum_room)$Room,caption = "Test post-hoc de Tukey pour l'humidité en fonction des différentes pièces")
Test post-hoc de Tukey pour l’humidité en fonction des différentes pièces
diff lwr upr p adj
4-3 -4.71382 -5.013535 -4.414104 0
write.csv2( TukeyHSD(Anova_Data_logger_hum_room)$Room , file = "output/Data_logger_hum_room.csv" )

3.5 Humidité par traitement

Anova_Data_logger_hum_treatment <- aov(Humidity ~ Treatment, data = Data_logger)
summary(Anova_Data_logger_hum_treatment)
##                 Df   Sum Sq Mean Sq F value Pr(>F)    
## Treatment        2   408004  204002   345.9 <2e-16 ***
## Residuals   100610 59329092     590                   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
kable(TukeyHSD(Anova_Data_logger_hum_treatment)$Treatment,caption = "Test post-hoc de Tukey pour l'humidité en fonction des différents traitements")
Test post-hoc de Tukey pour l’humidité en fonction des différents traitements
diff lwr upr p adj
Smart-Dark 1.214412 0.7749055 1.653918 0
Full-Dark 4.747522 4.3080161 5.187029 0
Full-Smart 3.533111 3.0936077 3.972614 0
write.csv2( TukeyHSD(Anova_Data_logger_hum_treatment)$Treatment , file = "output/Data_logger_hum_treatment.csv" )

3.6 Humidité par section

Anova_Data_logger_hum_section <- aov(Humidity ~ Section, data = Data_logger)
summary(Anova_Data_logger_hum_section)
##                 Df   Sum Sq Mean Sq F value Pr(>F)    
## Section          5  1661156  332231   575.5 <2e-16 ***
## Residuals   100607 58075939     577                   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
kable(TukeyHSD(Anova_Data_logger_hum_section)$Section,caption = "Test post-hoc de Tukey pour l'humidité en fonction des différentes sections")
Test post-hoc de Tukey pour l’humidité en fonction des différentes sections
diff lwr upr p adj
3_Smart-3_Dark 7.641563 6.893832 8.3892938 0.0000000
3_Full-3_Dark 7.698508 6.950777 8.4462388 0.0000000
4_Dark-3_Dark 1.538324 0.790582 2.2860664 0.0000001
4_Smart-3_Dark -3.674461 -4.422192 -2.9267300 0.0000000
4_Full-3_Dark 3.334815 2.587084 4.0825464 0.0000000
3_Full-3_Smart 0.056945 -0.690786 0.8046761 0.9999343
4_Dark-3_Smart -6.103239 -6.850981 -5.3554964 0.0000000
4_Smart-3_Smart -11.316024 -12.063755 -10.5682928 0.0000000
4_Full-3_Smart -4.306748 -5.054479 -3.5590164 0.0000000
4_Dark-3_Full -6.160184 -6.907926 -5.4124414 0.0000000
4_Smart-3_Full -11.372969 -12.120700 -10.6252378 0.0000000
4_Full-3_Full -4.363692 -5.111423 -3.6159614 0.0000000
4_Smart-4_Dark -5.212785 -5.960527 -4.4650430 0.0000000
4_Full-4_Dark 1.796491 1.048749 2.5442333 0.0000000
4_Full-4_Smart 7.009276 6.261545 7.7570074 0.0000000
write.csv2( TukeyHSD(Anova_Data_logger_hum_section)$Section , file = "output/Data_logger_hum_section.csv" )

4 Analyses Développement

4.1 Total_molt

Vu que c’est une variable de comptage, nous comptons faire un glm de type poisson

4.1.1 Test

GLM_Total_molt <- glmer(Total_molt ~ Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex , family = poisson, data = Data)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
summary(GLM_Total_molt)
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: poisson  ( log )
## Formula: Total_molt ~ Treatment_bis + Sex + Species + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Sex:Species + Region:Species +  
##     Treatment_bis:Species + Treatment_bis:Sex
##    Data: Data
## 
##      AIC      BIC   logLik deviance df.resid 
##    970.3   1033.5   -468.2    936.3      287 
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -1.87904 -0.46734  0.09575  0.30220  1.82167 
## 
## Random effects:
##  Groups Name        Variance Std.Dev. 
##  Mother (Intercept) 0.00e+00 0.000e+00
##  Site   (Intercept) 9.32e-17 9.654e-09
##  Room   (Intercept) 0.00e+00 0.000e+00
## Number of obs: 304, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                 Estimate Std. Error z value Pr(>|z|)    
## (Intercept)                      1.22906    0.09861  12.464  < 2e-16 ***
## Treatment_bisFull               -0.10802    0.12930  -0.835    0.403    
## Treatment_bisSmart               0.01831    0.14233   0.129    0.898    
## Treatment_bisMixt_smart          0.01054    0.15924   0.066    0.947    
## SexMale                          0.03246    0.13058   0.249    0.804    
## SpeciesOP                       -0.73140    0.15269  -4.790 1.67e-06 ***
## RegionLuxembourg                 0.14355    0.08255   1.739    0.082 .  
## SexMale:SpeciesOP               -0.05026    0.16401  -0.306    0.759    
## SpeciesOP:RegionLuxembourg      -0.09978    0.15673  -0.637    0.524    
## Treatment_bisFull:SpeciesOP      0.02977    0.17993   0.165    0.869    
## Treatment_bisSmart:SpeciesOP     0.03500    0.23814   0.147    0.883    
## Treatment_bisFull:SexMale        0.05893    0.16996   0.347    0.729    
## Treatment_bisSmart:SexMale      -0.12092    0.21066  -0.574    0.566    
## Treatment_bisMixt_smart:SexMale -0.07719    0.23607  -0.327    0.744    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 14 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Pas d’effet significatif autre que l’espèce.

Vérification des hypothèses

resid_panel(GLM_Total_molt, plots = c("resid"), smoother = TRUE)
## `geom_smooth()` using formula = 'y ~ x'

Le modèle pourrait être siplifié par AIC (surtout pour les interactions)

4.1.2 Sipmplification du modèle

Simplification par AIC/BIC

drop1(GLM_Total_molt)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
## boundary (singular) fit: see help('isSingular')
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
## Single term deletions
## 
## Model:
## Total_molt ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + 
##     (1 | Site) + (1 | Room) + Sex:Species + Region:Species + 
##     Treatment_bis:Species + Treatment_bis:Sex
##                       npar    AIC
## <none>                     970.31
## Sex:Species              1 968.40
## Species:Region           1 968.71
## Treatment_bis:Species    2 966.34
## Treatment_bis:Sex        3 965.12
GLM_Total_molt2 <- update(GLM_Total_molt, . ~ . - Treatment_bis:Sex)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
drop1(GLM_Total_molt2)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
## boundary (singular) fit: see help('isSingular')
## Single term deletions
## 
## Model:
## Total_molt ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + 
##     (1 | Site) + (1 | Room) + Sex:Species + Species:Region + 
##     Treatment_bis:Species
##                       npar    AIC
## <none>                     965.12
## Sex:Species              1 963.16
## Species:Region           1 963.54
## Treatment_bis:Species    2 961.16
GLM_Total_molt3 <- update(GLM_Total_molt2, . ~ . - Treatment_bis:Species)
## boundary (singular) fit: see help('isSingular')
drop1(GLM_Total_molt3)
## boundary (singular) fit: see help('isSingular')
## boundary (singular) fit: see help('isSingular')
## boundary (singular) fit: see help('isSingular')
## Single term deletions
## 
## Model:
## Total_molt ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + 
##     (1 | Site) + (1 | Room) + Sex:Species + Species:Region
##                npar    AIC
## <none>              961.16
## Treatment_bis     3 955.86
## Sex:Species       1 959.19
## Species:Region    1 959.57
GLM_Total_molt4 <- update(GLM_Total_molt3, . ~ . - Sex:Species)
## boundary (singular) fit: see help('isSingular')
# drop1(GLM_Total_molt5) drop1 a cessé de fonctionné donc je compare le modèle avec et  sans interactions
GLM_Total_molt5 <- update(GLM_Total_molt4, . ~ . - Species:Region - Room:Treatment_bis)
## boundary (singular) fit: see help('isSingular')
AIC(GLM_Total_molt4)
## [1] 959.1862
AIC(GLM_Total_molt5)
## [1] 957.5986

Modèle final, aucune interactions n’était significative

GLM_Total_molt <- GLM_Total_molt5
summary(GLM_Total_molt5)
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: poisson  ( log )
## Formula: Total_molt ~ Treatment_bis + Sex + Species + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room)
##    Data: Data
## 
##      AIC      BIC   logLik deviance df.resid 
##    957.6    994.8   -468.8    937.6      294 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.8750 -0.4448  0.1580  0.3201  1.8090 
## 
## Random effects:
##  Groups Name        Variance Std.Dev.
##  Mother (Intercept) 0        0       
##  Site   (Intercept) 0        0       
##  Room   (Intercept) 0        0       
## Number of obs: 304, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                          Estimate Std. Error z value Pr(>|z|)    
## (Intercept)              1.249363   0.076924  16.242   <2e-16 ***
## Treatment_bisFull       -0.071402   0.084509  -0.845    0.398    
## Treatment_bisSmart      -0.020291   0.102305  -0.198    0.843    
## Treatment_bisMixt_smart -0.019024   0.117183  -0.162    0.871    
## SexMale                  0.007811   0.070677   0.111    0.912    
## SpeciesOP               -0.789854   0.081302  -9.715   <2e-16 ***
## RegionLuxembourg         0.114200   0.070195   1.627    0.104    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal SpcsOP
## Trtmnt_bsFl -0.499                                   
## Trtmnt_bsSm -0.440  0.384                            
## Trtmnt_bsM_ -0.446  0.349  0.306                     
## SexMale     -0.362 -0.051  0.017 -0.029              
## SpeciesOP   -0.372  0.088  0.143  0.269 -0.034       
## ReginLxmbrg -0.394 -0.025 -0.076 -0.022 -0.020 -0.057
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Seulement les espèces sont significatives

4.1.3 Treatment VS Treatment_bis

AIC(GLM_Total_molt)
## [1] 957.5986
AIC(update(GLM_Total_molt, . ~ . - Treatment_bis + Treatment))
## boundary (singular) fit: see help('isSingular')
## [1] 955.6493
summary(GLM_Total_molt)$coeff
##                             Estimate Std. Error    z value     Pr(>|z|)
## (Intercept)              1.249362967 0.07692355 16.2416195 2.560733e-59
## Treatment_bisFull       -0.071402364 0.08450888 -0.8449096 3.981613e-01
## Treatment_bisSmart      -0.020290687 0.10230536 -0.1983345 8.427833e-01
## Treatment_bisMixt_smart -0.019024308 0.11718279 -0.1623473 8.710324e-01
## SexMale                  0.007811043 0.07067680  0.1105178 9.119987e-01
## SpeciesOP               -0.789853774 0.08130168 -9.7150980 2.599987e-22
## RegionLuxembourg         0.114200258 0.07019497  1.6269008 1.037582e-01
summary(update(GLM_Total_molt, . ~ . - Treatment_bis + Treatment))$coeff
## boundary (singular) fit: see help('isSingular')
##                       Estimate Std. Error       z value     Pr(>|z|)
## (Intercept)       1.2395001210 0.07816780  15.856913745 1.259322e-56
## SexMale           0.0078032917 0.07065795   0.110437559 9.120624e-01
## SpeciesOP        -0.7854511296 0.07817605 -10.047209082 9.450604e-24
## RegionLuxembourg  0.1131112397 0.07008653   1.613879843 1.065535e-01
## TreatmentFull    -0.0623153922 0.08736703  -0.713259799 4.756850e-01
## TreatmentSmart    0.0008079064 0.08482624   0.009524251 9.924009e-01

pas de grosse différence de significativité L’AIC préfère le modèle avec “Treatment”

summary(GLM_Total_molt)
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: poisson  ( log )
## Formula: Total_molt ~ Treatment_bis + Sex + Species + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room)
##    Data: Data
## 
##      AIC      BIC   logLik deviance df.resid 
##    957.6    994.8   -468.8    937.6      294 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.8750 -0.4448  0.1580  0.3201  1.8090 
## 
## Random effects:
##  Groups Name        Variance Std.Dev.
##  Mother (Intercept) 0        0       
##  Site   (Intercept) 0        0       
##  Room   (Intercept) 0        0       
## Number of obs: 304, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                          Estimate Std. Error z value Pr(>|z|)    
## (Intercept)              1.249363   0.076924  16.242   <2e-16 ***
## Treatment_bisFull       -0.071402   0.084509  -0.845    0.398    
## Treatment_bisSmart      -0.020291   0.102305  -0.198    0.843    
## Treatment_bisMixt_smart -0.019024   0.117183  -0.162    0.871    
## SexMale                  0.007811   0.070677   0.111    0.912    
## SpeciesOP               -0.789854   0.081302  -9.715   <2e-16 ***
## RegionLuxembourg         0.114200   0.070195   1.627    0.104    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal SpcsOP
## Trtmnt_bsFl -0.499                                   
## Trtmnt_bsSm -0.440  0.384                            
## Trtmnt_bsM_ -0.446  0.349  0.306                     
## SexMale     -0.362 -0.051  0.017 -0.029              
## SpeciesOP   -0.372  0.088  0.143  0.269 -0.034       
## ReginLxmbrg -0.394 -0.025 -0.076 -0.022 -0.020 -0.057
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(update(GLM_Total_molt, . ~ . - Treatment_bis + Treatment))
## boundary (singular) fit: see help('isSingular')
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: poisson  ( log )
## Formula: Total_molt ~ Sex + Species + Region + (1 | Mother) + (1 | Site) +  
##     (1 | Room) + Treatment
##    Data: Data
## 
##      AIC      BIC   logLik deviance df.resid 
##    955.6    989.1   -468.8    937.6      295 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.8657 -0.4425  0.1661  0.3278  1.8034 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev. 
##  Mother (Intercept) 0.000e+00 0.000e+00
##  Site   (Intercept) 0.000e+00 0.000e+00
##  Room   (Intercept) 1.459e-18 1.208e-09
## Number of obs: 304, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                    Estimate Std. Error z value Pr(>|z|)    
## (Intercept)       1.2395001  0.0781678  15.857   <2e-16 ***
## SexMale           0.0078033  0.0706580   0.110    0.912    
## SpeciesOP        -0.7854511  0.0781761 -10.047   <2e-16 ***
## RegionLuxembourg  0.1131112  0.0700865   1.614    0.107    
## TreatmentFull    -0.0623154  0.0873670  -0.713    0.476    
## TreatmentSmart    0.0008079  0.0848262   0.010    0.992    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) SexMal SpcsOP RgnLxm TrtmnF
## SexMale     -0.378                            
## SpeciesOP   -0.256 -0.028                     
## ReginLxmbrg -0.391 -0.020 -0.050              
## TreatmntFll -0.526 -0.032 -0.007 -0.023       
## TretmntSmrt -0.568  0.031  0.036 -0.053  0.507
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
Info_Total_molt <- "
Effet significatif de l'espèce, OP possède moins de mues.
"
Info_Total_molt
## [1] "\nEffet significatif de l'espèce, OP possède moins de mues.\n"

4.1.4 Visualisation

Résumé des données

Summary_Total_molt <- Data %>% 
  group_by(Treatment, Species, Region) %>% 
  summarise(Mean=mean(Total_molt),
            Var=var(Total_molt),
            N=n()) %>% 
  mutate(CI_S=Mean+qt(0.975, N-1)*sqrt(Var/N),
         CI_I=Mean-qt(0.975, N-1)*sqrt(Var/N))

Graphique avec ce résumé

ggplot(Summary_Total_molt, aes(x=Treatment, y=Mean, color = Species))+
  geom_errorbar(aes(ymin=CI_I, ymax=CI_S),width=0.2,size = 1.2, alpha = 0.5) +
  geom_point(alpha = 0.8) +
  facet_grid(~Region) +
  labs(title = "Nombre de mues", x = "Traitement", y = "Nombre de mues", color = "Espèce") +
  theme_bw()
## Warning: Using `size` aesthetic for lines was deprecated in ggplot2 3.4.0.
## ℹ Please use `linewidth` instead.

ggplot(Data, aes(x=Total_molt)) +
  geom_histogram(aes(y = ..count.. , fill = Species), position = "dodge", size = 4) +
  scale_x_continuous(breaks = seq(0,6)) +
  labs(title = "Nombres de mues par espèce", x = "Nombre de mues", y = "Nombre d'individu", fill = "Espèce") +
  theme_bw()
## Warning: The dot-dot notation (`..count..`) was deprecated in ggplot2 3.4.0.
## ℹ Please use `after_stat(count)` instead.
## `stat_bin()` using `bins = 30`. Pick better value with `binwidth`.

4.2 Diapause

4.2.1 Test

GLM_Diapause <- glmer(Diapause ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data, family = binomial)
summary(GLM_Diapause)
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: Diapause ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data
## 
##      AIC      BIC   logLik deviance df.resid 
##    195.4    251.2    -82.7    165.4      289 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -0.8081 -0.2944 -0.2163 -0.1254  5.6179 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev. 
##  Mother (Intercept) 3.425e-01 0.5852746
##  Site   (Intercept) 8.894e-01 0.9430726
##  Room   (Intercept) 1.062e-07 0.0003259
## Number of obs: 304, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error z value Pr(>|z|)
## (Intercept)                                -2.69086    0.67160  -4.007 6.16e-05
## Treatment_bisFull                           1.29096    0.71956   1.794   0.0728
## Treatment_bisSmart                         -0.11529    1.03099  -0.112   0.9110
## Treatment_bisMixt_smart                   -33.98513 5819.93268  -0.006   0.9953
## SexMale                                     0.07099    0.63243   0.112   0.9106
## RegionLuxembourg                           -0.57942    0.96440  -0.601   0.5480
## Treatment_bisFull:SexMale                  -2.08720    1.08502  -1.924   0.0544
## Treatment_bisSmart:SexMale                  0.26663    1.51819   0.176   0.8606
## Treatment_bisMixt_smart:SexMale            17.81447 4184.83400   0.004   0.9966
## Treatment_bisFull:RegionLuxembourg         -0.82819    0.99234  -0.835   0.4040
## Treatment_bisSmart:RegionLuxembourg        -0.99425    1.50602  -0.660   0.5091
## Treatment_bisMixt_smart:RegionLuxembourg   17.28909 4044.59938   0.004   0.9966
##                                             
## (Intercept)                              ***
## Treatment_bisFull                        .  
## Treatment_bisSmart                          
## Treatment_bisMixt_smart                     
## SexMale                                     
## RegionLuxembourg                            
## Treatment_bisFull:SexMale                .  
## Treatment_bisSmart:SexMale                  
## Treatment_bisMixt_smart:SexMale             
## Treatment_bisFull:RegionLuxembourg          
## Treatment_bisSmart:RegionLuxembourg         
## Treatment_bisMixt_smart:RegionLuxembourg    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_F:SM T_S:SM T_M_:S
## Trtmnt_bsFl -0.571                                                        
## Trtmnt_bsSm -0.362  0.341                                                 
## Trtmnt_bsM_  0.000  0.000  0.000                                          
## SexMale     -0.395  0.372  0.271  0.000                                   
## ReginLxmbrg -0.573  0.280  0.170  0.000 -0.036                            
## Trtmnt_F:SM  0.266 -0.497 -0.163  0.000 -0.576 -0.001                     
## Trtmnt_S:SM  0.138 -0.129 -0.485  0.000 -0.427  0.033  0.232              
## Trtmn_M_:SM  0.000  0.000  0.000 -0.719  0.000  0.000  0.000  0.000       
## Trtmnt_F:RL  0.291 -0.571 -0.163  0.000  0.029 -0.480  0.087 -0.037  0.000
## Trtmnt_S:RL  0.181 -0.170 -0.478  0.000  0.016 -0.308 -0.001 -0.090  0.000
## Trtmn_M_:RL  0.000  0.000  0.000 -0.695  0.000  0.000  0.000  0.000  0.000
##             T_F:RL T_S:RL
## Trtmnt_bsFl              
## Trtmnt_bsSm              
## Trtmnt_bsM_              
## SexMale                  
## ReginLxmbrg              
## Trtmnt_F:SM              
## Trtmnt_S:SM              
## Trtmn_M_:SM              
## Trtmnt_F:RL              
## Trtmnt_S:RL  0.297       
## Trtmn_M_:RL  0.000  0.000
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## unable to evaluate scaled gradient
## Model failed to converge: degenerate  Hessian with 1 negative eigenvalues

4.2.2 Simplification du modèle

drop1(GLM_Diapause)
## Single term deletions
## 
## Model:
## Diapause ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | 
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##                      npar    AIC
## <none>                    195.41
## Treatment_bis:Sex       3 197.50
## Treatment_bis:Region    3 192.78
GLM_Diapause1 <- update(GLM_Diapause, . ~ . - Treatment_bis:Region)
drop1(GLM_Diapause1)
## Single term deletions
## 
## Model:
## Diapause ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | 
##     Site) + (1 | Room) + Treatment_bis:Sex
##                   npar    AIC
## <none>                 192.78
## Region               1 191.88
## Treatment_bis:Sex    3 193.70

Plus aucune interaction est nécessaire à faire retirer

GLM_Diapause <- GLM_Diapause1

4.2.3 Treatment VS Treatment_bis

AIC(glmer(Diapause ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data, family = binomial))
## [1] 195.4097
AIC(glmer(Diapause ~ Treatment + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data, family = binomial))
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## [1] 196.4034
summary(glmer(Diapause ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data, family = binomial))$coeff
##                                              Estimate   Std. Error      z value
## (Intercept)                               -2.69085839    0.6716023 -4.006624629
## Treatment_bisFull                          1.29095850    0.7195566  1.794102698
## Treatment_bisSmart                        -0.11528514    1.0309858 -0.111820295
## Treatment_bisMixt_smart                  -33.98512976 5819.9326829 -0.005839437
## SexMale                                    0.07098974    0.6324269  0.112249713
## RegionLuxembourg                          -0.57941581    0.9643999 -0.600804494
## Treatment_bisFull:SexMale                 -2.08719598    1.0850233 -1.923641542
## Treatment_bisSmart:SexMale                 0.26663258    1.5181892  0.175625404
## Treatment_bisMixt_smart:SexMale           17.81447062 4184.8340023  0.004256912
## Treatment_bisFull:RegionLuxembourg        -0.82818915    0.9923404 -0.834581753
## Treatment_bisSmart:RegionLuxembourg       -0.99425108    1.5060199 -0.660184568
## Treatment_bisMixt_smart:RegionLuxembourg  17.28908514 4044.5993756  0.004274610
##                                              Pr(>|z|)
## (Intercept)                              6.159263e-05
## Treatment_bisFull                        7.279678e-02
## Treatment_bisSmart                       9.109659e-01
## Treatment_bisMixt_smart                  9.953408e-01
## SexMale                                  9.106254e-01
## RegionLuxembourg                         5.479702e-01
## Treatment_bisFull:SexMale                5.439953e-02
## Treatment_bisSmart:SexMale               8.605882e-01
## Treatment_bisMixt_smart:SexMale          9.966035e-01
## Treatment_bisFull:RegionLuxembourg       4.039532e-01
## Treatment_bisSmart:RegionLuxembourg      5.091354e-01
## Treatment_bisMixt_smart:RegionLuxembourg 9.965894e-01
summary(glmer(Diapause ~ Treatment + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data, family = binomial))$coeff
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
##                                              Estimate   Std. Error      z value
## (Intercept)                               -2.57720028    0.6894436 -3.738087133
## TreatmentFull                             -0.96039356    0.9739312 -0.986100028
## TreatmentSmart                            -0.81024571    0.8598493 -0.942311333
## SexMale                                    0.08045145    0.6360189  0.126492231
## RegionLuxembourg                          -0.59885534    0.9803765 -0.610842202
## SexFemale:Treatment_bisFull                2.12416873    1.0931975  1.943078665
## SexFemale:Treatment_bisSmart               0.53662765    1.2667396  0.423629007
## SexMale:Treatment_bisSmart                 0.83195584    1.5419772  0.539538362
## SexFemale:Treatment_bisMixt_smart        -32.83639589 5143.5970326 -0.006383936
## SexMale:Treatment_bisMixt_smart          -15.41720073 3883.8998730 -0.003969515
## RegionLuxembourg:Treatment_bisFull        -0.85127285    0.9960992 -0.854606474
## RegionLuxembourg:Treatment_bisSmart       -1.01366758    1.5103680 -0.671139475
## RegionLuxembourg:Treatment_bisMixt_smart  17.21961336 3883.9000385  0.004433588
##                                              Pr(>|z|)
## (Intercept)                              0.0001854257
## TreatmentFull                            0.3240840301
## TreatmentSmart                           0.3460332678
## SexMale                                  0.8993422985
## RegionLuxembourg                         0.5413040517
## SexFemale:Treatment_bisFull              0.0520066543
## SexFemale:Treatment_bisSmart             0.6718363969
## SexMale:Treatment_bisSmart               0.5895154342
## SexFemale:Treatment_bisMixt_smart        0.9949063904
## SexMale:Treatment_bisMixt_smart          0.9968327932
## RegionLuxembourg:Treatment_bisFull       0.3927690424
## RegionLuxembourg:Treatment_bisSmart      0.5021316814
## RegionLuxembourg:Treatment_bisMixt_smart 0.9964625200

Aucune grosse différence, on peut continuer avec Treatment_bis (qui est meilleur en termes d’AIC)

Analyse des p-val

summary(glmer(Diapause ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data, family = binomial))
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: Diapause ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data
## 
##      AIC      BIC   logLik deviance df.resid 
##    195.4    251.2    -82.7    165.4      289 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -0.8081 -0.2944 -0.2163 -0.1254  5.6179 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev. 
##  Mother (Intercept) 3.425e-01 0.5852746
##  Site   (Intercept) 8.894e-01 0.9430726
##  Room   (Intercept) 1.062e-07 0.0003259
## Number of obs: 304, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error z value Pr(>|z|)
## (Intercept)                                -2.69086    0.67160  -4.007 6.16e-05
## Treatment_bisFull                           1.29096    0.71956   1.794   0.0728
## Treatment_bisSmart                         -0.11529    1.03099  -0.112   0.9110
## Treatment_bisMixt_smart                   -33.98513 5819.93268  -0.006   0.9953
## SexMale                                     0.07099    0.63243   0.112   0.9106
## RegionLuxembourg                           -0.57942    0.96440  -0.601   0.5480
## Treatment_bisFull:SexMale                  -2.08720    1.08502  -1.924   0.0544
## Treatment_bisSmart:SexMale                  0.26663    1.51819   0.176   0.8606
## Treatment_bisMixt_smart:SexMale            17.81447 4184.83400   0.004   0.9966
## Treatment_bisFull:RegionLuxembourg         -0.82819    0.99234  -0.835   0.4040
## Treatment_bisSmart:RegionLuxembourg        -0.99425    1.50602  -0.660   0.5091
## Treatment_bisMixt_smart:RegionLuxembourg   17.28909 4044.59938   0.004   0.9966
##                                             
## (Intercept)                              ***
## Treatment_bisFull                        .  
## Treatment_bisSmart                          
## Treatment_bisMixt_smart                     
## SexMale                                     
## RegionLuxembourg                            
## Treatment_bisFull:SexMale                .  
## Treatment_bisSmart:SexMale                  
## Treatment_bisMixt_smart:SexMale             
## Treatment_bisFull:RegionLuxembourg          
## Treatment_bisSmart:RegionLuxembourg         
## Treatment_bisMixt_smart:RegionLuxembourg    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_F:SM T_S:SM T_M_:S
## Trtmnt_bsFl -0.571                                                        
## Trtmnt_bsSm -0.362  0.341                                                 
## Trtmnt_bsM_  0.000  0.000  0.000                                          
## SexMale     -0.395  0.372  0.271  0.000                                   
## ReginLxmbrg -0.573  0.280  0.170  0.000 -0.036                            
## Trtmnt_F:SM  0.266 -0.497 -0.163  0.000 -0.576 -0.001                     
## Trtmnt_S:SM  0.138 -0.129 -0.485  0.000 -0.427  0.033  0.232              
## Trtmn_M_:SM  0.000  0.000  0.000 -0.719  0.000  0.000  0.000  0.000       
## Trtmnt_F:RL  0.291 -0.571 -0.163  0.000  0.029 -0.480  0.087 -0.037  0.000
## Trtmnt_S:RL  0.181 -0.170 -0.478  0.000  0.016 -0.308 -0.001 -0.090  0.000
## Trtmn_M_:RL  0.000  0.000  0.000 -0.695  0.000  0.000  0.000  0.000  0.000
##             T_F:RL T_S:RL
## Trtmnt_bsFl              
## Trtmnt_bsSm              
## Trtmnt_bsM_              
## SexMale                  
## ReginLxmbrg              
## Trtmnt_F:SM              
## Trtmnt_S:SM              
## Trtmn_M_:SM              
## Trtmnt_F:RL              
## Trtmnt_S:RL  0.297       
## Trtmn_M_:RL  0.000  0.000
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## unable to evaluate scaled gradient
## Model failed to converge: degenerate  Hessian with 1 negative eigenvalues
summary(glmer(Diapause ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_ref_smart, family = binomial))
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: Diapause ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data_ref_smart
## 
##      AIC      BIC   logLik deviance df.resid 
##    195.4    251.2    -82.7    165.4      289 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -0.8064 -0.2939 -0.2164 -0.1255  5.6141 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev.
##  Mother (Intercept) 3.439e-01 0.586425
##  Site   (Intercept) 8.878e-01 0.942225
##  Room   (Intercept) 3.767e-06 0.001941
## Number of obs: 304, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                          Estimate Std. Error z value Pr(>|z|)
## (Intercept)                               -2.8030     1.0360  -2.706  0.00682
## Treatment_bisDark                          0.1132     1.0228   0.111  0.91185
## Treatment_bisFull                          1.4013     1.0502   1.334  0.18210
## Treatment_bisMixt_smart                  -33.9365   218.4837  -0.155  0.87656
## SexMale                                    0.3335     1.3528   0.247  0.80527
## RegionLuxembourg                          -1.5718     1.5176  -1.036  0.30034
## Treatment_bisDark:SexMale                 -0.2614     1.5112  -0.173  0.86266
## Treatment_bisFull:SexMale                 -2.3468     1.6419  -1.429  0.15291
## Treatment_bisMixt_smart:SexMale           17.9553   232.5937   0.077  0.93847
## Treatment_bisDark:RegionLuxembourg         0.9941     1.4674   0.677  0.49814
## Treatment_bisFull:RegionLuxembourg         0.1656     1.4989   0.110  0.91202
## Treatment_bisMixt_smart:RegionLuxembourg  17.9365   203.3988   0.088  0.92973
##                                            
## (Intercept)                              **
## Treatment_bisDark                          
## Treatment_bisFull                          
## Treatment_bisMixt_smart                    
## SexMale                                    
## RegionLuxembourg                           
## Treatment_bisDark:SexMale                  
## Treatment_bisFull:SexMale                  
## Treatment_bisMixt_smart:SexMale            
## Treatment_bisDark:RegionLuxembourg         
## Treatment_bisFull:RegionLuxembourg         
## Treatment_bisMixt_smart:RegionLuxembourg   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trt_M_ SexMal RgnLxm T_D:SM T_F:SM T_M_:S
## Trtmnt_bsDr -0.768                                                        
## Trtmnt_bsFl -0.799  0.750                                                 
## Trtmnt_bsM_  0.001 -0.001 -0.001                                          
## SexMale     -0.462  0.418  0.445  0.000                                   
## ReginLxmbrg -0.435  0.359  0.327 -0.001 -0.103                            
## Trtmnt_D:SM  0.433 -0.491 -0.412  0.000 -0.908  0.092                     
## Trtmnt_F:SM  0.411 -0.345 -0.506  0.000 -0.845  0.099  0.772              
## Trtmn_M_:SM  0.000  0.000  0.000 -0.595 -0.001  0.000  0.001  0.001       
## Trtmnt_D:RL  0.336 -0.476 -0.337  0.001  0.103 -0.775 -0.104 -0.095  0.000
## Trtmnt_F:RL  0.376 -0.368 -0.508  0.001  0.065 -0.747 -0.056 -0.010  0.000
## Trtmn_M_:RL  0.001 -0.001 -0.001 -0.394 -0.002 -0.002  0.002  0.002 -0.504
##             T_D:RL T_F:RL
## Trtmnt_bsDr              
## Trtmnt_bsFl              
## Trtmnt_bsM_              
## SexMale                  
## ReginLxmbrg              
## Trtmnt_D:SM              
## Trtmnt_F:SM              
## Trtmn_M_:SM              
## Trtmnt_D:RL              
## Trtmnt_F:RL  0.771       
## Trtmn_M_:RL  0.002  0.002
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## Model failed to converge with max|grad| = 0.0118311 (tol = 0.002, component 1)
## Model is nearly unidentifiable: large eigenvalue ratio
##  - Rescale variables?
summary(glmer(Diapause ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_ref_full, family = binomial))
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: Diapause ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data_ref_full
## 
##      AIC      BIC   logLik deviance df.resid 
##    195.4    251.2    -82.7    165.4      289 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -0.8093 -0.2939 -0.2160 -0.1254  5.6213 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev.
##  Mother (Intercept) 3.419e-01 0.584756
##  Site   (Intercept) 8.989e-01 0.948108
##  Room   (Intercept) 1.947e-06 0.001395
## Number of obs: 304, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                           Estimate Std. Error z value Pr(>|z|)
## (Intercept)                                -1.4003     0.6468  -2.165   0.0304
## Treatment_bisDark                          -1.2918     0.7197  -1.795   0.0727
## Treatment_bisSmart                         -1.4080     1.0370  -1.358   0.1745
## Treatment_bisMixt_smart                   -34.6146  4936.0524  -0.007   0.9944
## SexMale                                    -2.0169     0.8873  -2.273   0.0230
## RegionLuxembourg                           -1.4126     1.0003  -1.412   0.1579
## Treatment_bisDark:SexMale                   2.0903     1.0850   1.926   0.0540
## Treatment_bisSmart:SexMale                  2.3555     1.6489   1.429   0.1531
## Treatment_bisMixt_smart:SexMale            19.4483  3330.5276   0.006   0.9953
## Treatment_bisDark:RegionLuxembourg          0.8258     0.9925   0.832   0.4054
## Treatment_bisSmart:RegionLuxembourg        -0.1627     1.5373  -0.106   0.9157
## Treatment_bisMixt_smart:RegionLuxembourg   17.9108  3643.1034   0.005   0.9961
##                                           
## (Intercept)                              *
## Treatment_bisDark                        .
## Treatment_bisSmart                        
## Treatment_bisMixt_smart                   
## SexMale                                  *
## RegionLuxembourg                          
## Treatment_bisDark:SexMale                .
## Treatment_bisSmart:SexMale                
## Treatment_bisMixt_smart:SexMale           
## Treatment_bisDark:RegionLuxembourg        
## Treatment_bisSmart:RegionLuxembourg       
## Treatment_bisMixt_smart:RegionLuxembourg  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S Trt_M_ SexMal RgnLxm T_D:SM T_S:SM T_M_:S
## Trtmnt_bsDr -0.519                                                        
## Trtmnt_bsSm -0.357  0.355                                                 
## Trtmnt_bsM_  0.000  0.000  0.000                                          
## SexMale     -0.335  0.342  0.231  0.000                                   
## ReginLxmbrg -0.608  0.297  0.208  0.000  0.100                            
## Trtmnt_D:SM  0.276 -0.497 -0.183  0.000 -0.813 -0.085                     
## Trtmnt_S:SM  0.181 -0.208 -0.481  0.000 -0.554 -0.061  0.445              
## Trtmn_M_:SM  0.000  0.000  0.000 -0.675  0.000  0.000  0.000  0.000       
## Trtmnt_D:RL  0.334 -0.571 -0.235  0.000 -0.127 -0.529  0.087  0.092  0.000
## Trtmnt_S:RL  0.215 -0.203 -0.502  0.000 -0.072 -0.344  0.057 -0.022  0.000
## Trtmn_M_:RL  0.000  0.000  0.000 -0.738  0.000  0.000  0.000  0.000  0.000
##             T_D:RL T_S:RL
## Trtmnt_bsDr              
## Trtmnt_bsSm              
## Trtmnt_bsM_              
## SexMale                  
## ReginLxmbrg              
## Trtmnt_D:SM              
## Trtmnt_S:SM              
## Trtmn_M_:SM              
## Trtmnt_D:RL              
## Trtmnt_S:RL  0.355       
## Trtmn_M_:RL  0.000  0.000
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## unable to evaluate scaled gradient
## Model failed to converge: degenerate  Hessian with 1 negative eigenvalues
Info_Diapause <-"
Les individus du traitement Full ont quasiements significativement (p-val = 0.0728) une plus grande probabilité d'être en diapause que les individus du traitement Dark.
Les mâles du traitement Full ont significativements une plus petite probabilité de rentrer en diapause par rapport aux femelles du même traitement.
"

4.2.4 Visualisation

ggplot(Data) +
  aes(x = Diapause, fill = Treatment) +
  geom_bar(position = "dodge") +
  scale_fill_hue(direction = 1) +
  facet_grid(~Species) +
  labs(title = "Nombre de diapause chez AE et OP", y = "Nombre", x = "Diapause", fill = "Traitement") +
  theme_minimal()

4.3 TT_pupation

4.3.1 Test

LM_TT_pupation <- lmer(TT_pupation ~ Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region, data = Data)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
summary(LM_TT_pupation)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: TT_pupation ~ Treatment_bis + Sex + Species + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Sex:Species + Region:Species +  
##     Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data
## 
## REML criterion at convergence: 2134.8
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.9654 -0.4416 -0.0861  0.2605  5.2458 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 11.38    3.373   
##  Site     (Intercept) 23.20    4.817   
##  Room     (Intercept)  0.00    0.000   
##  Residual             72.18    8.496   
## Number of obs: 304, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                          Estimate Std. Error       df t value
## (Intercept)                               43.6897     2.7783  19.0993  15.725
## Treatment_bisFull                         -2.0835     2.2129 265.4220  -0.942
## Treatment_bisSmart                        -5.8623     2.6506 263.4238  -2.212
## Treatment_bisMixt_smart                   -1.6053     3.0843 267.4236  -0.520
## SexMale                                    0.8035     2.0424 272.9850   0.393
## SpeciesOP                                -26.0565     3.0826  34.0980  -8.453
## RegionLuxembourg                           5.9235     3.6424  16.1600   1.626
## SexMale:SpeciesOP                         -1.6867     2.1637 268.1280  -0.780
## SpeciesOP:RegionLuxembourg                -6.4407     3.7776  20.5335  -1.705
## Treatment_bisFull:SpeciesOP               -0.3947     2.3514 264.8778  -0.168
## Treatment_bisSmart:SpeciesOP               9.3164     3.0539 264.2310   3.051
## Treatment_bisFull:SexMale                  1.1886     2.3601 268.3797   0.504
## Treatment_bisSmart:SexMale                -0.6361     3.1106 274.9649  -0.205
## Treatment_bisMixt_smart:SexMale           -6.1167     3.9013 273.4112  -1.568
## Treatment_bisFull:RegionLuxembourg         3.2045     2.3379 264.5498   1.371
## Treatment_bisSmart:RegionLuxembourg       -3.8231     2.9792 262.2092  -1.283
## Treatment_bisMixt_smart:RegionLuxembourg  12.4549     3.8213 268.2423   3.259
##                                          Pr(>|t|)    
## (Intercept)                              2.19e-12 ***
## Treatment_bisFull                         0.34730    
## Treatment_bisSmart                        0.02785 *  
## Treatment_bisMixt_smart                   0.60316    
## SexMale                                   0.69431    
## SpeciesOP                                7.00e-10 ***
## RegionLuxembourg                          0.12324    
## SexMale:SpeciesOP                         0.43635    
## SpeciesOP:RegionLuxembourg                0.10328    
## Treatment_bisFull:SpeciesOP               0.86682    
## Treatment_bisSmart:SpeciesOP              0.00252 ** 
## Treatment_bisFull:SexMale                 0.61493    
## Treatment_bisSmart:SexMale                0.83811    
## Treatment_bisMixt_smart:SexMale           0.11807    
## Treatment_bisFull:RegionLuxembourg        0.17165    
## Treatment_bisSmart:RegionLuxembourg       0.20054    
## Treatment_bisMixt_smart:RegionLuxembourg  0.00126 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 17 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Normalité des résidus

qqnorm(resid(LM_TT_pupation))
qqline(resid(LM_TT_pupation))

Normalité non vérifiée, on modifie les données

LM_TT_pupation <- lmer(log(TT_pupation) ~ Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region, data = Data)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')

Normalité des résidus

qqnorm(resid(LM_TT_pupation))
qqline(resid(LM_TT_pupation))

C’est bien mieux

Homogénité des variances

plot(LM_TT_pupation)

Distance de cook

plot(cooks.distance(LM_TT_pupation))

4.3.2 Simplification du modèle

drop1(LM_TT_pupation)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(TT_pupation) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region
##                        Sum Sq  Mean Sq NumDF   DenDF F value   Pr(>F)   
## Sex:Species           0.08876 0.088757     1 266.356  2.4951 0.115389   
## Species:Region        0.07043 0.070426     1  24.272  1.9798 0.172090   
## Treatment_bis:Species 0.37054 0.185270     2 262.455  5.2082 0.006051 **
## Treatment_bis:Sex     0.09525 0.031751     3 268.905  0.8926 0.445454   
## Treatment_bis:Region  0.48820 0.162732     3 262.288  4.5746 0.003843 **
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_TT_pupation1 <- update(LM_TT_pupation, . ~ . - Treatment_bis:Sex)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
drop1(LM_TT_pupation1)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(TT_pupation) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Species:Region + Treatment_bis:Species + Treatment_bis:Region
##                        Sum Sq  Mean Sq NumDF   DenDF F value   Pr(>F)   
## Sex:Species           0.04739 0.047390     1 269.295  1.3375 0.248507   
## Species:Region        0.07172 0.071715     1  24.948  2.0240 0.167218   
## Treatment_bis:Species 0.37345 0.186723     2 265.128  5.2698 0.005697 **
## Treatment_bis:Region  0.47669 0.158896     3 265.281  4.4844 0.004328 **
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_TT_pupation2 <- update(LM_TT_pupation1, . ~ . - Species:Region)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
drop1(LM_TT_pupation2)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(TT_pupation) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Treatment_bis:Species + Treatment_bis:Region
##                        Sum Sq  Mean Sq NumDF  DenDF F value   Pr(>F)   
## Sex:Species           0.04637 0.046373     1 269.57  1.3109 0.253251   
## Treatment_bis:Species 0.35527 0.177637     2 266.05  5.0215 0.007234 **
## Treatment_bis:Region  0.51978 0.173260     3 268.64  4.8977 0.002486 **
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_TT_pupation3 <- update(LM_TT_pupation2, . ~ . - Sex:Species)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
drop1(LM_TT_pupation3)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(TT_pupation) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Species + Treatment_bis:Region
##                        Sum Sq  Mean Sq NumDF  DenDF F value   Pr(>F)   
## Sex                   0.01930 0.019299     1 271.14  0.5460 0.460606   
## Treatment_bis:Species 0.36260 0.181298     2 266.67  5.1289 0.006521 **
## Treatment_bis:Region  0.52963 0.176542     3 269.39  4.9943 0.002184 **
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_TT_pupation4 <- update(LM_TT_pupation3, . ~ . - Sex)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
drop1(LM_TT_pupation4)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(TT_pupation) ~ Treatment_bis + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Species + Treatment_bis:Region
##                        Sum Sq Mean Sq NumDF  DenDF F value   Pr(>F)   
## Treatment_bis:Species 0.54568 0.27284     2 278.00  7.0389 0.001042 **
## Treatment_bis:Region  0.48652 0.16217     3 281.36  4.1838 0.006419 **
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
AIC(LM_TT_pupation)
## [1] -3.013188
AIC(LM_TT_pupation2)
## [1] -20.08038
AIC(LM_TT_pupation3)
## [1] -25.1234
AIC(LM_TT_pupation4)
## [1] -12.10204

Le meilleur modèle est le dernier (et en plus c’est le plus simple)

LM_TT_pupation <- lmer(log(TT_pupation) ~ Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex , data = Data)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')

4.3.3 Treatment VS Treatment_bis

AIC(lmer(log(TT_pupation) ~ Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex , data = Data))
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
## [1] -6.633181
AIC(lmer(log(TT_pupation) ~ Treatment + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Sex:Species + Region:Species + Treatment:Species + Treatment:Sex , data = Data))
## [1] -2.274728
summary(lmer(log(TT_pupation) ~ Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Region + Treatment_bis:Species , data = Data))$coeff
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
##                                             Estimate Std. Error         df
## (Intercept)                               3.77610265 0.05429042  12.938393
## Treatment_bisFull                        -0.01950870 0.04341651 266.819071
## Treatment_bisSmart                       -0.11957283 0.05386700 265.169701
## Treatment_bisMixt_smart                  -0.07251908 0.05767618 271.164010
## SexMale                                  -0.01672386 0.02263342 271.143916
## SpeciesOP                                -1.10427693 0.05756314  43.691433
## RegionLuxembourg                          0.06218835 0.06865808   9.016883
## Treatment_bisFull:RegionLuxembourg        0.07849757 0.05185327 267.789463
## Treatment_bisSmart:RegionLuxembourg      -0.06105654 0.06574407 266.735175
## Treatment_bisMixt_smart:RegionLuxembourg  0.26851935 0.08394681 278.353468
## Treatment_bisFull:SpeciesOP              -0.03738171 0.05191725 267.548880
## Treatment_bisSmart:SpeciesOP              0.17834786 0.06722218 266.433847
##                                              t value     Pr(>|t|)
## (Intercept)                               69.5537518 4.863173e-18
## Treatment_bisFull                         -0.4493384 6.535523e-01
## Treatment_bisSmart                        -2.2197789 2.727982e-02
## Treatment_bisMixt_smart                   -1.2573488 2.097092e-01
## SexMale                                   -0.7389014 4.606060e-01
## SpeciesOP                                -19.1837516 6.615424e-23
## RegionLuxembourg                           0.9057688 3.886203e-01
## Treatment_bisFull:RegionLuxembourg         1.5138404 1.312457e-01
## Treatment_bisSmart:RegionLuxembourg       -0.9287003 3.538841e-01
## Treatment_bisMixt_smart:RegionLuxembourg   3.1986844 1.540074e-03
## Treatment_bisFull:SpeciesOP               -0.7200247 4.721383e-01
## Treatment_bisSmart:SpeciesOP               2.6531103 8.454303e-03
summary(lmer(log(TT_pupation) ~ Treatment + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment:Region + Treatment:Species, data = Data))$coeff
##                                     Estimate Std. Error         df     t value
## (Intercept)                      3.780751833 0.05640102  11.335252  67.0333941
## TreatmentFull                   -0.029148130 0.04591439 268.365046  -0.6348366
## TreatmentSmart                  -0.087902764 0.04575129 270.330492  -1.9213177
## SexMale                         -0.007683795 0.02352130 272.347985  -0.3266739
## SpeciesOP                       -1.120694368 0.06128983  56.768536 -18.2851590
## RegionLuxembourg                 0.054444947 0.06627489   9.009504   0.8215019
## TreatmentFull:RegionLuxembourg   0.087292304 0.05706355 269.427478   1.5297385
## TreatmentSmart:RegionLuxembourg  0.055271076 0.05659217 268.917444   0.9766558
## TreatmentFull:SpeciesOP         -0.032135196 0.05679876 268.538867  -0.5657729
## TreatmentSmart:SpeciesOP         0.067552879 0.05671879 268.781807   1.1910141
##                                     Pr(>|t|)
## (Intercept)                     4.305979e-16
## TreatmentFull                   5.260759e-01
## TreatmentSmart                  5.574309e-02
## SexMale                         7.441654e-01
## SpeciesOP                       1.837220e-25
## RegionLuxembourg                4.325610e-01
## TreatmentFull:RegionLuxembourg  1.272547e-01
## TreatmentSmart:RegionLuxembourg 3.296173e-01
## TreatmentFull:SpeciesOP         5.720206e-01
## TreatmentSmart:SpeciesOP        2.346988e-01

Le modèle treatment_bis a des p-val concernants les traitements plus significatifs et est mieux selon l’AIC.

Analyse des P-val

summary(lmer(log(TT_pupation) ~ Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Region + Treatment_bis:Species , data = Data))
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(TT_pupation) ~ Treatment_bis + Sex + Species + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  
##     Treatment_bis:Species
##    Data: Data
## 
## REML criterion at convergence: -57.1
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.2068 -0.6222 -0.0553  0.4602  3.9758 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.012935 0.11373 
##  Site     (Intercept) 0.005718 0.07562 
##  Room     (Intercept) 0.000000 0.00000 
##  Residual             0.035349 0.18801 
## Number of obs: 304, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                           Estimate Std. Error        df t value
## (Intercept)                                3.77610    0.05429  12.93839  69.554
## Treatment_bisFull                         -0.01951    0.04342 266.81907  -0.449
## Treatment_bisSmart                        -0.11957    0.05387 265.16970  -2.220
## Treatment_bisMixt_smart                   -0.07252    0.05768 271.16401  -1.257
## SexMale                                   -0.01672    0.02263 271.14392  -0.739
## SpeciesOP                                 -1.10428    0.05756  43.69143 -19.184
## RegionLuxembourg                           0.06219    0.06866   9.01688   0.906
## Treatment_bisFull:RegionLuxembourg         0.07850    0.05185 267.78946   1.514
## Treatment_bisSmart:RegionLuxembourg       -0.06106    0.06574 266.73517  -0.929
## Treatment_bisMixt_smart:RegionLuxembourg   0.26852    0.08395 278.35347   3.199
## Treatment_bisFull:SpeciesOP               -0.03738    0.05192 267.54888  -0.720
## Treatment_bisSmart:SpeciesOP               0.17835    0.06722 266.43385   2.653
##                                          Pr(>|t|)    
## (Intercept)                               < 2e-16 ***
## Treatment_bisFull                         0.65355    
## Treatment_bisSmart                        0.02728 *  
## Treatment_bisMixt_smart                   0.20971    
## SexMale                                   0.46061    
## SpeciesOP                                 < 2e-16 ***
## RegionLuxembourg                          0.38862    
## Treatment_bisFull:RegionLuxembourg        0.13125    
## Treatment_bisSmart:RegionLuxembourg       0.35388    
## Treatment_bisMixt_smart:RegionLuxembourg  0.00154 ** 
## Treatment_bisFull:SpeciesOP               0.47214    
## Treatment_bisSmart:SpeciesOP              0.00845 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal SpcsOP RgnLxm T_F:RL T_S:RL
## Trtmnt_bsFl -0.378                                                        
## Trtmnt_bsSm -0.311  0.399                                                 
## Trtmnt_bsM_ -0.297  0.387  0.313                                          
## SexMale     -0.168 -0.044  0.039 -0.015                                   
## SpeciesOP   -0.446  0.267  0.215  0.193  0.020                            
## ReginLxmbrg -0.606  0.172  0.138  0.155 -0.018  0.002                     
## Trtmnt_F:RL  0.172 -0.494 -0.184 -0.187  0.032  0.032 -0.351              
## Trtmnt_S:RL  0.143 -0.182 -0.593 -0.164 -0.015  0.026 -0.290  0.370       
## Trtmn_M_:RL  0.122 -0.147 -0.132 -0.627 -0.014  0.040 -0.253  0.319  0.267
## Trtmn_F:SOP  0.246 -0.584 -0.249 -0.230 -0.042 -0.416  0.024 -0.094 -0.024
## Trtmn_S:SOP  0.194 -0.232 -0.469 -0.165 -0.067 -0.324  0.023 -0.027 -0.083
##             T_M_:R T_F:SO
## Trtmnt_bsFl              
## Trtmnt_bsSm              
## Trtmnt_bsM_              
## SexMale                  
## SpeciesOP                
## ReginLxmbrg              
## Trtmnt_F:RL              
## Trtmnt_S:RL              
## Trtmn_M_:RL              
## Trtmn_F:SOP -0.034       
## Trtmn_S:SOP -0.030  0.360
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(TT_pupation) ~ Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Region + Treatment_bis:Species , data = Data_ref_full))
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(TT_pupation) ~ Treatment_bis + Sex + Species + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  
##     Treatment_bis:Species
##    Data: Data_ref_full
## 
## REML criterion at convergence: -57.1
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.2068 -0.6222 -0.0553  0.4602  3.9758 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.012935 0.11373 
##  Site     (Intercept) 0.005718 0.07562 
##  Room     (Intercept) 0.000000 0.00000 
##  Residual             0.035349 0.18801 
## Number of obs: 304, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                           Estimate Std. Error        df t value
## (Intercept)                                3.75659    0.05521  14.02771  68.037
## Treatment_bisDark                          0.01951    0.04342 266.81907   0.449
## Treatment_bisSmart                        -0.10006    0.05405 262.21600  -1.851
## Treatment_bisMixt_smart                   -0.05301    0.05722 265.73700  -0.926
## SexMale                                   -0.01672    0.02263 271.14392  -0.739
## SpeciesOP                                 -1.14166    0.05935  47.95417 -19.236
## RegionLuxembourg                           0.14069    0.07004  10.05440   2.009
## Treatment_bisDark:RegionLuxembourg        -0.07850    0.05185 267.78946  -1.514
## Treatment_bisSmart:RegionLuxembourg       -0.13955    0.06701 265.12660  -2.083
## Treatment_bisMixt_smart:RegionLuxembourg   0.19002    0.08344 273.14728   2.277
## Treatment_bisDark:SpeciesOP                0.03738    0.05192 267.54888   0.720
## Treatment_bisSmart:SpeciesOP               0.21573    0.06859 265.61916   3.145
##                                          Pr(>|t|)    
## (Intercept)                               < 2e-16 ***
## Treatment_bisDark                         0.65355    
## Treatment_bisSmart                        0.06523 .  
## Treatment_bisMixt_smart                   0.35510    
## SexMale                                   0.46061    
## SpeciesOP                                 < 2e-16 ***
## RegionLuxembourg                          0.07217 .  
## Treatment_bisDark:RegionLuxembourg        0.13125    
## Treatment_bisSmart:RegionLuxembourg       0.03823 *  
## Treatment_bisMixt_smart:RegionLuxembourg  0.02354 *  
## Treatment_bisDark:SpeciesOP               0.47214    
## Treatment_bisSmart:SpeciesOP              0.00185 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S Trt_M_ SexMal SpcsOP RgnLxm T_D:RL T_S:RL
## Trtmnt_bsDr -0.414                                                        
## Trtmnt_bsSm -0.325  0.406                                                 
## Trtmnt_bsM_ -0.302  0.369  0.309                                          
## SexMale     -0.199  0.044  0.074  0.018                                   
## SpeciesOP   -0.412  0.252  0.193  0.177 -0.018                            
## ReginLxmbrg -0.613  0.197  0.157  0.163  0.006 -0.015                     
## Trtmnt_D:RL  0.219 -0.494 -0.214 -0.187 -0.032  0.051 -0.396              
## Trtmnt_S:RL  0.167 -0.204 -0.602 -0.171 -0.040  0.043 -0.317  0.411       
## Trtmn_M_:RL  0.140 -0.159 -0.146 -0.639 -0.034  0.040 -0.259  0.301  0.270
## Trtmn_D:SOP  0.217 -0.584 -0.222 -0.211  0.042 -0.471  0.046 -0.094 -0.049
## Trtmn_S:SOP  0.173 -0.215 -0.443 -0.151 -0.034 -0.357  0.037 -0.045 -0.096
##             T_M_:R T_D:SO
## Trtmnt_bsDr              
## Trtmnt_bsSm              
## Trtmnt_bsM_              
## SexMale                  
## SpeciesOP                
## ReginLxmbrg              
## Trtmnt_D:RL              
## Trtmnt_S:RL              
## Trtmn_M_:RL              
## Trtmn_D:SOP -0.024       
## Trtmn_S:SOP -0.031  0.405
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(TT_pupation) ~ Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Region + Treatment_bis:Species , data = Data_ref_smart))
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(TT_pupation) ~ Treatment_bis + Sex + Species + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  
##     Treatment_bis:Species
##    Data: Data_ref_smart
## 
## REML criterion at convergence: -57.1
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.2068 -0.6222 -0.0553  0.4602  3.9758 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.012935 0.11373 
##  Site     (Intercept) 0.005718 0.07562 
##  Room     (Intercept) 0.000000 0.00000 
##  Residual             0.035349 0.18801 
## Number of obs: 304, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                                3.656530   0.063466  23.026455
## Treatment_bisDark                          0.119573   0.053867 265.169700
## Treatment_bisFull                          0.100064   0.054047 262.216001
## Treatment_bisMixt_smart                    0.047054   0.065443 264.421486
## SexMale                                   -0.016724   0.022633 271.143916
## SpeciesOP                                 -0.925929   0.072961 101.429192
## RegionLuxembourg                           0.001132   0.080137  16.863093
## Treatment_bisDark:RegionLuxembourg         0.061057   0.065744 266.735175
## Treatment_bisFull:RegionLuxembourg         0.139554   0.067005 265.126605
## Treatment_bisMixt_smart:RegionLuxembourg   0.329576   0.091801 270.349382
## Treatment_bisDark:SpeciesOP               -0.178348   0.067222 266.433847
## Treatment_bisFull:SpeciesOP               -0.215730   0.068588 265.619155
##                                          t value Pr(>|t|)    
## (Intercept)                               57.614  < 2e-16 ***
## Treatment_bisDark                          2.220 0.027280 *  
## Treatment_bisFull                          1.851 0.065230 .  
## Treatment_bisMixt_smart                    0.719 0.472773    
## SexMale                                   -0.739 0.460606    
## SpeciesOP                                -12.691  < 2e-16 ***
## RegionLuxembourg                           0.014 0.988897    
## Treatment_bisDark:RegionLuxembourg         0.929 0.353884    
## Treatment_bisFull:RegionLuxembourg         2.083 0.038234 *  
## Treatment_bisMixt_smart:RegionLuxembourg   3.590 0.000392 ***
## Treatment_bisDark:SpeciesOP               -2.653 0.008454 ** 
## Treatment_bisFull:SpeciesOP               -3.145 0.001848 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trt_M_ SexMal SpcsOP RgnLxm T_D:RL T_F:RL
## Trtmnt_bsDr -0.582                                                        
## Trtmnt_bsFl -0.569  0.676                                                 
## Trtmnt_bsM_ -0.469  0.547  0.555                                          
## SexMale     -0.110 -0.039 -0.074 -0.045                                   
## SpeciesOP   -0.371  0.263  0.260  0.216 -0.046                            
## ReginLxmbrg -0.657  0.369  0.366  0.302 -0.028 -0.027                     
## Trtmnt_D:RL  0.382 -0.593 -0.445 -0.344  0.015  0.056 -0.572              
## Trtmnt_F:RL  0.368 -0.440 -0.602 -0.348  0.040  0.056 -0.559  0.695       
## Trtmn_M_:RL  0.266 -0.304 -0.307 -0.652 -0.002  0.044 -0.408  0.472  0.484
## Trtmn_D:SOP  0.232 -0.469 -0.281 -0.241  0.067 -0.666  0.049 -0.083 -0.061
## Trtmn_F:SOP  0.227 -0.272 -0.443 -0.234  0.034 -0.650  0.049 -0.063 -0.096
##             T_M_:R T_D:SO
## Trtmnt_bsDr              
## Trtmnt_bsFl              
## Trtmnt_bsM_              
## SexMale                  
## SpeciesOP                
## ReginLxmbrg              
## Trtmnt_D:RL              
## Trtmnt_F:RL              
## Trtmn_M_:RL              
## Trtmn_D:SOP -0.032       
## Trtmn_F:SOP -0.042  0.708
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
Infos_TT_pupation <- "
OP est plus rapide.
Smart est significativement plus rapide que Dark chez AE mais Smart est significativement plus lent que Dark et Full chez OP.
Full est quasiment significativement (0.082) plus lent que Dark mais uniquement dans le Luxembourg.
Full est quasiment significativement (0.086) plus lent que Smart.
Full est quasiment significativement (0.097) plus lent dans le Luxembourg.
Mixt_smart est plus lent que n'importe quel autre treatment mais uniquement dans le Luxembourg
"
Infos_TT_pupation
## [1] "\nOP est plus rapide.\nSmart est significativement plus rapide que Dark chez AE mais Smart est significativement plus lent que Dark et Full chez OP.\nFull est quasiment significativement (0.082) plus lent que Dark mais uniquement dans le Luxembourg.\nFull est quasiment significativement (0.086) plus lent que Smart.\nFull est quasiment significativement (0.097) plus lent dans le Luxembourg.\nMixt_smart est plus lent que n'importe quel autre treatment mais uniquement dans le Luxembourg\n"

4.3.4 Visualisation

Summary_TT_pupation <- Data %>% 
  filter(Did_pupated == "Yes") %>% 
  group_by(Treatment_bis, Species, Region) %>% 
  summarise(Mean=mean(log(TT_pupation)),
            Var=var(log(TT_pupation)),
            N=n()) %>% 
  mutate(CI_S=Mean+qt(0.975, N-1)*sqrt(Var/N),
         CI_I=Mean-qt(0.975, N-1)*sqrt(Var/N))
ggplot(Summary_TT_pupation, aes(x=Treatment_bis, y=Mean, color = Species))+
  geom_errorbar(aes(ymin=CI_I, ymax=CI_S),width=0.2,size = 1.2, alpha = 0.5) +
  geom_point(alpha = 0.8) +
  facet_grid(~Region) +
  labs(title = "Temps pour entrer en chrysalide", x = "Traitement", y = "log(Nombre de jours)", color = "Espèce") +
  theme_bw()

Summary_TT_pupation2 <- Data %>%
  filter(Did_pupated == "Yes") %>% 
  group_by(Treatment_bis, Species) %>% 
  summarise(Mean=mean(log(TT_pupation)),
            Var=var(log(TT_pupation)),
            N=n()) %>% 
  mutate(CI_S=Mean+qt(0.975, N-1)*sqrt(Var/N),
         CI_I=Mean-qt(0.975, N-1)*sqrt(Var/N))
ggplot(Summary_TT_pupation2, aes(x=Treatment_bis, y=Mean, color = Species))+
  geom_errorbar(aes(ymin=CI_I, ymax=CI_S),width=0.2,size = 1.2, alpha = 0.5) +
  geom_point(alpha = 0.8) +
  labs(title = "Time to Pupation", x = "Treatment", y = "log(Days)") +
  theme_bw()

4.4 Time_in_pupa

4.4.1 Test

LM_Time_in_pupa <- lmer(Time_in_pupa ~ Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region, data = Data)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
summary(LM_TT_pupation)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(TT_pupation) ~ Treatment_bis + Sex + Species + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Sex:Species + Region:Species +  
##     Treatment_bis:Species + Treatment_bis:Sex
##    Data: Data
## 
## REML criterion at convergence: -42.6
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.1358 -0.5872 -0.1119  0.5122  4.1975 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.009186 0.09584 
##  Site     (Intercept) 0.007935 0.08908 
##  Room     (Intercept) 0.000000 0.00000 
##  Residual             0.037209 0.19290 
## Number of obs: 304, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                   Estimate Std. Error         df t value
## (Intercept)                       3.703375   0.059318  17.639677  62.433
## Treatment_bisFull                 0.003632   0.045196 270.551334   0.080
## Treatment_bisSmart               -0.149036   0.051781 267.531050  -2.878
## Treatment_bisMixt_smart           0.094418   0.060451 273.190577   1.562
## SexMale                           0.032073   0.046472 274.662322   0.690
## SpeciesOP                        -0.978520   0.075109  36.810031 -13.028
## RegionLuxembourg                  0.167889   0.072314  11.490685   2.322
## SexMale:SpeciesOP                -0.080675   0.049172 270.185399  -1.641
## SpeciesOP:RegionLuxembourg       -0.177645   0.093183  22.435976  -1.906
## Treatment_bisFull:SpeciesOP      -0.020124   0.053223 266.394454  -0.378
## Treatment_bisSmart:SpeciesOP      0.186982   0.069245 266.224474   2.700
## Treatment_bisFull:SexMale         0.008564   0.053709 269.268432   0.159
## Treatment_bisSmart:SexMale       -0.019486   0.070773 277.233351  -0.275
## Treatment_bisMixt_smart:SexMale  -0.122305   0.088787 274.741600  -1.378
##                                 Pr(>|t|)    
## (Intercept)                      < 2e-16 ***
## Treatment_bisFull                0.93601    
## Treatment_bisSmart               0.00432 ** 
## Treatment_bisMixt_smart          0.11947    
## SexMale                          0.49068    
## SpeciesOP                       2.35e-15 ***
## RegionLuxembourg                 0.03953 *  
## SexMale:SpeciesOP                0.10203    
## SpeciesOP:RegionLuxembourg       0.06949 .  
## Treatment_bisFull:SpeciesOP      0.70566    
## Treatment_bisSmart:SpeciesOP     0.00737 ** 
## Treatment_bisFull:SexMale        0.87344    
## Treatment_bisSmart:SexMale       0.78327    
## Treatment_bisMixt_smart:SexMale  0.16947    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 14 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Vérification de la normalité

qqnorm(resid(LM_Time_in_pupa))
qqline(resid(LM_Time_in_pupa))

Homogénité des variances

plot(LM_Time_in_pupa)

Distance de cook

plot(cooks.distance(LM_Time_in_pupa))

4.4.2 Simplification du modèle

drop1(LM_Time_in_pupa)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Time_in_pupa ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region
##                        Sum Sq Mean Sq NumDF   DenDF F value   Pr(>F)   
## Sex:Species            0.0006  0.0006     1 233.454  0.0007 0.979312   
## Species:Region         0.2057  0.2057     1  24.657  0.2453 0.624763   
## Treatment_bis:Species  0.0504  0.0252     2 225.751  0.0301 0.970386   
## Treatment_bis:Sex      0.4442  0.1481     3 236.799  0.1766 0.912182   
## Treatment_bis:Region  10.6469  3.5490     3 226.603  4.2325 0.006184 **
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Time_in_pupa1 <- update(LM_Time_in_pupa, . ~ . - Treatment_bis:Species)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Time_in_pupa1)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Time_in_pupa ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Species:Region + Treatment_bis:Sex + Treatment_bis:Region
##                       Sum Sq Mean Sq NumDF   DenDF F value   Pr(>F)   
## Sex:Species           0.0018  0.0018     1 234.291  0.0021 0.963184   
## Species:Region        0.2232  0.2232     1  24.502  0.2685 0.608970   
## Treatment_bis:Sex     0.4791  0.1597     3 238.458  0.1921 0.901693   
## Treatment_bis:Region 10.6736  3.5579     3 228.099  4.2809 0.005794 **
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Time_in_pupa2 <- update(LM_Time_in_pupa1, . ~ . - Sex:Species)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Time_in_pupa2)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Time_in_pupa ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region + Treatment_bis:Sex + Treatment_bis:Region
##                       Sum Sq Mean Sq NumDF   DenDF F value   Pr(>F)   
## Species:Region        0.2233  0.2233     1  24.508  0.2699 0.608084   
## Treatment_bis:Sex     0.4781  0.1594     3 239.938  0.1926 0.901365   
## Treatment_bis:Region 10.6700  3.5567     3 228.953  4.2984 0.005659 **
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Time_in_pupa3 <- update(LM_Time_in_pupa2, . ~ . - Treatment_bis:Sex)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Time_in_pupa3)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Time_in_pupa ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region + Treatment_bis:Region
##                       Sum Sq Mean Sq NumDF   DenDF F value    Pr(>F)    
## Sex                  14.4272 14.4272     1 240.509 17.5990 3.838e-05 ***
## Species:Region        0.2293  0.2293     1  24.592  0.2797  0.601642    
## Treatment_bis:Region 10.6710  3.5570     3 231.728  4.3390  0.005353 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Time_in_pupa4 <- update(LM_Time_in_pupa3, . ~ . - Species:Region)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Time_in_pupa4)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Time_in_pupa ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region
##                       Sum Sq Mean Sq NumDF   DenDF F value    Pr(>F)    
## Sex                  14.5453 14.5453     1 240.987 17.7076 3.637e-05 ***
## Species               7.6276  7.6276     1  25.499  9.2859  0.005316 ** 
## Treatment_bis:Region 11.7854  3.9285     3 237.395  4.7825  0.002960 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Regardons si les simplifications étaient utiles

AIC(LM_Time_in_pupa4)
## [1] 757.3326
AIC(LM_Time_in_pupa)
## [1] 773.8755

Les simplifications étaient utiles

LM_Time_in_pupa <- LM_Time_in_pupa4

4.4.3 Treatment VS Treatment_bis

AIC(lmer(Time_in_pupa ~ Treatment_bis + Sex + Species + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region , data = Data))
## boundary (singular) fit: see help('isSingular')
## [1] 757.3326
AIC(lmer(Time_in_pupa ~ Treatment + Sex + Species + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment:Region , data = Data))
## boundary (singular) fit: see help('isSingular')
## [1] 777.6884
summary(lmer(Time_in_pupa ~ Treatment_bis + Sex + Species + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region , data = Data))$coeff
## boundary (singular) fit: see help('isSingular')
##                                             Estimate Std. Error         df
## (Intercept)                              13.45331264  0.3249256   1.817888
## Treatment_bisFull                         0.45732669  0.1850741 229.313659
## Treatment_bisSmart                        0.09052413  0.2551831 228.989561
## Treatment_bisMixt_smart                   0.42937690  0.2813087 243.934122
## SexMale                                   0.49161888  0.1168286 240.987065
## SpeciesOP                                -0.55825601  0.1831983  25.498629
## RegionLuxembourg                         -0.06501675  0.2244022  61.155647
## Treatment_bisFull:RegionLuxembourg       -0.28437877  0.2675173 228.196157
## Treatment_bisSmart:RegionLuxembourg      -0.17391802  0.3339218 231.779821
## Treatment_bisMixt_smart:RegionLuxembourg  1.28735203  0.4186491 251.087106
##                                             t value     Pr(>|t|)
## (Intercept)                              41.4042883 1.025199e-03
## Treatment_bisFull                         2.4710458 1.420013e-02
## Treatment_bisSmart                        0.3547418 7.231095e-01
## Treatment_bisMixt_smart                   1.5263549 1.282170e-01
## SexMale                                   4.2080344 3.637027e-05
## SpeciesOP                                -3.0472775 5.315530e-03
## RegionLuxembourg                         -0.2897331 7.730005e-01
## Treatment_bisFull:RegionLuxembourg       -1.0630294 2.888923e-01
## Treatment_bisSmart:RegionLuxembourg      -0.5208345 6.029792e-01
## Treatment_bisMixt_smart:RegionLuxembourg  3.0750143 2.337524e-03
summary(lmer(Time_in_pupa ~ Treatment + Sex + Species + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment:Region , data = Data))$coeff
## boundary (singular) fit: see help('isSingular')
##                                    Estimate Std. Error         df    t value
## (Intercept)                     13.54506094  0.4239224   1.480875 31.9517457
## TreatmentFull                    0.42000429  0.2040923 227.548411  2.0579139
## TreatmentSmart                   0.09595950  0.1998780 229.649815  0.4800903
## SexMale                          0.53525851  0.1220365 242.847208  4.3860510
## SpeciesOP                       -0.75352492  0.1794630  21.626285 -4.1987768
## RegionLuxembourg                -0.08781116  0.2481337  88.075803 -0.3538864
## TreatmentFull:RegionLuxembourg  -0.18552603  0.2983027 230.389072 -0.6219387
## TreatmentSmart:RegionLuxembourg  0.30029402  0.2907840 230.282277  1.0327048
##                                     Pr(>|t|)
## (Intercept)                     4.419164e-03
## TreatmentFull                   4.073785e-02
## TreatmentSmart                  6.316201e-01
## SexMale                         1.720899e-05
## SpeciesOP                       3.829421e-04
## RegionLuxembourg                7.242698e-01
## TreatmentFull:RegionLuxembourg  5.345971e-01
## TreatmentSmart:RegionLuxembourg 3.028254e-01

Selon les summary le choix de treatment ou treatment_bis est discutable mais on peut alors se pencher sur l’AIC qui nous encourage à prendre treatment_bis.

Analysons les P-val

summary(LM_Time_in_pupa)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Time_in_pupa ~ Treatment_bis + Sex + Species + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data
## 
## REML criterion at convergence: 729.3
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -3.0873 -0.6314 -0.0501  0.5971  3.7822 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.1324   0.3639  
##  Site     (Intercept) 0.0000   0.0000  
##  Room     (Intercept) 0.1471   0.3836  
##  Residual             0.8214   0.9063  
## Number of obs: 263, groups:  Mother, 35; Site, 15; Room, 2
## 
## Fixed effects:
##                                           Estimate Std. Error        df t value
## (Intercept)                               13.45331    0.32493   1.81789  41.404
## Treatment_bisFull                          0.45733    0.18507 229.31366   2.471
## Treatment_bisSmart                         0.09052    0.25518 228.98956   0.355
## Treatment_bisMixt_smart                    0.42938    0.28131 243.93412   1.526
## SexMale                                    0.49162    0.11683 240.98707   4.208
## SpeciesOP                                 -0.55826    0.18320  25.49863  -3.047
## RegionLuxembourg                          -0.06502    0.22440  61.15565  -0.290
## Treatment_bisFull:RegionLuxembourg        -0.28438    0.26752 228.19616  -1.063
## Treatment_bisSmart:RegionLuxembourg       -0.17392    0.33392 231.77982  -0.521
## Treatment_bisMixt_smart:RegionLuxembourg   1.28735    0.41865 251.08711   3.075
##                                          Pr(>|t|)    
## (Intercept)                               0.00103 ** 
## Treatment_bisFull                         0.01420 *  
## Treatment_bisSmart                        0.72311    
## Treatment_bisMixt_smart                   0.12822    
## SexMale                                  3.64e-05 ***
## SpeciesOP                                 0.00532 ** 
## RegionLuxembourg                          0.77300    
## Treatment_bisFull:RegionLuxembourg        0.28889    
## Treatment_bisSmart:RegionLuxembourg       0.60298    
## Treatment_bisMixt_smart:RegionLuxembourg  0.00234 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal SpcsOP RgnLxm T_F:RL T_S:RL
## Trtmnt_bsFl -0.244                                                        
## Trtmnt_bsSm -0.203  0.326                                                 
## Trtmnt_bsM_ -0.214  0.305  0.174                                          
## SexMale     -0.142 -0.100  0.029 -0.043                                   
## SpeciesOP   -0.244  0.037  0.044  0.183 -0.003                            
## ReginLxmbrg -0.319  0.360  0.268  0.254  0.000 -0.013                     
## Trtmnt_F:RL  0.179 -0.687 -0.212 -0.226  0.032 -0.051 -0.533              
## Trtmnt_S:RL  0.146 -0.237 -0.703 -0.174 -0.033 -0.012 -0.450  0.361       
## Trtmn_M_:RL  0.120 -0.203 -0.158 -0.610 -0.012  0.014 -0.396  0.299  0.259
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(Time_in_pupa ~ Treatment_bis + Sex + Species + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region , data = Data_ref_full))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Time_in_pupa ~ Treatment_bis + Sex + Species + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_ref_full
## 
## REML criterion at convergence: 729.3
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -3.0873 -0.6314 -0.0501  0.5971  3.7822 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.1324   0.3639  
##  Site     (Intercept) 0.0000   0.0000  
##  Room     (Intercept) 0.1471   0.3836  
##  Residual             0.8214   0.9063  
## Number of obs: 263, groups:  Mother, 35; Site, 15; Room, 2
## 
## Fixed effects:
##                                           Estimate Std. Error        df t value
## (Intercept)                               13.91064    0.33232   1.98902  41.859
## Treatment_bisDark                         -0.45733    0.18507 229.31366  -2.471
## Treatment_bisSmart                        -0.36680    0.26193 230.47280  -1.400
## Treatment_bisMixt_smart                   -0.02795    0.28564 234.75630  -0.098
## SexMale                                    0.49162    0.11683 240.98707   4.208
## SpeciesOP                                 -0.55826    0.18320  25.49863  -3.047
## RegionLuxembourg                          -0.34940    0.24080  77.02702  -1.451
## Treatment_bisDark:RegionLuxembourg         0.28438    0.26752 228.19616   1.063
## Treatment_bisSmart:RegionLuxembourg        0.11046    0.34428 231.63277   0.321
## Treatment_bisMixt_smart:RegionLuxembourg   1.57173    0.42411 248.36645   3.706
##                                          Pr(>|t|)    
## (Intercept)                               0.00059 ***
## Treatment_bisDark                         0.01420 *  
## Treatment_bisSmart                        0.16275    
## Treatment_bisMixt_smart                   0.92214    
## SexMale                                  3.64e-05 ***
## SpeciesOP                                 0.00532 ** 
## RegionLuxembourg                          0.15085    
## Treatment_bisDark:RegionLuxembourg        0.28889    
## Treatment_bisSmart:RegionLuxembourg       0.74861    
## Treatment_bisMixt_smart:RegionLuxembourg  0.00026 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S Trt_M_ SexMal SpcsOP RgnLxm T_D:RL T_S:RL
## Trtmnt_bsDr -0.318                                                        
## Trtmnt_bsSm -0.241  0.389                                                 
## Trtmnt_bsM_ -0.244  0.347  0.206                                          
## SexMale     -0.195  0.100  0.099  0.023                                   
## SpeciesOP   -0.218 -0.037  0.017  0.156 -0.003                            
## ReginLxmbrg -0.334  0.427  0.315  0.262  0.035 -0.069                     
## Trtmnt_D:RL  0.207 -0.687 -0.278 -0.222 -0.032  0.051 -0.615              
## Trtmnt_S:RL  0.171 -0.303 -0.718 -0.190 -0.057  0.028 -0.495  0.427       
## Trtmn_M_:RL  0.135 -0.232 -0.185 -0.603 -0.032  0.046 -0.424  0.336  0.287
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(Time_in_pupa ~ Treatment_bis + Sex + Species + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region , data = Data_ref_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Time_in_pupa ~ Treatment_bis + Sex + Species + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_ref_smart
## 
## REML criterion at convergence: 729.3
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -3.0873 -0.6314 -0.0501  0.5971  3.7822 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.1324   0.3639  
##  Site     (Intercept) 0.0000   0.0000  
##  Room     (Intercept) 0.1471   0.3836  
##  Residual             0.8214   0.9063  
## Number of obs: 263, groups:  Mother, 35; Site, 15; Room, 2
## 
## Fixed effects:
##                                           Estimate Std. Error        df t value
## (Intercept)                               13.54384    0.37027   3.03794  36.578
## Treatment_bisDark                         -0.09052    0.25518 228.98956  -0.355
## Treatment_bisFull                          0.36680    0.26193 230.47280   1.400
## Treatment_bisMixt_smart                    0.33885    0.34540 232.77518   0.981
## SexMale                                    0.49162    0.11683 240.98707   4.208
## SpeciesOP                                 -0.55826    0.18320  25.49863  -3.047
## RegionLuxembourg                          -0.23893    0.30735 166.21382  -0.777
## Treatment_bisDark:RegionLuxembourg         0.17392    0.33392 231.77982   0.521
## Treatment_bisFull:RegionLuxembourg        -0.11046    0.34428 231.63277  -0.321
## Treatment_bisMixt_smart:RegionLuxembourg   1.46127    0.46310 242.04038   3.155
##                                          Pr(>|t|)    
## (Intercept)                              4.06e-05 ***
## Treatment_bisDark                         0.72311    
## Treatment_bisFull                         0.16275    
## Treatment_bisMixt_smart                   0.32759    
## SexMale                                  3.64e-05 ***
## SpeciesOP                                 0.00532 ** 
## RegionLuxembourg                          0.43803    
## Treatment_bisDark:RegionLuxembourg        0.60298    
## Treatment_bisFull:RegionLuxembourg        0.74861    
## Treatment_bisMixt_smart:RegionLuxembourg  0.00181 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trt_M_ SexMal SpcsOP RgnLxm T_D:RL T_F:RL
## Trtmnt_bsDr -0.511                                                        
## Trtmnt_bsFl -0.491  0.744                                                 
## Trtmnt_bsM_ -0.433  0.597  0.588                                          
## SexMale     -0.105 -0.029 -0.099 -0.056                                   
## SpeciesOP   -0.184 -0.044 -0.017  0.116 -0.003                            
## ReginLxmbrg -0.457  0.568  0.557  0.416 -0.036 -0.022                     
## Trtmnt_D:RL  0.357 -0.703 -0.517 -0.377  0.033  0.012 -0.758              
## Trtmnt_F:RL  0.354 -0.517 -0.718 -0.387  0.057 -0.028 -0.732  0.689       
## Trtmn_M_:RL  0.254 -0.364 -0.364 -0.616  0.013  0.021 -0.554  0.487  0.480
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
Info_time_in_pupa <- "
Le traitement Full met significativement plus de temps que le traitement Dark.
Le traitement Smart met significativement moins de temps que le traitement Full.
Le traitement Smart a une p-val de 0.999 quand on le compare à dark. Ces 2 traitements sont donc très simillaires.
Les males sont significatiment plus lent
L'espèce OP est significativement plus rapide
Les chenilles restent plus longtemps en chrysalide dans le traitement Mixt_smart quand elles viennent du luxembourg que quand elles viennent du brabant.
"
Info_time_in_pupa
## [1] "\nLe traitement Full met significativement plus de temps que le traitement Dark.\nLe traitement Smart met significativement moins de temps que le traitement Full.\nLe traitement Smart a une p-val de 0.999 quand on le compare à dark. Ces 2 traitements sont donc très simillaires.\nLes males sont significatiment plus lent\nL'espèce OP est significativement plus rapide\nLes chenilles restent plus longtemps en chrysalide dans le traitement Mixt_smart quand elles viennent du luxembourg que quand elles viennent du brabant.\n"

4.4.4 Visualisation

Summary_Time_in_pupa <- Data %>% 
  filter(Did_pupated == "Yes", Did_emerged == "Yes", Sex != "NA") %>% 
  group_by(Treatment_bis, Species, Region) %>% 
  summarise(Mean=mean(Time_in_pupa),
            Var=var(Time_in_pupa),
            N=n()) %>% 
  mutate(CI_S=Mean+qt(0.975, N-1)*sqrt(Var/N),
         CI_I=Mean-qt(0.975, N-1)*sqrt(Var/N))
ggplot(Summary_Time_in_pupa, aes(x=Treatment_bis, y=Mean, color = Species))+
  geom_errorbar(aes(ymin=CI_I, ymax=CI_S),width=0.2,size = 1.2, alpha = 0.5) +
  geom_point(alpha = 0.8) +
  facet_wrap(~Region) +
  labs(title = "Temps en chrysalide", x = "Traitement", y = "Nombre de jours", color = "Espèce") +
  theme_bw()

Tout se voit super bien sur ce graph sauf le Sex.

Summary_Time_in_pupa2 <- Data %>% 
  filter(Did_pupated == "Yes", Did_emerged == "Yes", Sex != "NA") %>% 
  group_by(Treatment_bis, Species, Sex) %>% 
  summarise(Mean=mean(Time_in_pupa),
            Var=var(Time_in_pupa),
            N=n()) %>% 
  mutate(CI_S=Mean+qt(0.975, N-1)*sqrt(Var/N),
         CI_I=Mean-qt(0.975, N-1)*sqrt(Var/N))
ggplot(Summary_Time_in_pupa2, aes(x=Treatment_bis, y=Mean, color = Sex))+
  scale_color_manual(name = "Sex", values = c("Female" = "red", "Male" = "royalblue")) +
  geom_errorbar(aes(ymin=CI_I, ymax=CI_S),width=0.2,size = 1.2, alpha = 0.5) +
  geom_point(alpha = 0.8) +
  facet_wrap(~Species) +
  labs(title = "Temps en chrysalide", x = "Traitement", y = "Nombre de jours", color = "Espèce") +
  theme_bw()

4.5 TT_emerge

4.5.1 Test

LM_TT_emerge <- lmer(TT_emerge ~ Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region, data = Data)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
summary(LM_TT_pupation)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(TT_pupation) ~ Treatment_bis + Sex + Species + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Sex:Species + Region:Species +  
##     Treatment_bis:Species + Treatment_bis:Sex
##    Data: Data
## 
## REML criterion at convergence: -42.6
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.1358 -0.5872 -0.1119  0.5122  4.1975 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.009186 0.09584 
##  Site     (Intercept) 0.007935 0.08908 
##  Room     (Intercept) 0.000000 0.00000 
##  Residual             0.037209 0.19290 
## Number of obs: 304, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                   Estimate Std. Error         df t value
## (Intercept)                       3.703375   0.059318  17.639677  62.433
## Treatment_bisFull                 0.003632   0.045196 270.551334   0.080
## Treatment_bisSmart               -0.149036   0.051781 267.531050  -2.878
## Treatment_bisMixt_smart           0.094418   0.060451 273.190577   1.562
## SexMale                           0.032073   0.046472 274.662322   0.690
## SpeciesOP                        -0.978520   0.075109  36.810031 -13.028
## RegionLuxembourg                  0.167889   0.072314  11.490685   2.322
## SexMale:SpeciesOP                -0.080675   0.049172 270.185399  -1.641
## SpeciesOP:RegionLuxembourg       -0.177645   0.093183  22.435976  -1.906
## Treatment_bisFull:SpeciesOP      -0.020124   0.053223 266.394454  -0.378
## Treatment_bisSmart:SpeciesOP      0.186982   0.069245 266.224474   2.700
## Treatment_bisFull:SexMale         0.008564   0.053709 269.268432   0.159
## Treatment_bisSmart:SexMale       -0.019486   0.070773 277.233351  -0.275
## Treatment_bisMixt_smart:SexMale  -0.122305   0.088787 274.741600  -1.378
##                                 Pr(>|t|)    
## (Intercept)                      < 2e-16 ***
## Treatment_bisFull                0.93601    
## Treatment_bisSmart               0.00432 ** 
## Treatment_bisMixt_smart          0.11947    
## SexMale                          0.49068    
## SpeciesOP                       2.35e-15 ***
## RegionLuxembourg                 0.03953 *  
## SexMale:SpeciesOP                0.10203    
## SpeciesOP:RegionLuxembourg       0.06949 .  
## Treatment_bisFull:SpeciesOP      0.70566    
## Treatment_bisSmart:SpeciesOP     0.00737 ** 
## Treatment_bisFull:SexMale        0.87344    
## Treatment_bisSmart:SexMale       0.78327    
## Treatment_bisMixt_smart:SexMale  0.16947    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 14 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Vérification de la normalité

qqnorm(resid(LM_TT_emerge))
qqline(resid(LM_TT_emerge))

il faudrait mettre d’autres facteur

LM_TT_emerge <- lmer(log(TT_emerge) ~ Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region, data = Data)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
summary(LM_TT_pupation)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(TT_pupation) ~ Treatment_bis + Sex + Species + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Sex:Species + Region:Species +  
##     Treatment_bis:Species + Treatment_bis:Sex
##    Data: Data
## 
## REML criterion at convergence: -42.6
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.1358 -0.5872 -0.1119  0.5122  4.1975 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.009186 0.09584 
##  Site     (Intercept) 0.007935 0.08908 
##  Room     (Intercept) 0.000000 0.00000 
##  Residual             0.037209 0.19290 
## Number of obs: 304, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                   Estimate Std. Error         df t value
## (Intercept)                       3.703375   0.059318  17.639677  62.433
## Treatment_bisFull                 0.003632   0.045196 270.551334   0.080
## Treatment_bisSmart               -0.149036   0.051781 267.531050  -2.878
## Treatment_bisMixt_smart           0.094418   0.060451 273.190577   1.562
## SexMale                           0.032073   0.046472 274.662322   0.690
## SpeciesOP                        -0.978520   0.075109  36.810031 -13.028
## RegionLuxembourg                  0.167889   0.072314  11.490685   2.322
## SexMale:SpeciesOP                -0.080675   0.049172 270.185399  -1.641
## SpeciesOP:RegionLuxembourg       -0.177645   0.093183  22.435976  -1.906
## Treatment_bisFull:SpeciesOP      -0.020124   0.053223 266.394454  -0.378
## Treatment_bisSmart:SpeciesOP      0.186982   0.069245 266.224474   2.700
## Treatment_bisFull:SexMale         0.008564   0.053709 269.268432   0.159
## Treatment_bisSmart:SexMale       -0.019486   0.070773 277.233351  -0.275
## Treatment_bisMixt_smart:SexMale  -0.122305   0.088787 274.741600  -1.378
##                                 Pr(>|t|)    
## (Intercept)                      < 2e-16 ***
## Treatment_bisFull                0.93601    
## Treatment_bisSmart               0.00432 ** 
## Treatment_bisMixt_smart          0.11947    
## SexMale                          0.49068    
## SpeciesOP                       2.35e-15 ***
## RegionLuxembourg                 0.03953 *  
## SexMale:SpeciesOP                0.10203    
## SpeciesOP:RegionLuxembourg       0.06949 .  
## Treatment_bisFull:SpeciesOP      0.70566    
## Treatment_bisSmart:SpeciesOP     0.00737 ** 
## Treatment_bisFull:SexMale        0.87344    
## Treatment_bisSmart:SexMale       0.78327    
## Treatment_bisMixt_smart:SexMale  0.16947    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 14 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
qqnorm(resid(LM_TT_emerge))
qqline(resid(LM_TT_emerge))

La normalité est bien meilleure

Homogénité des variances

plot(LM_TT_emerge)

Distance de cook

plot(cooks.distance(LM_TT_emerge))

4.5.2 Simplification du modèle

drop1(LM_TT_emerge)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(TT_emerge) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region
##                         Sum Sq  Mean Sq NumDF   DenDF F value   Pr(>F)   
## Sex:Species           0.050181 0.050181     1 226.851  3.7656 0.053555 . 
## Species:Region        0.062438 0.062438     1  24.509  4.6854 0.040371 * 
## Treatment_bis:Species 0.077601 0.038801     2 222.783  2.9116 0.056460 . 
## Treatment_bis:Sex     0.029588 0.009863     3 231.007  0.7401 0.529101   
## Treatment_bis:Region  0.161811 0.053937     3 224.073  4.0475 0.007911 **
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_TT_emerge1 <- update(LM_TT_emerge, . ~ . - Treatment_bis:Sex)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
drop1(LM_TT_emerge1)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(TT_emerge) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Species:Region + Treatment_bis:Species + Treatment_bis:Region
##                         Sum Sq  Mean Sq NumDF   DenDF F value   Pr(>F)   
## Sex:Species           0.032558 0.032558     1 231.652  2.4589 0.118228   
## Species:Region        0.063200 0.063200     1  25.091  4.7731 0.038459 * 
## Treatment_bis:Species 0.082017 0.041009     2 225.158  3.0971 0.047110 * 
## Treatment_bis:Region  0.157084 0.052361     3 226.910  3.9545 0.008932 **
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_TT_emerge2 <- update(LM_TT_emerge1, . ~ . - Sex:Species)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
drop1(LM_TT_emerge2)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(TT_emerge) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region + Treatment_bis:Species + Treatment_bis:Region
##                         Sum Sq  Mean Sq NumDF   DenDF F value   Pr(>F)   
## Sex                   0.028634 0.028634     1 232.688  2.1554 0.143420   
## Species:Region        0.059023 0.059023     1  25.068  4.4429 0.045215 * 
## Treatment_bis:Species 0.086589 0.043295     2 225.388  3.2589 0.040248 * 
## Treatment_bis:Region  0.161320 0.053773     3 227.310  4.0477 0.007894 **
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_TT_emerge3 <- update(LM_TT_emerge2, . ~ . - Sex)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
drop1(LM_TT_emerge3)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(TT_emerge) ~ Treatment_bis + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region + Treatment_bis:Species + Treatment_bis:Region
##                         Sum Sq  Mean Sq NumDF   DenDF F value   Pr(>F)   
## Species:Region        0.077673 0.077673     1  23.623  5.5680 0.026907 * 
## Treatment_bis:Species 0.118286 0.059143     2 230.317  4.2397 0.015552 * 
## Treatment_bis:Region  0.179960 0.059987     3 232.584  4.3002 0.005633 **
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Regardons si les simplifications étaient utiles

AIC(LM_TT_emerge)
## [1] -230.623
AIC(LM_TT_emerge3)
## [1] -255.422

Les simplifications étaient utiles

LM_TT_emerge <- LM_TT_emerge3

4.5.3 Treatment VS Treatment_bis

AIC(lmer(log(TT_emerge) ~ Treatment_bis + Species + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Species:Region + Treatment_bis:Species + Treatment_bis:Region, data = Data))
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## [1] -255.422
AIC(lmer(log(TT_emerge) ~ Treatment + Species + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Species:Region + Treatment:Species + Treatment:Region, data = Data))
## [1] -240.5444
summary(lmer(log(TT_emerge) ~ Treatment_bis + Species + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Species:Region + Treatment_bis:Species + Treatment_bis:Region, data = Data))$coeff
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
##                                             Estimate Std. Error        df
## (Intercept)                               3.95511287 0.03922836  10.86725
## Treatment_bisFull                         0.03071693 0.02982998 230.27031
## Treatment_bisSmart                       -0.02498566 0.03655393 226.81083
## Treatment_bisMixt_smart                   0.01850374 0.03861631 230.55791
## SpeciesOP                                -0.61094803 0.04728140  32.08622
## RegionLuxembourg                          0.12977121 0.04817467  20.66081
## SpeciesOP:RegionLuxembourg               -0.14641003 0.06204679  23.62279
## Treatment_bisFull:SpeciesOP              -0.03994628 0.03529009 231.70760
## Treatment_bisSmart:SpeciesOP              0.09209626 0.04426232 229.36551
## Treatment_bisFull:RegionLuxembourg        0.01203657 0.03482695 229.18573
## Treatment_bisSmart:RegionLuxembourg      -0.08467750 0.04340001 229.05798
## Treatment_bisMixt_smart:RegionLuxembourg  0.13212333 0.05662560 239.33271
##                                              t value     Pr(>|t|)
## (Intercept)                              100.8227848 1.691591e-17
## Treatment_bisFull                          1.0297336 3.042155e-01
## Treatment_bisSmart                        -0.6835286 4.949706e-01
## Treatment_bisMixt_smart                    0.4791690 6.322726e-01
## SpeciesOP                                -12.9215309 2.914775e-14
## RegionLuxembourg                           2.6937641 1.371780e-02
## SpeciesOP:RegionLuxembourg                -2.3596714 2.690678e-02
## Treatment_bisFull:SpeciesOP               -1.1319405 2.588295e-01
## Treatment_bisSmart:SpeciesOP               2.0806924 3.857230e-02
## Treatment_bisFull:RegionLuxembourg         0.3456108 7.299523e-01
## Treatment_bisSmart:RegionLuxembourg       -1.9510939 5.226518e-02
## Treatment_bisMixt_smart:RegionLuxembourg   2.3332792 2.046272e-02
summary(lmer(log(TT_emerge) ~ Treatment + Species + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Species:Region + Treatment:Species + Treatment:Region, data = Data))$coeff
##                                      Estimate Std. Error         df
## (Intercept)                      3.9562735447 0.04720156   4.787439
## TreatmentFull                    0.0271855793 0.03176171 231.679029
## TreatmentSmart                   0.0001964454 0.03048215 233.363063
## SpeciesOP                       -0.6110264019 0.05073851  37.109398
## RegionLuxembourg                 0.1362527299 0.04939532  21.758770
## SpeciesOP:RegionLuxembourg      -0.1610352195 0.06359414  22.744920
## TreatmentFull:SpeciesOP         -0.0362881789 0.03897183 231.487350
## TreatmentSmart:SpeciesOP         0.0113951343 0.03793371 231.155322
## TreatmentFull:RegionLuxembourg   0.0138360443 0.03901176 231.765691
## TreatmentSmart:RegionLuxembourg -0.0122431400 0.03781352 232.754484
##                                       t value     Pr(>|t|)
## (Intercept)                      83.816592483 9.097349e-09
## TreatmentFull                     0.855923007 3.929247e-01
## TreatmentSmart                    0.006444605 9.948635e-01
## SpeciesOP                       -12.042655457 2.194485e-14
## RegionLuxembourg                  2.758413625 1.153818e-02
## SpeciesOP:RegionLuxembourg       -2.532233499 1.870751e-02
## TreatmentFull:SpeciesOP          -0.931138719 3.527519e-01
## TreatmentSmart:SpeciesOP          0.300396017 7.641451e-01
## TreatmentFull:RegionLuxembourg    0.354663397 7.231643e-01
## TreatmentSmart:RegionLuxembourg  -0.323776769 7.463978e-01

Treatment_bis est meilleur, il explique mieux les résultats obtenus

Analysons les P-val

summary(LM_TT_emerge)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(TT_emerge) ~ Treatment_bis + Species + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Species:Region + Treatment_bis:Species +  
##     Treatment_bis:Region
##    Data: Data
## 
## REML criterion at convergence: -287.4
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.4315 -0.6567 -0.0274  0.4973  3.5040 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0043738 0.06613 
##  Site     (Intercept) 0.0017208 0.04148 
##  Room     (Intercept) 0.0005773 0.02403 
##  Residual             0.0139498 0.11811 
## Number of obs: 268, groups:  Mother, 35; Site, 15; Room, 2
## 
## Fixed effects:
##                                           Estimate Std. Error        df t value
## (Intercept)                                3.95511    0.03923  10.86725 100.823
## Treatment_bisFull                          0.03072    0.02983 230.27031   1.030
## Treatment_bisSmart                        -0.02499    0.03655 226.81083  -0.684
## Treatment_bisMixt_smart                    0.01850    0.03862 230.55791   0.479
## SpeciesOP                                 -0.61095    0.04728  32.08622 -12.922
## RegionLuxembourg                           0.12977    0.04817  20.66081   2.694
## SpeciesOP:RegionLuxembourg                -0.14641    0.06205  23.62279  -2.360
## Treatment_bisFull:SpeciesOP               -0.03995    0.03529 231.70760  -1.132
## Treatment_bisSmart:SpeciesOP               0.09210    0.04426 229.36551   2.081
## Treatment_bisFull:RegionLuxembourg         0.01204    0.03483 229.18573   0.346
## Treatment_bisSmart:RegionLuxembourg       -0.08468    0.04340 229.05798  -1.951
## Treatment_bisMixt_smart:RegionLuxembourg   0.13212    0.05663 239.33271   2.333
##                                          Pr(>|t|)    
## (Intercept)                               < 2e-16 ***
## Treatment_bisFull                          0.3042    
## Treatment_bisSmart                         0.4950    
## Treatment_bisMixt_smart                    0.6323    
## SpeciesOP                                2.91e-14 ***
## RegionLuxembourg                           0.0137 *  
## SpeciesOP:RegionLuxembourg                 0.0269 *  
## Treatment_bisFull:SpeciesOP                0.2588    
## Treatment_bisSmart:SpeciesOP               0.0386 *  
## Treatment_bisFull:RegionLuxembourg         0.7300    
## Treatment_bisSmart:RegionLuxembourg        0.0523 .  
## Treatment_bisMixt_smart:RegionLuxembourg   0.0205 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SpcsOP RgnLxm SOP:RL T_F:SO T_S:SO
## Trtmnt_bsFl -0.374                                                        
## Trtmnt_bsSm -0.284  0.371                                                 
## Trtmnt_bsM_ -0.338  0.396  0.259                                          
## SpeciesOP   -0.522  0.234  0.166  0.256                                   
## ReginLxmbrg -0.608  0.188  0.149  0.210  0.344                            
## SpcsOP:RgnL  0.326 -0.022 -0.021 -0.103 -0.654 -0.516                     
## Trtmn_F:SOP  0.229 -0.604 -0.212 -0.260 -0.333  0.007 -0.004              
## Trtmn_S:SOP  0.161 -0.231 -0.453 -0.187 -0.247  0.047 -0.049  0.367       
## Trtmnt_F:RL  0.178 -0.477 -0.178 -0.190  0.004 -0.325  0.002 -0.110 -0.013
## Trtmnt_S:RL  0.158 -0.182 -0.593 -0.165 -0.025 -0.318  0.073 -0.022 -0.066
## Trtmn_M_:RL  0.179 -0.155 -0.131 -0.590 -0.090 -0.338  0.182 -0.019 -0.038
##             T_F:RL T_S:RL
## Trtmnt_bsFl              
## Trtmnt_bsSm              
## Trtmnt_bsM_              
## SpeciesOP                
## ReginLxmbrg              
## SpcsOP:RgnL              
## Trtmn_F:SOP              
## Trtmn_S:SOP              
## Trtmnt_F:RL              
## Trtmnt_S:RL  0.361       
## Trtmn_M_:RL  0.293  0.272
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
summary(lmer(log(TT_emerge) ~ Treatment_bis + Species + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Species:Region + Treatment_bis:Species + Treatment_bis:Region, data = Data_ref_full))
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(TT_emerge) ~ Treatment_bis + Species + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Species:Region + Treatment_bis:Species +  
##     Treatment_bis:Region
##    Data: Data_ref_full
## 
## REML criterion at convergence: -287.4
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.4315 -0.6567 -0.0274  0.4973  3.5040 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0043738 0.06613 
##  Site     (Intercept) 0.0017208 0.04148 
##  Room     (Intercept) 0.0005773 0.02403 
##  Residual             0.0139498 0.11811 
## Number of obs: 268, groups:  Mother, 35; Site, 15; Room, 2
## 
## Fixed effects:
##                                           Estimate Std. Error        df t value
## (Intercept)                                3.98583    0.03941  11.39642 101.141
## Treatment_bisDark                         -0.03072    0.02983 230.27031  -1.030
## Treatment_bisSmart                        -0.05570    0.03764 227.26576  -1.480
## Treatment_bisMixt_smart                   -0.01221    0.03833 227.31328  -0.319
## SpeciesOP                                 -0.65089    0.04869  36.17365 -13.369
## RegionLuxembourg                           0.14181    0.04942  23.88074   2.869
## SpeciesOP:RegionLuxembourg                -0.14641    0.06205  23.62279  -2.360
## Treatment_bisDark:SpeciesOP                0.03995    0.03529 231.70760   1.132
## Treatment_bisSmart:SpeciesOP               0.13204    0.04537 229.72874   2.910
## Treatment_bisDark:RegionLuxembourg        -0.01204    0.03483 229.18573  -0.346
## Treatment_bisSmart:RegionLuxembourg       -0.09671    0.04479 230.27755  -2.159
## Treatment_bisMixt_smart:RegionLuxembourg   0.12009    0.05715 235.94233   2.101
##                                          Pr(>|t|)    
## (Intercept)                               < 2e-16 ***
## Treatment_bisDark                         0.30422    
## Treatment_bisSmart                        0.14030    
## Treatment_bisMixt_smart                   0.75032    
## SpeciesOP                                1.45e-15 ***
## RegionLuxembourg                          0.00847 ** 
## SpeciesOP:RegionLuxembourg                0.02691 *  
## Treatment_bisDark:SpeciesOP               0.25883    
## Treatment_bisSmart:SpeciesOP              0.00397 ** 
## Treatment_bisDark:RegionLuxembourg        0.72995    
## Treatment_bisSmart:RegionLuxembourg       0.03186 *  
## Treatment_bisMixt_smart:RegionLuxembourg  0.03667 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S Trt_M_ SpcsOP RgnLxm SOP:RL T_D:SO T_S:SO
## Trtmnt_bsDr -0.384                                                        
## Trtmnt_bsSm -0.306  0.432                                                 
## Trtmnt_bsM_ -0.337  0.380  0.274                                          
## SpeciesOP   -0.499  0.211  0.174  0.225                                   
## ReginLxmbrg -0.581  0.153  0.140  0.190  0.277                            
## SpcsOP:RgnL  0.308  0.022 -0.003 -0.086 -0.638 -0.502                     
## Trtmn_D:SOP  0.229 -0.604 -0.272 -0.208 -0.402  0.071  0.004              
## Trtmn_S:SOP  0.164 -0.244 -0.462 -0.170 -0.287  0.090 -0.045  0.420       
## Trtmnt_D:RL  0.183 -0.477 -0.205 -0.179  0.076 -0.388 -0.002 -0.110 -0.072
## Trtmnt_S:RL  0.162 -0.195 -0.577 -0.163  0.020 -0.355  0.070 -0.064 -0.103
## Trtmn_M_:RL  0.172 -0.137 -0.129 -0.578 -0.055 -0.359  0.179 -0.048 -0.066
##             T_D:RL T_S:RL
## Trtmnt_bsDr              
## Trtmnt_bsSm              
## Trtmnt_bsM_              
## SpeciesOP                
## ReginLxmbrg              
## SpcsOP:RgnL              
## Trtmn_D:SOP              
## Trtmn_S:SOP              
## Trtmnt_D:RL              
## Trtmnt_S:RL  0.428       
## Trtmn_M_:RL  0.320  0.296
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
summary(lmer(log(TT_emerge) ~ Treatment_bis + Species + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Species:Region + Treatment_bis:Species + Treatment_bis:Region, data = Data_ref_smart))
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(TT_emerge) ~ Treatment_bis + Species + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Species:Region + Treatment_bis:Species +  
##     Treatment_bis:Region
##    Data: Data_ref_smart
## 
## REML criterion at convergence: -287.4
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.4315 -0.6567 -0.0274  0.4973  3.5040 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0043738 0.06613 
##  Site     (Intercept) 0.0017208 0.04148 
##  Room     (Intercept) 0.0005773 0.02403 
##  Residual             0.0139498 0.11811 
## Number of obs: 268, groups:  Mother, 35; Site, 15; Room, 2
## 
## Fixed effects:
##                                           Estimate Std. Error        df t value
## (Intercept)                                3.93013    0.04541  18.07036  86.551
## Treatment_bisDark                          0.02499    0.03655 226.81083   0.684
## Treatment_bisFull                          0.05570    0.03764 227.26576   1.480
## Treatment_bisMixt_smart                    0.04349    0.04577 195.09444   0.950
## SpeciesOP                                 -0.51885    0.05621  60.35141  -9.231
## RegionLuxembourg                           0.04509    0.05363  30.96334   0.841
## SpeciesOP:RegionLuxembourg                -0.14641    0.06205  23.62279  -2.360
## Treatment_bisDark:SpeciesOP               -0.09210    0.04426 229.36551  -2.081
## Treatment_bisFull:SpeciesOP               -0.13204    0.04537 229.72874  -2.910
## Treatment_bisDark:RegionLuxembourg         0.08468    0.04340 229.05797   1.951
## Treatment_bisFull:RegionLuxembourg         0.09671    0.04479 230.27755   2.159
## Treatment_bisMixt_smart:RegionLuxembourg   0.21680    0.06128 236.48764   3.538
##                                          Pr(>|t|)    
## (Intercept)                               < 2e-16 ***
## Treatment_bisDark                        0.494971    
## Treatment_bisFull                        0.140302    
## Treatment_bisMixt_smart                  0.343238    
## SpeciesOP                                3.83e-13 ***
## RegionLuxembourg                         0.406932    
## SpeciesOP:RegionLuxembourg               0.026907 *  
## Treatment_bisDark:SpeciesOP              0.038572 *  
## Treatment_bisFull:SpeciesOP              0.003966 ** 
## Treatment_bisDark:RegionLuxembourg       0.052265 .  
## Treatment_bisFull:RegionLuxembourg       0.031856 *  
## Treatment_bisMixt_smart:RegionLuxembourg 0.000485 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trt_M_ SpcsOP RgnLxm SOP:RL T_D:SO T_F:SO
## Trtmnt_bsDr -0.560                                                        
## Trtmnt_bsFl -0.563  0.677                                                 
## Trtmnt_bsM_ -0.518  0.580  0.593                                          
## SpeciesOP   -0.445  0.218  0.223  0.231                                   
## ReginLxmbrg -0.640  0.346  0.353  0.323  0.234                            
## SpcsOP:RgnL  0.265  0.021  0.003 -0.070 -0.589 -0.405                     
## Trtmn_D:SOP  0.226 -0.453 -0.257 -0.204 -0.579  0.012  0.049              
## Trtmn_F:SOP  0.241 -0.277 -0.462 -0.238 -0.558  0.003  0.045  0.690       
## Trtmnt_D:RL  0.341 -0.593 -0.431 -0.334  0.073 -0.524 -0.073 -0.066 -0.048
## Trtmnt_F:RL  0.338 -0.436 -0.577 -0.338  0.065 -0.508 -0.070 -0.054 -0.103
## Trtmn_M_:RL  0.286 -0.299 -0.301 -0.600 -0.046 -0.449  0.116 -0.012 -0.013
##             T_D:RL T_F:RL
## Trtmnt_bsDr              
## Trtmnt_bsFl              
## Trtmnt_bsM_              
## SpeciesOP                
## ReginLxmbrg              
## SpcsOP:RgnL              
## Trtmn_D:SOP              
## Trtmn_F:SOP              
## Trtmnt_D:RL              
## Trtmnt_F:RL  0.689       
## Trtmn_M_:RL  0.457  0.455
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
Infos_TT_emerge <- "
L'impacte du traitement Smart chez OP est quasiment significativemt (p = 0.051) différent (plus lent que Dark) que l'impacte du traitement smart chez AE.
L'impacte du traitement Smart chez OP est significativemt différent (plus lent que Full) que l'impacte du traitement smart chez AE.
Chez AE, Le traitement smart est également significativement plus rapide que le traitement full.
L'impacte du traitement Mixt_Smart est différent (plus lent) en fonction de la région
L'espèce OP met significativement moins de temps.
La région luxembourg met significativement plus de temps pour l'espèce AE mais met significativement moins de temps pour l'espèce OP.
"
Infos_TT_emerge
## [1] "\nL'impacte du traitement Smart chez OP est quasiment significativemt (p = 0.051) différent (plus lent que Dark) que l'impacte du traitement smart chez AE.\nL'impacte du traitement Smart chez OP est significativemt différent (plus lent que Full) que l'impacte du traitement smart chez AE.\nChez AE, Le traitement smart est également significativement plus rapide que le traitement full.\nL'impacte du traitement Mixt_Smart est différent (plus lent) en fonction de la région\nL'espèce OP met significativement moins de temps.\nLa région luxembourg met significativement plus de temps pour l'espèce AE mais met significativement moins de temps pour l'espèce OP.\n"

4.5.4 Visualisation

Summary_TT_emerge <- Data %>% 
  filter(Did_emerged == "Yes") %>% 
  group_by(Treatment_bis, Species, Region) %>% 
  summarise(Mean=mean(log(TT_emerge)),
            Var=var(log(TT_emerge)),
            N=n()) %>% 
  mutate(CI_S=Mean+qt(0.975, N-1)*sqrt(Var/N),
         CI_I=Mean-qt(0.975, N-1)*sqrt(Var/N))
ggplot(Summary_TT_emerge, aes(x=Treatment_bis, y=Mean, color = Species))+
  geom_errorbar(aes(ymin=CI_I, ymax=CI_S),width=0.2,size = 1.2, alpha = 0.5) +
  geom_point(alpha = 0.8) +
  facet_grid(~Region) +
  labs(title = "Time to Emerge", x = "Treatment", y = "log(Days)") +
  theme_bw()

ggplot(Summary_TT_emerge, aes(x=Region, y=Mean, color = Species))+
  geom_errorbar(aes(ymin=CI_I, ymax=CI_S),width=0.2,size = 1.2, alpha = 0.5) +
  geom_point(alpha = 0.8) +
  facet_grid(~Treatment_bis) +
  labs(title = "Temps pour devenir adulte", x = "Région", y = "log(Nombre de jours)", color = "Espèce") +
  theme_bw()

Summary_TT_emerge2 <- Data %>% 
  filter(Did_emerged == "Yes") %>% 
  group_by(Treatment_bis, Species) %>% 
  summarise(Mean=mean(log(TT_emerge)),
            Var=var(log(TT_emerge)),
            N=n()) %>% 
  mutate(CI_S=Mean+qt(0.975, N-1)*sqrt(Var/N),
         CI_I=Mean-qt(0.975, N-1)*sqrt(Var/N))
ggplot(Summary_TT_emerge2, aes(x=Species, y=Mean, color = Species))+
  geom_errorbar(aes(ymin=CI_I, ymax=CI_S),width=0.2,size = 1.2, alpha = 0.5) +
  geom_point(alpha = 0.8) +
  facet_grid(~Treatment_bis) +
  labs(title = "Time to Emerge", x = "Treatment", y = "log(Days)") +
  theme_bw()

4.6 Pupa_mass

4.6.1 Test

LM_Pupa_mass <- lmer(Pupa_mass ~ Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region, data = Data)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
summary(LM_Pupa_mass)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Pupa_mass ~ Treatment_bis + Sex + Species + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Sex:Species + Region:Species +  
##     Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data
## 
## REML criterion at convergence: -827
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -3.1746 -0.4147 -0.0613  0.4129  3.1564 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 5.817e-04 0.024119
##  Site     (Intercept) 4.711e-04 0.021706
##  Room     (Intercept) 1.845e-06 0.001358
##  Residual             1.942e-03 0.044066
## Number of obs: 288, groups:  Mother, 35; Site, 15; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                               3.236e-01  1.493e-02  1.804e+01
## Treatment_bisFull                         1.673e-02  1.172e-02  2.472e+02
## Treatment_bisSmart                        3.451e-03  1.403e-02  1.971e+02
## Treatment_bisMixt_smart                   5.505e-02  1.623e-02  1.800e+02
## SexMale                                   2.074e-02  1.090e-02  2.543e+02
## SpeciesOP                                -1.594e-01  1.841e-02  3.515e+01
## RegionLuxembourg                          1.109e-02  1.947e-02  1.575e+01
## SexMale:SpeciesOP                        -1.823e-02  1.160e-02  2.523e+02
## SpeciesOP:RegionLuxembourg               -1.974e-02  2.362e-02  2.302e+01
## Treatment_bisFull:SpeciesOP              -1.638e-02  1.257e-02  2.483e+02
## Treatment_bisSmart:SpeciesOP              1.077e-02  1.656e-02  2.522e+02
## Treatment_bisFull:SexMale                -5.581e-04  1.265e-02  2.498e+02
## Treatment_bisSmart:SexMale               -2.591e-02  1.683e-02  2.603e+02
## Treatment_bisMixt_smart:SexMale          -5.771e-02  2.049e-02  2.547e+02
## Treatment_bisFull:RegionLuxembourg        7.998e-03  1.258e-02  2.481e+02
## Treatment_bisSmart:RegionLuxembourg       8.815e-03  1.594e-02  2.494e+02
## Treatment_bisMixt_smart:RegionLuxembourg  4.570e-02  2.014e-02  2.524e+02
##                                          t value Pr(>|t|)    
## (Intercept)                               21.666 2.29e-14 ***
## Treatment_bisFull                          1.427 0.154701    
## Treatment_bisSmart                         0.246 0.805956    
## Treatment_bisMixt_smart                    3.393 0.000851 ***
## SexMale                                    1.902 0.058251 .  
## SpeciesOP                                 -8.658 3.08e-10 ***
## RegionLuxembourg                           0.570 0.576800    
## SexMale:SpeciesOP                         -1.572 0.117286    
## SpeciesOP:RegionLuxembourg                -0.836 0.411726    
## Treatment_bisFull:SpeciesOP               -1.303 0.193808    
## Treatment_bisSmart:SpeciesOP               0.650 0.516065    
## Treatment_bisFull:SexMale                 -0.044 0.964832    
## Treatment_bisSmart:SexMale                -1.539 0.125002    
## Treatment_bisMixt_smart:SexMale           -2.817 0.005231 ** 
## Treatment_bisFull:RegionLuxembourg         0.636 0.525643    
## Treatment_bisSmart:RegionLuxembourg        0.553 0.580822    
## Treatment_bisMixt_smart:RegionLuxembourg   2.270 0.024082 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 17 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient

Vérification des hypothèses

qqnorm(resid(LM_Pupa_mass))
qqline(resid(LM_Pupa_mass))

Une modification des données est nécessaire

LM_Pupa_mass <- lmer(log(Pupa_mass) ~ Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region, data = Data)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
summary(LM_Pupa_mass)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Pupa_mass) ~ Treatment_bis + Sex + Species + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Sex:Species + Region:Species +  
##     Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data
## 
## REML criterion at convergence: -173.3
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -3.7997 -0.5194 -0.0361  0.5925  2.6501 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0081743 0.09041 
##  Site     (Intercept) 0.0016180 0.04022 
##  Room     (Intercept) 0.0002465 0.01570 
##  Residual             0.0216932 0.14729 
## Number of obs: 288, groups:  Mother, 35; Site, 15; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                               -1.159437   0.046059  23.082221
## Treatment_bisFull                          0.058897   0.039224 247.902786
## Treatment_bisSmart                         0.023849   0.047302 236.570590
## Treatment_bisMixt_smart                    0.163299   0.054827 231.860153
## SexMale                                    0.061889   0.036432 255.388721
## SpeciesOP                                 -0.717450   0.062067  41.503349
## RegionLuxembourg                           0.044759   0.058080  24.964495
## SexMale:SpeciesOP                         -0.052370   0.038754 253.584990
## SpeciesOP:RegionLuxembourg                -0.081379   0.080940  29.739302
## Treatment_bisFull:SpeciesOP               -0.031081   0.042079 249.800337
## Treatment_bisSmart:SpeciesOP               0.027601   0.055488 253.951908
## Treatment_bisFull:SexMale                 -0.008714   0.042316 250.518122
## Treatment_bisSmart:SexMale                -0.051378   0.056344 262.240865
## Treatment_bisMixt_smart:SexMale           -0.155689   0.068472 255.857117
## Treatment_bisFull:RegionLuxembourg         0.010560   0.042080 248.995529
## Treatment_bisSmart:RegionLuxembourg        0.017807   0.053329 250.617895
## Treatment_bisMixt_smart:RegionLuxembourg   0.108362   0.067306 253.671981
##                                          t value Pr(>|t|)    
## (Intercept)                              -25.173  < 2e-16 ***
## Treatment_bisFull                          1.502  0.13448    
## Treatment_bisSmart                         0.504  0.61460    
## Treatment_bisMixt_smart                    2.978  0.00321 ** 
## SexMale                                    1.699  0.09058 .  
## SpeciesOP                                -11.559 1.48e-14 ***
## RegionLuxembourg                           0.771  0.44815    
## SexMale:SpeciesOP                         -1.351  0.17780    
## SpeciesOP:RegionLuxembourg                -1.005  0.32280    
## Treatment_bisFull:SpeciesOP               -0.739  0.46083    
## Treatment_bisSmart:SpeciesOP               0.497  0.61932    
## Treatment_bisFull:SexMale                 -0.206  0.83702    
## Treatment_bisSmart:SexMale                -0.912  0.36268    
## Treatment_bisMixt_smart:SexMale           -2.274  0.02381 *  
## Treatment_bisFull:RegionLuxembourg         0.251  0.80207    
## Treatment_bisSmart:RegionLuxembourg        0.334  0.73873    
## Treatment_bisMixt_smart:RegionLuxembourg   1.610  0.10864    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 17 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
qqnorm(resid(LM_Pupa_mass))
qqline(resid(LM_Pupa_mass))

Je pense que la normalité est ok.

Homogénité des variances

plot(LM_Pupa_mass)

Distance de cook

plot(cooks.distance(LM_Pupa_mass))

4.6.2 Simplification du modèle

drop1(LM_Pupa_mass)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Pupa_mass) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region
##                         Sum Sq  Mean Sq NumDF   DenDF F value Pr(>F)
## Sex:Species           0.039613 0.039613     1 253.585  1.8261 0.1778
## Species:Region        0.021929 0.021929     1  29.739  1.0109 0.3228
## Treatment_bis:Species 0.026189 0.013094     2 251.109  0.6036 0.5476
## Treatment_bis:Sex     0.123487 0.041162     3 255.779  1.8975 0.1304
## Treatment_bis:Region  0.058108 0.019369     3 250.167  0.8929 0.4454
LM_Pupa_mass1 <- update(LM_Pupa_mass, . ~ . - Treatment_bis:Region)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
drop1(LM_Pupa_mass1)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Pupa_mass) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Species:Region + Treatment_bis:Species + Treatment_bis:Sex
##                         Sum Sq  Mean Sq NumDF   DenDF F value Pr(>F)
## Sex:Species           0.038991 0.038991     1 256.876  1.7934 0.1817
## Species:Region        0.036320 0.036320     1  28.519  1.6705 0.2066
## Treatment_bis:Species 0.026841 0.013421     2 254.612  0.6173 0.5402
## Treatment_bis:Sex     0.115544 0.038515     3 259.087  1.7715 0.1530
LM_Pupa_mass2 <- update(LM_Pupa_mass1, . ~ . - Treatment_bis:Species)
drop1(LM_Pupa_mass2)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Pupa_mass) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Species:Region + Treatment_bis:Sex
##                     Sum Sq  Mean Sq NumDF   DenDF F value Pr(>F)
## Sex:Species       0.043904 0.043904     1 258.563  2.0241 0.1560
## Species:Region    0.033971 0.033971     1  28.494  1.5662 0.2209
## Treatment_bis:Sex 0.114387 0.038129     3 260.779  1.7579 0.1556
LM_Pupa_mass3 <- update(LM_Pupa_mass2, . ~ . - Treatment_bis:Sex)
drop1(LM_Pupa_mass3)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Pupa_mass) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Species:Region
##                 Sum Sq  Mean Sq NumDF   DenDF F value   Pr(>F)   
## Treatment_bis  0.36788 0.122627     3  97.951  5.5939 0.001391 **
## Sex:Species    0.01144 0.011445     1 262.323  0.5221 0.470602   
## Species:Region 0.03591 0.035906     1  28.636  1.6379 0.210882   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Pupa_mass4 <- update(LM_Pupa_mass3, . ~ . - Sex:Species)
drop1(LM_Pupa_mass4)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Pupa_mass) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region
##                 Sum Sq  Mean Sq NumDF   DenDF F value  Pr(>F)   
## Treatment_bis  0.36156 0.120520     3 105.202  5.5140 0.00148 **
## Sex            0.01126 0.011259     1 264.072  0.5151 0.47357   
## Species:Region 0.03635 0.036346     1  28.587  1.6629 0.20755   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Pupa_mass5 <- update(LM_Pupa_mass4, . ~ . - Sex)
drop1(LM_Pupa_mass5)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Pupa_mass) ~ Treatment_bis + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region
##                  Sum Sq  Mean Sq NumDF   DenDF F value   Pr(>F)   
## Treatment_bis  0.303763 0.101254     3 144.503  4.3892 0.005471 **
## Species:Region 0.034196 0.034196     1  29.637  1.4823 0.233015   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Pupa_mass6 <- update(LM_Pupa_mass5, . ~ . - Species:Region)
drop1(LM_Pupa_mass6)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Pupa_mass) ~ Treatment_bis + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room)
##               Sum Sq Mean Sq NumDF   DenDF  F value    Pr(>F)    
## Treatment_bis 0.3048  0.1016     3 140.053   4.3994  0.005439 ** 
## Species       8.7078  8.7078     1  31.820 377.0611 < 2.2e-16 ***
## Region        0.0183  0.0183     1   7.837   0.7908  0.400328    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Il n’y a plus aucune interaction, nous arrêtons la simplification du modèle

Regardons si les simplifications étaient utiles

AIC(LM_Pupa_mass6)
## [1] -176.5115
AIC(LM_Pupa_mass)
## [1] -131.2767

Elle l’a été

LM_Pupa_mass <- LM_Pupa_mass6

4.6.3 Treatment VS Treatment_bis

AIC(lmer(log(Pupa_mass) ~ Treatment_bis + Species + Region + (1 | Mother) +  (1 | Site) + (1 | Room), data = Data))
## [1] -176.5115
AIC(lmer(log(Pupa_mass) ~ Treatment + Species + Region + (1 | Mother) +  (1 | Site) + (1 | Room), data = Data))
## boundary (singular) fit: see help('isSingular')
## [1] -177.1378
summary(lmer(log(Pupa_mass) ~ Treatment_bis + Species + Region + (1 | Mother) +  (1 | Site) + (1 | Room), data = Data))$coeff
##                            Estimate Std. Error         df     t value
## (Intercept)             -1.11485370 0.03641410  10.022152 -30.6159861
## Treatment_bisFull        0.03366768 0.02126123 261.847742   1.5835245
## Treatment_bisSmart       0.01026932 0.02828342 158.542150   0.3630862
## Treatment_bisMixt_smart  0.12571078 0.03537482 204.036224   3.5536798
## SpeciesOP               -0.79298016 0.04083725  31.820207 -19.4180610
## RegionLuxembourg         0.03502196 0.03938257   7.836814   0.8892758
##                             Pr(>|t|)
## (Intercept)             3.111105e-11
## Treatment_bisFull       1.145090e-01
## Treatment_bisSmart      7.170241e-01
## Treatment_bisMixt_smart 4.719401e-04
## SpeciesOP               3.319481e-19
## RegionLuxembourg        4.003276e-01
summary(lmer(log(Pupa_mass) ~ Treatment + Species + Region + (1 | Mother) +  (1 | Site) + (1 | Room), data = Data))$coeff
## boundary (singular) fit: see help('isSingular')
##                     Estimate Std. Error         df     t value     Pr(>|t|)
## (Intercept)      -1.11264604 0.04159904   5.848142 -26.7469137 2.436948e-07
## TreatmentFull     0.04130535 0.02235363 262.595199   1.8478136 6.575383e-02
## TreatmentSmart    0.05503177 0.02243855 265.235145   2.4525549 1.482914e-02
## SpeciesOP        -0.81478596 0.04048370  30.261326 -20.1262729 4.490787e-19
## RegionLuxembourg  0.03477702 0.03884826  32.002473   0.8952017 3.773634e-01

Les AIC sont assez proche mais pour une fois je serais plus d’avis de sélectionner la colonne Treatment et non treatment_bis au vu des p-val. Je pars sur Treatment.

Analyse des p-val

summary(lmer(log(Pupa_mass) ~ Treatment + Species + Region + (1 | Mother) +  (1 | Site) + (1 | Room), data = Data))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Pupa_mass) ~ Treatment + Species + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room)
##    Data: Data
## 
## REML criterion at convergence: -195.1
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -3.6328 -0.5054  0.0294  0.5453  3.5681 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 9.449e-03 9.721e-02
##  Site     (Intercept) 9.867e-11 9.933e-06
##  Room     (Intercept) 1.218e-03 3.490e-02
##  Residual             2.342e-02 1.530e-01
## Number of obs: 292, groups:  Mother, 35; Site, 15; Room, 2
## 
## Fixed effects:
##                   Estimate Std. Error        df t value Pr(>|t|)    
## (Intercept)       -1.11265    0.04160   5.84814 -26.747 2.44e-07 ***
## TreatmentFull      0.04131    0.02235 262.59520   1.848   0.0658 .  
## TreatmentSmart     0.05503    0.02244 265.23515   2.453   0.0148 *  
## SpeciesOP         -0.81479    0.04048  30.26133 -20.126  < 2e-16 ***
## RegionLuxembourg   0.03478    0.03885  32.00247   0.895   0.3774    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TrtmnF TrtmnS SpcsOP
## TreatmntFll -0.267                     
## TretmntSmrt -0.276  0.510              
## SpeciesOP   -0.366 -0.003  0.033       
## ReginLxmbrg -0.455  0.005 -0.029  0.024
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Pupa_mass) ~ Treatment + Species + Region + (1 | Mother) +  (1 | Site) + (1 | Room), data = Data_ref_full))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Pupa_mass) ~ Treatment + Species + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room)
##    Data: Data_ref_full
## 
## REML criterion at convergence: -195.1
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -3.6328 -0.5054  0.0294  0.5453  3.5681 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 9.449e-03 9.721e-02
##  Site     (Intercept) 9.867e-11 9.933e-06
##  Room     (Intercept) 1.218e-03 3.490e-02
##  Residual             2.342e-02 1.530e-01
## Number of obs: 292, groups:  Mother, 35; Site, 15; Room, 2
## 
## Fixed effects:
##                   Estimate Std. Error        df t value Pr(>|t|)    
## (Intercept)       -1.07134    0.04163   5.86668 -25.735 2.94e-07 ***
## TreatmentDark     -0.04131    0.02235 262.59520  -1.848   0.0658 .  
## TreatmentSmart     0.01373    0.02218 261.32124   0.619   0.5365    
## SpeciesOP         -0.81479    0.04048  30.26133 -20.126  < 2e-16 ***
## RegionLuxembourg   0.03478    0.03885  32.00251   0.895   0.3774    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TrtmnD TrtmnS SpcsOP
## TreatmntDrk -0.270                     
## TretmntSmrt -0.274  0.492              
## SpeciesOP   -0.367  0.003  0.036       
## ReginLxmbrg -0.452 -0.005 -0.034  0.024
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Pupa_mass) ~ Treatment + Species + Region + (1 | Mother) +  (1 | Site) + (1 | Room), data = Data_ref_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Pupa_mass) ~ Treatment + Species + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room)
##    Data: Data_ref_smart
## 
## REML criterion at convergence: -195.1
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -3.6328 -0.5054  0.0294  0.5453  3.5681 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 9.449e-03 9.721e-02
##  Site     (Intercept) 9.867e-11 9.933e-06
##  Room     (Intercept) 1.218e-03 3.490e-02
##  Residual             2.342e-02 1.530e-01
## Number of obs: 292, groups:  Mother, 35; Site, 15; Room, 2
## 
## Fixed effects:
##                   Estimate Std. Error        df t value Pr(>|t|)    
## (Intercept)       -1.05761    0.04146   5.76879 -25.510 3.74e-07 ***
## TreatmentDark     -0.05503    0.02244 265.23515  -2.453   0.0148 *  
## TreatmentFull     -0.01373    0.02218 261.32124  -0.619   0.5365    
## SpeciesOP         -0.81479    0.04048  30.26133 -20.126  < 2e-16 ***
## RegionLuxembourg   0.03478    0.03885  32.00248   0.895   0.3774    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TrtmnD TrtmnF SpcsOP
## TreatmntDrk -0.264                     
## TreatmntFll -0.260  0.498              
## SpeciesOP   -0.349 -0.033 -0.036       
## ReginLxmbrg -0.472  0.029  0.034  0.024
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
Info_Pupa_mass <- "
Le traitement Full (P = 0.0658) est presque significativement plus lourd que le le traitement Dark.
Le traitement Smart est significativement plus lourd que le traitement Dark.
L'espèce OP est significativement plus légère.
"
Info_Pupa_mass
## [1] "\nLe traitement Full (P = 0.0658) est presque significativement plus lourd que le le traitement Dark.\nLe traitement Smart est significativement plus lourd que le traitement Dark.\nL'espèce OP est significativement plus légère.\n"

4.6.4 Visualisation

Summary_Pupa_mass <- Data %>% 
  filter(Pupa_mass != "NA") %>% 
  group_by(Treatment, Species, Region) %>% 
  summarise(Mean=mean(log(Pupa_mass)),
            Var=var(log(Pupa_mass)),
            N=n()) %>% 
  mutate(CI_S=Mean+qt(0.975, N-1)*sqrt(Var/N),
         CI_I=Mean-qt(0.975, N-1)*sqrt(Var/N))
ggplot(Summary_Pupa_mass, aes(x=Treatment, y=Mean, color = Species))+
  geom_errorbar(aes(ymin=CI_I, ymax=CI_S),width=0.2,size = 1.2, alpha = 0.5) +
  geom_point(alpha = 0.8) +
  facet_grid(~Region) +
  labs(title = "Poids des chrysalides", x = "Traitement", y = "log(Poids des chrysalides (g) )", color = "Espèce") +
  theme_bw()

4.7 Adult_mass

4.7.1 Test

LM_Adult_mass <- lmer(Adult_mass ~ Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region, data = Data)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
summary(LM_Adult_mass)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Adult_mass ~ Treatment_bis + Sex + Species + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Sex:Species + Region:Species +  
##     Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data
## 
## REML criterion at convergence: -964.5
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -3.0550 -0.4644 -0.0047  0.4095  4.1061 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 1.950e-04 0.013964
##  Site     (Intercept) 1.210e-04 0.010999
##  Room     (Intercept) 1.648e-05 0.004059
##  Residual             8.733e-04 0.029551
## Number of obs: 267, groups:  Mother, 35; Site, 15; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                               1.917e-01  9.558e-03  1.962e+01
## Treatment_bisFull                         2.209e-02  8.420e-03  2.252e+02
## Treatment_bisSmart                        1.035e-02  1.011e-02  2.177e+02
## Treatment_bisMixt_smart                   4.010e-02  1.137e-02  2.273e+02
## SexMale                                  -1.988e-02  7.638e-03  2.365e+02
## SpeciesOP                                -9.715e-02  1.148e-02  3.775e+01
## RegionLuxembourg                          7.836e-03  1.160e-02  2.278e+01
## SexMale:SpeciesOP                         6.198e-03  8.090e-03  2.283e+02
## SpeciesOP:RegionLuxembourg               -1.099e-02  1.419e-02  2.325e+01
## Treatment_bisFull:SpeciesOP              -1.655e-02  8.859e-03  2.273e+02
## Treatment_bisSmart:SpeciesOP              2.690e-03  1.153e-02  2.248e+02
## Treatment_bisFull:SexMale                 1.803e-03  8.877e-03  2.325e+02
## Treatment_bisSmart:SexMale               -4.729e-03  1.179e-02  2.408e+02
## Treatment_bisMixt_smart:SexMale          -3.741e-02  1.443e-02  2.403e+02
## Treatment_bisFull:RegionLuxembourg       -8.193e-04  8.723e-03  2.238e+02
## Treatment_bisSmart:RegionLuxembourg      -4.877e-03  1.116e-02  2.216e+02
## Treatment_bisMixt_smart:RegionLuxembourg  2.390e-02  1.411e-02  2.324e+02
##                                          t value Pr(>|t|)    
## (Intercept)                               20.052 1.54e-14 ***
## Treatment_bisFull                          2.623 0.009304 ** 
## Treatment_bisSmart                         1.024 0.307114    
## Treatment_bisMixt_smart                    3.528 0.000506 ***
## SexMale                                   -2.603 0.009831 ** 
## SpeciesOP                                 -8.465 2.98e-10 ***
## RegionLuxembourg                           0.676 0.506052    
## SexMale:SpeciesOP                          0.766 0.444375    
## SpeciesOP:RegionLuxembourg                -0.774 0.446603    
## Treatment_bisFull:SpeciesOP               -1.868 0.063068 .  
## Treatment_bisSmart:SpeciesOP               0.233 0.815795    
## Treatment_bisFull:SexMale                  0.203 0.839200    
## Treatment_bisSmart:SexMale                -0.401 0.688646    
## Treatment_bisMixt_smart:SexMale           -2.592 0.010112 *  
## Treatment_bisFull:RegionLuxembourg        -0.094 0.925256    
## Treatment_bisSmart:RegionLuxembourg       -0.437 0.662522    
## Treatment_bisMixt_smart:RegionLuxembourg   1.693 0.091783 .  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 17 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient

Vérification des hypothèses

qqnorm(resid(LM_Adult_mass))
qqline(resid(LM_Adult_mass))

Une modification des données est nécessaire.

LM_Adult_mass <- lmer(log(Adult_mass) ~ Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region, data = Data)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
summary(LM_Adult_mass)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Adult_mass) ~ Treatment_bis + Sex + Species + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Sex:Species + Region:Species +  
##     Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data
## 
## REML criterion at convergence: -67
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -3.4145 -0.5848  0.0962  0.5492  2.7251 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0049108 0.07008 
##  Site     (Intercept) 0.0020527 0.04531 
##  Room     (Intercept) 0.0005858 0.02420 
##  Residual             0.0328065 0.18113 
## Number of obs: 267, groups:  Mother, 35; Site, 15; Room, 2
## 
## Fixed effects:
##                                           Estimate Std. Error        df t value
## (Intercept)                               -1.69468    0.05205  19.48485 -32.558
## Treatment_bisFull                          0.13766    0.05144 228.20505   2.676
## Treatment_bisSmart                         0.07193    0.06178 220.02668   1.164
## Treatment_bisMixt_smart                    0.20067    0.06923 230.07090   2.898
## SexMale                                   -0.11432    0.04643 240.96571  -2.462
## SpeciesOP                                 -0.71263    0.06290  43.18709 -11.329
## RegionLuxembourg                           0.06343    0.06129  31.88112   1.035
## SexMale:SpeciesOP                         -0.06067    0.04930 232.67779  -1.231
## SpeciesOP:RegionLuxembourg                -0.09203    0.07576  23.88701  -1.215
## Treatment_bisFull:SpeciesOP               -0.05461    0.05408 230.29959  -1.010
## Treatment_bisSmart:SpeciesOP               0.01466    0.07045 228.19172   0.208
## Treatment_bisFull:SexMale                  0.01757    0.05408 236.62925   0.325
## Treatment_bisSmart:SexMale                 0.02017    0.07153 244.59652   0.282
## Treatment_bisMixt_smart:SexMale           -0.14667    0.08753 245.17031  -1.676
## Treatment_bisFull:RegionLuxembourg        -0.03240    0.05329 226.55231  -0.608
## Treatment_bisSmart:RegionLuxembourg       -0.04387    0.06825 224.50158  -0.643
## Treatment_bisMixt_smart:RegionLuxembourg   0.09566    0.08596 235.72876   1.113
##                                          Pr(>|t|)    
## (Intercept)                               < 2e-16 ***
## Treatment_bisFull                         0.00799 ** 
## Treatment_bisSmart                        0.24558    
## Treatment_bisMixt_smart                   0.00411 ** 
## SexMale                                   0.01450 *  
## SpeciesOP                                1.61e-14 ***
## RegionLuxembourg                          0.30855    
## SexMale:SpeciesOP                         0.21963    
## SpeciesOP:RegionLuxembourg                0.23635    
## Treatment_bisFull:SpeciesOP               0.31363    
## Treatment_bisSmart:SpeciesOP              0.83539    
## Treatment_bisFull:SexMale                 0.74559    
## Treatment_bisSmart:SexMale                0.77818    
## Treatment_bisMixt_smart:SexMale           0.09507 .  
## Treatment_bisFull:RegionLuxembourg        0.54379    
## Treatment_bisSmart:RegionLuxembourg       0.52102    
## Treatment_bisMixt_smart:RegionLuxembourg  0.26692    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 17 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
qqnorm(resid(LM_Adult_mass))
qqline(resid(LM_Adult_mass))

Homogénité des variances

plot(LM_Adult_mass)

Distance de cook

plot(cooks.distance(LM_Adult_mass))

4.7.2 Simplification du modèle

drop1(LM_Adult_mass)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Adult_mass) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region
##                         Sum Sq  Mean Sq NumDF   DenDF F value Pr(>F)
## Sex:Species           0.049701 0.049701     1 232.678  1.5150 0.2196
## Species:Region        0.048405 0.048405     1  23.887  1.4755 0.2364
## Treatment_bis:Species 0.045458 0.022729     2 228.905  0.6928 0.5012
## Treatment_bis:Sex     0.127423 0.042474     3 240.167  1.2947 0.2769
## Treatment_bis:Region  0.089449 0.029816     3 228.924  0.9089 0.4375
LM_Adult_mass1 <- update(LM_Adult_mass, . ~ . - Treatment_bis:Species)
drop1(LM_Adult_mass1)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Adult_mass) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Species:Region + Treatment_bis:Sex + Treatment_bis:Region
##                        Sum Sq  Mean Sq NumDF   DenDF F value Pr(>F)
## Sex:Species          0.059771 0.059771     1 233.527  1.8303 0.1774
## Species:Region       0.045475 0.045475     1  24.003  1.3925 0.2495
## Treatment_bis:Sex    0.134890 0.044963     3 241.690  1.3768 0.2504
## Treatment_bis:Region 0.097870 0.032623     3 230.856  0.9990 0.3941
LM_Adult_mass2 <- update(LM_Adult_mass1, . ~ . - Treatment_bis:Region)
drop1(LM_Adult_mass2)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Adult_mass) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Species:Region + Treatment_bis:Sex
##                     Sum Sq  Mean Sq NumDF   DenDF F value Pr(>F)
## Sex:Species       0.058300 0.058300     1 237.467  1.7771 0.1838
## Species:Region    0.074952 0.074952     1  21.922  2.2847 0.1449
## Treatment_bis:Sex 0.128122 0.042707     3 245.517  1.3018 0.2744
LM_Adult_mass3 <- update(LM_Adult_mass2, . ~ . - Treatment_bis:Sex)
drop1(LM_Adult_mass3)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Adult_mass) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Species:Region
##                 Sum Sq  Mean Sq NumDF   DenDF F value   Pr(>F)    
## Treatment_bis  0.72726 0.242421     3 129.321  7.3485 0.000138 ***
## Sex:Species    0.02244 0.022439     1 242.655  0.6802 0.410334    
## Species:Region 0.08141 0.081406     1  22.513  2.4677 0.130161    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Adult_mass4 <- update(LM_Adult_mass3, . ~ . - Sex:Species)
drop1(LM_Adult_mass4)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Adult_mass) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region
##                 Sum Sq Mean Sq NumDF   DenDF F value    Pr(>F)    
## Treatment_bis  0.71349 0.23783     3 134.474  7.2238 0.0001568 ***
## Sex            1.33152 1.33152     1 246.586 40.4433 9.747e-10 ***
## Species:Region 0.08083 0.08083     1  22.385  2.4550 0.1311777    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Adult_mass5 <- update(LM_Adult_mass4, . ~ . - Species:Region)
drop1(LM_Adult_mass5)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Adult_mass) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room)
##                Sum Sq Mean Sq NumDF   DenDF  F value    Pr(>F)    
## Treatment_bis  0.6924  0.2308     3 128.767   7.0119 0.0002095 ***
## Sex            1.3324  1.3324     1 245.959  40.4801 9.625e-10 ***
## Species       14.7698 14.7698     1  26.531 448.7142 < 2.2e-16 ***
## Region         0.0063  0.0063     1  10.270   0.1901 0.6718326    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Nous n’avons plus d’interaction, nous arrêtons la simplification du modèle.

Est ce que la simplification a été utile ?

AIC(LM_Adult_mass5)
## [1] -70.68366
AIC(LM_Adult_mass)
## [1] -24.95704

Oui, clairement

LM_Adult_mass <- LM_Adult_mass5

4.7.3 Treatment VS Treatment_bis

AIC(lmer(log(Adult_mass) ~ Treatment_bis + Sex + Species + Region + (1 |  Mother) + (1 | Site) + (1 | Room), data = Data))
## [1] -70.68366
AIC(lmer(log(Adult_mass) ~ Treatment + Sex + Species + Region + (1 |  Mother) + (1 | Site) + (1 | Room), data = Data))
## [1] -70.01737
summary(lmer(log(Adult_mass) ~ Treatment_bis + Sex + Species + Region + (1 |  Mother) + (1 | Site) + (1 | Room), data = Data))$coeff
##                            Estimate Std. Error         df     t value
## (Intercept)             -1.64384714 0.04150109   8.551585 -39.6097346
## Treatment_bisFull        0.09951414 0.02659351 237.979846   3.7420464
## Treatment_bisSmart       0.05444616 0.03562532 135.161913   1.5282997
## Treatment_bisMixt_smart  0.15819770 0.04376917 197.571796   3.6143636
## SexMale                 -0.14750246 0.02318346 245.958656  -6.3624010
## SpeciesOP               -0.81080683 0.03827652  26.530707 -21.1828747
## RegionLuxembourg         0.01828273 0.04192918  10.269655   0.4360383
##                             Pr(>|t|)
## (Intercept)             5.440142e-11
## Treatment_bisFull       2.288521e-04
## Treatment_bisSmart      1.287750e-01
## Treatment_bisMixt_smart 3.820347e-04
## SexMale                 9.624769e-10
## SpeciesOP               3.748241e-18
## RegionLuxembourg        6.718326e-01
summary(lmer(log(Adult_mass) ~ Treatment + Sex + Species + Region + (1 |  Mother) + (1 | Site) + (1 | Room), data = Data))$coeff
##                     Estimate Std. Error         df     t value     Pr(>|t|)
## (Intercept)      -1.63464765 0.04415767   6.906927 -37.0184321 3.352957e-09
## TreatmentFull     0.10344866 0.02852921 237.210830   3.6260614 3.522174e-04
## TreatmentSmart    0.07396902 0.02804199 238.354540   2.6377947 8.893944e-03
## SexMale          -0.14043353 0.02336806 245.362410  -6.0096361 6.682904e-09
## SpeciesOP        -0.84544727 0.03809351  23.921155 -22.1939976 1.814242e-17
## RegionLuxembourg  0.01604739 0.04111075   9.518202   0.3903453 7.048740e-01
summary(lmer(log(Adult_mass) ~ Treatment + Sex + Species + Region + (1 |  Mother) + (1 | Site) + (1 | Room), data = Data_ref_smart))$coeff
##                     Estimate Std. Error         df     t value     Pr(>|t|)
## (Intercept)      -1.56067864 0.04359782   6.585044 -35.7971723 8.564833e-09
## TreatmentDark    -0.07396902 0.02804199 238.354540  -2.6377947 8.893944e-03
## TreatmentFull     0.02947964 0.02751896 236.390513   1.0712486 2.851501e-01
## SexMale          -0.14043353 0.02336806 245.362410  -6.0096361 6.682904e-09
## SpeciesOP        -0.84544727 0.03809351  23.921155 -22.1939976 1.814242e-17
## RegionLuxembourg  0.01604739 0.04111075   9.518202   0.3903453 7.048740e-01

Les AIC sont plus ou moins simillaires mais vu qu’il y a une différence significative entre Mixt_smart et Smart je pense qu’il est plus correcte scientifiquement parlant de prendre Treatment_bis

Analyse des P-val

summary(lmer(log(Adult_mass) ~ Treatment_bis + Sex + Species + Region + (1 |  Mother) + (1 | Site) + (1 | Room), data = Data))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Adult_mass) ~ Treatment_bis + Sex + Species + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room)
##    Data: Data
## 
## REML criterion at convergence: -92.7
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -3.6044 -0.5960  0.0509  0.6052  2.9552 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0053883 0.07340 
##  Site     (Intercept) 0.0015578 0.03947 
##  Room     (Intercept) 0.0006429 0.02535 
##  Residual             0.0329157 0.18143 
## Number of obs: 267, groups:  Mother, 35; Site, 15; Room, 2
## 
## Fixed effects:
##                          Estimate Std. Error        df t value Pr(>|t|)    
## (Intercept)              -1.64385    0.04150   8.55158 -39.610 5.44e-11 ***
## Treatment_bisFull         0.09951    0.02659 237.97985   3.742 0.000229 ***
## Treatment_bisSmart        0.05445    0.03563 135.16191   1.528 0.128775    
## Treatment_bisMixt_smart   0.15820    0.04377 197.57180   3.614 0.000382 ***
## SexMale                  -0.14750    0.02318 245.95866  -6.362 9.62e-10 ***
## SpeciesOP                -0.81081    0.03828  26.53071 -21.183  < 2e-16 ***
## RegionLuxembourg          0.01828    0.04193  10.26965   0.436 0.671833    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal SpcsOP
## Trtmnt_bsFl -0.275                                   
## Trtmnt_bsSm -0.233  0.361                            
## Trtmnt_bsM_ -0.275  0.287  0.160                     
## SexMale     -0.216 -0.108  0.009 -0.062              
## SpeciesOP   -0.393  0.019  0.061  0.226 -0.010       
## ReginLxmbrg -0.485  0.001 -0.058  0.006 -0.012 -0.001
summary(lmer(log(Adult_mass) ~ Treatment_bis + Sex + Species + Region + (1 |  Mother) + (1 | Site) + (1 | Room), data = Data_ref_full))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Adult_mass) ~ Treatment_bis + Sex + Species + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room)
##    Data: Data_ref_full
## 
## REML criterion at convergence: -92.7
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -3.6044 -0.5960  0.0509  0.6052  2.9552 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0053883 0.07340 
##  Site     (Intercept) 0.0015578 0.03947 
##  Room     (Intercept) 0.0006429 0.02535 
##  Residual             0.0329157 0.18143 
## Number of obs: 267, groups:  Mother, 35; Site, 15; Room, 2
## 
## Fixed effects:
##                          Estimate Std. Error        df t value Pr(>|t|)    
## (Intercept)              -1.54433    0.04270   9.62358 -36.170 1.32e-11 ***
## Treatment_bisDark        -0.09951    0.02659 237.97985  -3.742 0.000229 ***
## Treatment_bisSmart       -0.04507    0.03596 172.73269  -1.253 0.211817    
## Treatment_bisMixt_smart   0.05868    0.04421 169.57954   1.327 0.186191    
## SexMale                  -0.14750    0.02318 245.95866  -6.362 9.62e-10 ***
## SpeciesOP                -0.81081    0.03828  26.53071 -21.183  < 2e-16 ***
## RegionLuxembourg          0.01828    0.04193  10.26965   0.436 0.671833    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S Trt_M_ SexMal SpcsOP
## Trtmnt_bsDr -0.356                                   
## Trtmnt_bsSm -0.265  0.382                            
## Trtmnt_bsM_ -0.302  0.317  0.176                     
## SexMale     -0.278  0.108  0.089  0.004              
## SpeciesOP   -0.370 -0.019  0.046  0.212 -0.010       
## ReginLxmbrg -0.471 -0.001 -0.058  0.005 -0.012 -0.001
summary(lmer(log(Adult_mass) ~ Treatment_bis + Sex + Species + Region + (1 |  Mother) + (1 | Site) + (1 | Room), data = Data_ref_smart))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Adult_mass) ~ Treatment_bis + Sex + Species + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room)
##    Data: Data_ref_smart
## 
## REML criterion at convergence: -92.7
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -3.6044 -0.5960  0.0509  0.6052  2.9552 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0053883 0.07340 
##  Site     (Intercept) 0.0015578 0.03947 
##  Room     (Intercept) 0.0006429 0.02535 
##  Residual             0.0329157 0.18143 
## Number of obs: 267, groups:  Mother, 35; Site, 15; Room, 2
## 
## Fixed effects:
##                          Estimate Std. Error        df t value Pr(>|t|)    
## (Intercept)              -1.58940    0.04797  12.58720 -33.131 1.26e-13 ***
## Treatment_bisDark        -0.05445    0.03563 135.16191  -1.528   0.1288    
## Treatment_bisFull         0.04507    0.03596 172.73269   1.253   0.2118    
## Treatment_bisMixt_smart   0.10375    0.05184  66.06313   2.002   0.0494 *  
## SexMale                  -0.14750    0.02318 245.95866  -6.362 9.62e-10 ***
## SpeciesOP                -0.81081    0.03828  26.53071 -21.183  < 2e-16 ***
## RegionLuxembourg          0.01828    0.04193  10.26965   0.436   0.6718    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trt_M_ SexMal SpcsOP
## Trtmnt_bsDr -0.541                                   
## Trtmnt_bsFl -0.513  0.724                            
## Trtmnt_bsM_ -0.472  0.552  0.543                     
## SexMale     -0.181 -0.009 -0.089 -0.058              
## SpeciesOP   -0.294 -0.061 -0.046  0.149 -0.010       
## ReginLxmbrg -0.462  0.058  0.058  0.044 -0.012 -0.001
Info_Adult_mass <- "
classsement croissant de poids : Dark < Smart < Full et Mixt_smart
Les males sont moins lourds
OP est moins lourds
"
Info_Adult_mass
## [1] "\nclasssement croissant de poids : Dark < Smart < Full et Mixt_smart\nLes males sont moins lourds\nOP est moins lourds\n"

4.7.4 Visualisation

Summary_Adult_mass <- Data %>% 
  filter(Adult_mass != "NA", Sex != "NA") %>% 
  group_by(Treatment_bis, Species, Sex) %>% 
  summarise(Mean=mean(log(Adult_mass)),
            Var=var(log(Adult_mass)),
            N=n()) %>% 
  mutate(CI_S=Mean+qt(0.975, N-1)*sqrt(Var/N),
         CI_I=Mean-qt(0.975, N-1)*sqrt(Var/N))
ggplot(Summary_Adult_mass, aes(x=Treatment_bis, y=Mean, color = Species))+
  geom_errorbar(aes(ymin=CI_I, ymax=CI_S),width=0.2,size = 1.2, alpha = 0.5) +
  geom_point(alpha = 0.8) +
  facet_grid(~Sex) +
  labs(title = "Poids des adultes", x = "Traitement", y = "log(Poids des adultes (g))", color = "Espèce") +
  theme_bw()

4.8 M0

4.8.1 Test

LM_M0 <- lmer(M0 ~ Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region, data = Data)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
summary(LM_M0)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: M0 ~ Treatment_bis + Sex + Species + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Sex:Species + Region:Species +  
##     Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data
## 
## REML criterion at convergence: -1752.3
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.3630 -0.5563 -0.0803  0.4921  4.6891 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 3.608e-05 0.006007
##  Site     (Intercept) 0.000e+00 0.000000
##  Room     (Intercept) 0.000e+00 0.000000
##  Residual             9.359e-05 0.009674
## Number of obs: 304, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                               1.385e-02  2.604e-03  7.190e+01
## Treatment_bisFull                        -7.228e-04  2.530e-03  2.635e+02
## Treatment_bisSmart                       -3.336e-03  3.026e-03  2.624e+02
## Treatment_bisMixt_smart                  -2.461e-04  3.533e-03  2.660e+02
## SexMale                                   1.359e-04  2.335e-03  2.711e+02
## SpeciesOP                                 2.144e-02  3.851e-03  3.959e+01
## RegionLuxembourg                          1.074e-03  3.393e-03  5.279e+01
## SexMale:SpeciesOP                        -5.843e-06  2.466e-03  2.676e+02
## SpeciesOP:RegionLuxembourg               -3.803e-03  4.984e-03  2.810e+01
## Treatment_bisFull:SpeciesOP               1.549e-03  2.681e-03  2.644e+02
## Treatment_bisSmart:SpeciesOP             -1.655e-03  3.487e-03  2.621e+02
## Treatment_bisFull:SexMale                 5.835e-04  2.701e-03  2.650e+02
## Treatment_bisSmart:SexMale                2.238e-03  3.567e-03  2.747e+02
## Treatment_bisMixt_smart:SexMale           3.039e-03  4.460e-03  2.715e+02
## Treatment_bisFull:RegionLuxembourg       -2.304e-03  2.668e-03  2.634e+02
## Treatment_bisSmart:RegionLuxembourg       6.598e-04  3.399e-03  2.603e+02
## Treatment_bisMixt_smart:RegionLuxembourg -3.525e-03  4.365e-03  2.672e+02
##                                          t value Pr(>|t|)    
## (Intercept)                                5.317 1.14e-06 ***
## Treatment_bisFull                         -0.286    0.775    
## Treatment_bisSmart                        -1.102    0.271    
## Treatment_bisMixt_smart                   -0.070    0.945    
## SexMale                                    0.058    0.954    
## SpeciesOP                                  5.568 1.97e-06 ***
## RegionLuxembourg                           0.316    0.753    
## SexMale:SpeciesOP                         -0.002    0.998    
## SpeciesOP:RegionLuxembourg                -0.763    0.452    
## Treatment_bisFull:SpeciesOP                0.578    0.564    
## Treatment_bisSmart:SpeciesOP              -0.475    0.635    
## Treatment_bisFull:SexMale                  0.216    0.829    
## Treatment_bisSmart:SexMale                 0.627    0.531    
## Treatment_bisMixt_smart:SexMale            0.681    0.496    
## Treatment_bisFull:RegionLuxembourg        -0.864    0.389    
## Treatment_bisSmart:RegionLuxembourg        0.194    0.846    
## Treatment_bisMixt_smart:RegionLuxembourg  -0.808    0.420    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 17 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Vérification des hypothèses

qqnorm(resid(LM_M0))
qqline(resid(LM_M0))

Je pense que ca va

Homogénité des variances

plot(LM_M0)

Il faudrait quand même un sqrt ou quelque chose dans le style

LM_M0 <- lmer(sqrt(M0) ~ Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region, data = Data)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
summary(LM_M0)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: sqrt(M0) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Sex:Species + Region:Species +  
##     Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data
## 
## REML criterion at convergence: -1110.5
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.4434 -0.6501 -0.0323  0.6353  3.5364 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 3.869e-04 1.967e-02
##  Site     (Intercept) 3.323e-06 1.823e-03
##  Room     (Intercept) 1.790e-13 4.231e-07
##  Residual             8.647e-04 2.941e-02
## Number of obs: 304, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                               1.147e-01  8.245e-03  3.534e+01
## Treatment_bisFull                        -4.472e-03  7.697e-03  2.633e+02
## Treatment_bisSmart                       -1.388e-02  9.206e-03  2.624e+02
## Treatment_bisMixt_smart                  -6.030e-04  1.075e-02  2.654e+02
## SexMale                                   2.872e-03  7.110e-03  2.702e+02
## SpeciesOP                                 6.894e-02  1.232e-02  3.871e+01
## RegionLuxembourg                          1.275e-03  1.081e-02  2.989e+01
## SexMale:SpeciesOP                        -9.482e-04  7.506e-03  2.670e+02
## SpeciesOP:RegionLuxembourg               -1.116e-02  1.607e-02  2.903e+01
## Treatment_bisFull:SpeciesOP               6.273e-03  8.159e-03  2.642e+02
## Treatment_bisSmart:SpeciesOP             -2.447e-03  1.061e-02  2.618e+02
## Treatment_bisFull:SexMale                 8.007e-04  8.219e-03  2.644e+02
## Treatment_bisSmart:SexMale                4.260e-03  1.087e-02  2.735e+02
## Treatment_bisMixt_smart:SexMale           8.559e-03  1.358e-02  2.704e+02
## Treatment_bisFull:RegionLuxembourg       -4.421e-03  8.117e-03  2.633e+02
## Treatment_bisSmart:RegionLuxembourg       5.933e-03  1.034e-02  2.603e+02
## Treatment_bisMixt_smart:RegionLuxembourg -1.119e-02  1.329e-02  2.668e+02
##                                          t value Pr(>|t|)    
## (Intercept)                               13.916 6.57e-16 ***
## Treatment_bisFull                         -0.581    0.562    
## Treatment_bisSmart                        -1.508    0.133    
## Treatment_bisMixt_smart                   -0.056    0.955    
## SexMale                                    0.404    0.687    
## SpeciesOP                                  5.598 1.92e-06 ***
## RegionLuxembourg                           0.118    0.907    
## SexMale:SpeciesOP                         -0.126    0.900    
## SpeciesOP:RegionLuxembourg                -0.695    0.493    
## Treatment_bisFull:SpeciesOP                0.769    0.443    
## Treatment_bisSmart:SpeciesOP              -0.231    0.818    
## Treatment_bisFull:SexMale                  0.097    0.922    
## Treatment_bisSmart:SexMale                 0.392    0.695    
## Treatment_bisMixt_smart:SexMale            0.630    0.529    
## Treatment_bisFull:RegionLuxembourg        -0.545    0.586    
## Treatment_bisSmart:RegionLuxembourg        0.574    0.567    
## Treatment_bisMixt_smart:RegionLuxembourg  -0.842    0.400    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 17 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
qqnorm(resid(LM_M0))
qqline(resid(LM_M0))

C’est NICKEL

Homogénité des variances

plot(LM_M0)

c’est correcte

Distance de cook

plot(cooks.distance(LM_M0))

4.8.2 Simplification du modèle

drop1(LM_M0)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## sqrt(M0) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region
##                           Sum Sq    Mean Sq NumDF   DenDF F value Pr(>F)
## Sex:Species           0.00001380 0.00001380     1 267.035  0.0160 0.8996
## Species:Region        0.00041714 0.00041714     1  29.027  0.4824 0.4929
## Treatment_bis:Species 0.00076234 0.00038117     2 262.804  0.4408 0.6440
## Treatment_bis:Sex     0.00041812 0.00013937     3 268.786  0.1612 0.9224
## Treatment_bis:Region  0.00150859 0.00050286     3 262.399  0.5815 0.6276
LM_M0_1 <- update(LM_M0, . ~ . - Treatment_bis:Sex)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
drop1(LM_M0_1)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## sqrt(M0) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Species:Region + Treatment_bis:Species + Treatment_bis:Region
##                           Sum Sq    Mean Sq NumDF   DenDF F value Pr(>F)
## Sex:Species           0.00011537 0.00011537     1 269.609  0.1349 0.7137
## Species:Region        0.00040419 0.00040419     1  29.345  0.4725 0.4972
## Treatment_bis:Species 0.00072899 0.00036449     2 265.358  0.4261 0.6535
## Treatment_bis:Region  0.00149749 0.00049916     3 265.265  0.5836 0.6263
LM_M0_2 <- update(LM_M0_1, . ~ . - Treatment_bis:Species)
## boundary (singular) fit: see help('isSingular')
drop1(LM_M0_2)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## sqrt(M0) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Species:Region + Treatment_bis:Region
##                          Sum Sq    Mean Sq NumDF   DenDF F value Pr(>F)
## Sex:Species          0.00007388 0.00007388     1 270.952  0.0869 0.7684
## Species:Region       0.00041528 0.00041528     1  29.263  0.4885 0.4901
## Treatment_bis:Region 0.00135376 0.00045125     3 266.977  0.5308 0.6615
LM_M0_3 <- update(LM_M0_2, . ~ . - Treatment_bis:Region)
## boundary (singular) fit: see help('isSingular')
drop1(LM_M0_3)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## sqrt(M0) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Species:Region
##                    Sum Sq    Mean Sq NumDF   DenDF F value Pr(>F)
## Treatment_bis  0.00290152 0.00096717     3 269.908  1.1446 0.3315
## Sex:Species    0.00005642 0.00005642     1 273.657  0.0668 0.7963
## Species:Region 0.00032532 0.00032532     1  28.091  0.3850 0.5399
LM_M0_4 <- update(LM_M0_3, . ~ . - Sex:Species)
## boundary (singular) fit: see help('isSingular')
drop1(LM_M0_4)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## sqrt(M0) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region
##                   Sum Sq    Mean Sq NumDF   DenDF F value Pr(>F)
## Treatment_bis  0.0029891 0.00099637     3 270.732  1.1834 0.3164
## Sex            0.0012278 0.00122776     1 275.632  1.4583 0.2282
## Species:Region 0.0003225 0.00032250     1  28.103  0.3830 0.5410
LM_M0_5 <- update(LM_M0_4, . ~ . - Species:Region)
## boundary (singular) fit: see help('isSingular')
drop1(LM_M0_5)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## sqrt(M0) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room)
##                 Sum Sq  Mean Sq NumDF   DenDF F value    Pr(>F)    
## Treatment_bis 0.003020 0.001007     3 270.466  1.1941    0.3124    
## Sex           0.001235 0.001235     1 275.539  1.4653    0.2271    
## Species       0.055808 0.055808     1  29.780 66.1935 4.662e-09 ***
## Region        0.000202 0.000202     1  11.855  0.2398    0.6333    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
summary(LM_M0_5)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: sqrt(M0) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room)
##    Data: Data
## 
## REML criterion at convergence: -1181.2
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.4960 -0.6258 -0.0644  0.6407  3.5925 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 3.728e-04 0.019307
##  Site     (Intercept) 2.333e-05 0.004831
##  Room     (Intercept) 0.000e+00 0.000000
##  Residual             8.431e-04 0.029036
## Number of obs: 304, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                           Estimate Std. Error         df t value Pr(>|t|)    
## (Intercept)              1.158e-01  6.848e-03  2.128e+01  16.916 8.08e-14 ***
## Treatment_bisFull       -3.067e-03  3.991e-03  2.715e+02  -0.769   0.4428    
## Treatment_bisSmart      -9.212e-03  5.057e-03  2.688e+02  -1.822   0.0696 .  
## Treatment_bisMixt_smart -3.091e-04  6.507e-03  2.744e+02  -0.048   0.9621    
## SexMale                  4.215e-03  3.482e-03  2.755e+02   1.211   0.2271    
## SpeciesOP                6.510e-02  8.001e-03  2.978e+01   8.136 4.66e-09 ***
## RegionLuxembourg        -3.933e-03  8.031e-03  1.185e+01  -0.490   0.6333    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal SpcsOP
## Trtmnt_bsFl -0.256                                   
## Trtmnt_bsSm -0.222  0.372                            
## Trtmnt_bsM_ -0.236  0.322  0.271                     
## SexMale     -0.192 -0.089 -0.013 -0.054              
## SpeciesOP   -0.443  0.028  0.064  0.138 -0.001       
## ReginLxmbrg -0.567 -0.007 -0.047 -0.009 -0.012 -0.004
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Nous n’avons plus d’interactions nous pouvons nous arrêter là. Vu qu’il y a aucune différence significative peut-importe le modèle à part pour l’espèce (ce qui est logique), nous pouvons nous arrêter là. Notons cependant que l’espèce OP est significativement plus lourde au départ de l’expérience et que nous avions presque un effet significatif du traitement Smart.

4.9 Total_eaten

4.9.1 Test

LM_Total_eaten <- lmer(Total_eaten ~ Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region, data = Data)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
summary(LM_Total_eaten)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Total_eaten ~ Treatment_bis + Sex + Species + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Sex:Species + Region:Species +  
##     Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data
## 
## REML criterion at convergence: 2429.2
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.9815 -0.3975 -0.0501  0.2431  6.1844 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 159.019  12.61   
##  Site     (Intercept)   8.408   2.90   
##  Room     (Intercept)   0.000   0.00   
##  Residual             184.906  13.60   
## Number of obs: 304, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                           Estimate Std. Error        df t value
## (Intercept)                               65.69025    4.75387  20.46260  13.818
## Treatment_bisFull                          0.28380    3.57395 259.15138   0.079
## Treatment_bisSmart                        -4.56156    4.27250 258.14206  -1.068
## Treatment_bisMixt_smart                   -0.86996    4.99650 260.49839  -0.174
## SexMale                                   -1.05641    3.31250 263.74935  -0.319
## SpeciesOP                                -46.44854    7.32533  33.84382  -6.341
## RegionLuxembourg                           7.55825    6.39414  19.57261   1.182
## SexMale:SpeciesOP                         -0.80946    3.49097 260.81398  -0.232
## SpeciesOP:RegionLuxembourg                -8.79301    9.83654  27.30592  -0.894
## Treatment_bisFull:SpeciesOP               -2.80734    3.78947 258.90055  -0.741
## Treatment_bisSmart:SpeciesOP               7.99767    4.92063 256.98722   1.625
## Treatment_bisFull:SexMale                  2.27051    3.81680 258.92059   0.595
## Treatment_bisSmart:SexMale                -0.09876    5.07313 265.51280  -0.019
## Treatment_bisMixt_smart:SexMale          -12.15096    6.32696 262.55831  -1.921
## Treatment_bisFull:RegionLuxembourg         3.92577    3.76817 258.32976   1.042
## Treatment_bisSmart:RegionLuxembourg       -2.89676    4.79245 255.93432  -0.604
## Treatment_bisMixt_smart:RegionLuxembourg  21.80175    6.18031 260.77765   3.528
##                                          Pr(>|t|)    
## (Intercept)                              7.67e-12 ***
## Treatment_bisFull                        0.936769    
## Treatment_bisSmart                       0.286674    
## Treatment_bisMixt_smart                  0.861912    
## SexMale                                  0.750041    
## SpeciesOP                                3.18e-07 ***
## RegionLuxembourg                         0.251345    
## SexMale:SpeciesOP                        0.816819    
## SpeciesOP:RegionLuxembourg               0.379180    
## Treatment_bisFull:SpeciesOP              0.459471    
## Treatment_bisSmart:SpeciesOP             0.105318    
## Treatment_bisFull:SexMale                0.552448    
## Treatment_bisSmart:SexMale               0.984482    
## Treatment_bisMixt_smart:SexMale          0.055877 .  
## Treatment_bisFull:RegionLuxembourg       0.298467    
## Treatment_bisSmart:RegionLuxembourg      0.546085    
## Treatment_bisMixt_smart:RegionLuxembourg 0.000495 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 17 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Vérification des hypothèses

qqnorm(resid(LM_Total_eaten))
qqline(resid(LM_Total_eaten))

Il faut modifier les variables

LM_Total_eaten <- lmer(log(Total_eaten) ~ Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region, data = Data)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
summary(LM_Total_eaten)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Total_eaten) ~ Treatment_bis + Sex + Species + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Sex:Species + Region:Species +  
##     Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data
## 
## REML criterion at convergence: 55.2
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.3890 -0.6520 -0.0160  0.5467  4.2463 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.03671  0.1916  
##  Site     (Intercept) 0.00000  0.0000  
##  Room     (Intercept) 0.00000  0.0000  
##  Residual             0.04796  0.2190  
## Number of obs: 304, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                                4.109019   0.070890  51.778948
## Treatment_bisFull                          0.028851   0.057515 259.766080
## Treatment_bisSmart                        -0.038988   0.068760 258.843388
## Treatment_bisMixt_smart                    0.026992   0.080401 261.213801
## SexMale                                   -0.011909   0.053271 264.976901
## SpeciesOP                                 -1.229018   0.110638  34.499910
## RegionLuxembourg                           0.125369   0.094892  41.706761
## SexMale:SpeciesOP                         -0.064999   0.056155 262.128923
## SpeciesOP:RegionLuxembourg                -0.189256   0.148241  27.896870
## Treatment_bisFull:SpeciesOP               -0.032808   0.060971 260.041568
## Treatment_bisSmart:SpeciesOP               0.134356   0.079204 257.725410
## Treatment_bisFull:SexMale                  0.025316   0.061426 259.711623
## Treatment_bisSmart:SexMale                 0.005673   0.081553 267.207544
## Treatment_bisMixt_smart:SexMale           -0.189421   0.101747 264.216262
## Treatment_bisFull:RegionLuxembourg         0.053287   0.060638 259.259502
## Treatment_bisSmart:RegionLuxembourg       -0.053152   0.077148 256.613088
## Treatment_bisMixt_smart:RegionLuxembourg   0.285749   0.099412 262.097512
##                                          t value Pr(>|t|)    
## (Intercept)                               57.963  < 2e-16 ***
## Treatment_bisFull                          0.502  0.61636    
## Treatment_bisSmart                        -0.567  0.57120    
## Treatment_bisMixt_smart                    0.336  0.73735    
## SexMale                                   -0.224  0.82328    
## SpeciesOP                                -11.108  6.1e-13 ***
## RegionLuxembourg                           1.321  0.19365    
## SexMale:SpeciesOP                         -1.157  0.24813    
## SpeciesOP:RegionLuxembourg                -1.277  0.21224    
## Treatment_bisFull:SpeciesOP               -0.538  0.59097    
## Treatment_bisSmart:SpeciesOP               1.696  0.09103 .  
## Treatment_bisFull:SexMale                  0.412  0.68058    
## Treatment_bisSmart:SexMale                 0.070  0.94460    
## Treatment_bisMixt_smart:SexMale           -1.862  0.06376 .  
## Treatment_bisFull:RegionLuxembourg         0.879  0.38034    
## Treatment_bisSmart:RegionLuxembourg       -0.689  0.49147    
## Treatment_bisMixt_smart:RegionLuxembourg   2.874  0.00438 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 17 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
qqnorm(resid(LM_Total_eaten))
qqline(resid(LM_Total_eaten))

C’est très bon.

Homogénité des variances

plot(LM_Total_eaten)

c’est correcte

Distance de cook

plot(cooks.distance(LM_Total_eaten))

4.9.2 Simplification du modèle

drop1(LM_Total_eaten)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Total_eaten) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region
##                        Sum Sq  Mean Sq NumDF   DenDF F value  Pr(>F)  
## Sex:Species           0.06426 0.064261     1 262.129  1.3398 0.24813  
## Species:Region        0.07818 0.078178     1  27.897  1.6299 0.21224  
## Treatment_bis:Species 0.20958 0.104789     2 258.694  2.1847 0.11458  
## Treatment_bis:Sex     0.22396 0.074653     3 263.066  1.5564 0.20038  
## Treatment_bis:Region  0.51971 0.173237     3 258.456  3.6118 0.01387 *
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Total_eaten1 <- update(LM_Total_eaten, . ~ . - Species:Region)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
drop1(LM_Total_eaten1)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Total_eaten) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region
##                        Sum Sq  Mean Sq NumDF  DenDF F value   Pr(>F)   
## Sex:Species           0.06473 0.064729     1 261.97  1.3489 0.246523   
## Treatment_bis:Species 0.19891 0.099456     2 259.09  2.0726 0.127938   
## Treatment_bis:Sex     0.22640 0.075466     3 262.89  1.5727 0.196369   
## Treatment_bis:Region  0.55805 0.186017     3 260.58  3.8765 0.009752 **
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Total_eaten2 <- update(LM_Total_eaten1, . ~ . - Treatment_bis:Sex)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
drop1(LM_Total_eaten2)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Total_eaten) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Treatment_bis:Species + Treatment_bis:Region
##                        Sum Sq  Mean Sq NumDF  DenDF F value  Pr(>F)  
## Sex:Species           0.01721 0.017207     1 264.67  0.3565 0.55095  
## Treatment_bis:Species 0.20780 0.103899     2 261.82  2.1528 0.11822  
## Treatment_bis:Region  0.53729 0.179098     3 263.53  3.7108 0.01214 *
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Total_eaten3 <- update(LM_Total_eaten2, . ~ . - Treatment_bis:Species)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Total_eaten3)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Total_eaten) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Treatment_bis:Region
##                       Sum Sq  Mean Sq NumDF  DenDF F value  Pr(>F)  
## Sex:Species          0.02175 0.021749     1 266.54  0.4458 0.50493  
## Treatment_bis:Region 0.51887 0.172958     3 265.60  3.5450 0.01512 *
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Total_eaten4 <- update(LM_Total_eaten3, . ~ . - Sex:Species)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Total_eaten4)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Total_eaten) ~ Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region
##                       Sum Sq Mean Sq NumDF   DenDF  F value  Pr(>F)    
## Sex                   0.1604  0.1604     1 268.211   3.3010 0.07035 .  
## Species              15.6461 15.6461     1  29.051 321.9056 < 2e-16 ***
## Treatment_bis:Region  0.5259  0.1753     3 266.479   3.6068 0.01393 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

On arrête la simplification de modèle.

Est-ce qu’elle a été utile ?

AIC(LM_Total_eaten4)
## [1] 71.16486
AIC(LM_Total_eaten)
## [1] 97.17414

Oui, elle a été utile.

LM_Total_eaten <- LM_Total_eaten4

4.9.3 Treatment VS Treatment_bis

AIC(lmer(log(Total_eaten) ~ Treatment_bis + Sex + Species + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data))
## boundary (singular) fit: see help('isSingular')
## [1] 71.16486
AIC(lmer(log(Total_eaten) ~ Treatment + Sex + Species + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment:Region, data = Data))
## boundary (singular) fit: see help('isSingular')
## [1] 71.2323
summary(lmer(log(Total_eaten) ~ Treatment_bis + Sex + Species + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data))$coeff
## boundary (singular) fit: see help('isSingular')
##                                              Estimate Std. Error        df
## (Intercept)                               4.153477797 0.06162099  42.75638
## Treatment_bisFull                         0.026942383 0.04139184 263.71600
## Treatment_bisSmart                        0.001836929 0.05562459 263.48985
## Treatment_bisMixt_smart                  -0.057136020 0.06589460 268.02789
## SexMale                                  -0.048291898 0.02657985 268.21073
## SpeciesOP                                -1.341061221 0.07474538  29.05099
## RegionLuxembourg                          0.057172203 0.07819417  43.35920
## Treatment_bisFull:RegionLuxembourg        0.048278571 0.06070793 264.98118
## Treatment_bisSmart:RegionLuxembourg      -0.037782694 0.07703579 264.33955
## Treatment_bisMixt_smart:RegionLuxembourg  0.296840489 0.09922843 274.18593
##                                               t value     Pr(>|t|)
## (Intercept)                               67.40361965 4.773598e-45
## Treatment_bisFull                          0.65091055 5.156710e-01
## Treatment_bisSmart                         0.03302369 9.736807e-01
## Treatment_bisMixt_smart                   -0.86708199 3.866727e-01
## SexMale                                   -1.81686101 7.035444e-02
## SpeciesOP                                -17.94172764 2.925529e-17
## RegionLuxembourg                           0.73115685 4.686164e-01
## Treatment_bisFull:RegionLuxembourg         0.79525965 4.271742e-01
## Treatment_bisSmart:RegionLuxembourg       -0.49045637 6.242179e-01
## Treatment_bisMixt_smart:RegionLuxembourg   2.99148627 3.028778e-03
summary(lmer(log(Total_eaten) ~ Treatment + Sex + Species + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment:Region, data = Data))$coeff
## boundary (singular) fit: see help('isSingular')
##                                     Estimate Std. Error        df     t value
## (Intercept)                      4.179562911 0.06209529  39.21607  67.3088600
## TreatmentFull                    0.002713428 0.04393433 264.59305   0.0617610
## TreatmentSmart                  -0.065998225 0.04431099 266.81199  -1.4894324
## SexMale                         -0.044336781 0.02697193 268.84668  -1.6438119
## SpeciesOP                       -1.355694902 0.07366708  28.20778 -18.4029960
## RegionLuxembourg                 0.033581997 0.07999868  49.27363   0.4197819
## TreatmentFull:RegionLuxembourg   0.075263856 0.06518564 265.68145   1.1546079
## TreatmentSmart:RegionLuxembourg  0.112034388 0.06481134 266.03931   1.7286233
##                                     Pr(>|t|)
## (Intercept)                     3.852278e-42
## TreatmentFull                   9.507998e-01
## TreatmentSmart                  1.375546e-01
## SexMale                         1.013839e-01
## SpeciesOP                       2.986756e-17
## RegionLuxembourg                6.764696e-01
## TreatmentFull:RegionLuxembourg  2.492885e-01
## TreatmentSmart:RegionLuxembourg 8.503673e-02

Au vu des summary et de l’AIC je préfère le modèle avec Treatment_bis

Analyse des P-val

summary(lmer(log(Total_eaten) ~ Treatment_bis + Sex + Species + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Total_eaten) ~ Treatment_bis + Sex + Species + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data
## 
## REML criterion at convergence: 43.2
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.3680 -0.7088 -0.0252  0.5633  4.0709 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.03747  0.1936  
##  Site     (Intercept) 0.00000  0.0000  
##  Room     (Intercept) 0.00000  0.0000  
##  Residual             0.04860  0.2205  
## Number of obs: 304, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                                4.153478   0.061621  42.756384
## Treatment_bisFull                          0.026942   0.041392 263.716002
## Treatment_bisSmart                         0.001837   0.055625 263.489850
## Treatment_bisMixt_smart                   -0.057136   0.065895 268.027894
## SexMale                                   -0.048292   0.026580 268.210731
## SpeciesOP                                 -1.341061   0.074745  29.050986
## RegionLuxembourg                           0.057172   0.078194  43.359200
## Treatment_bisFull:RegionLuxembourg         0.048279   0.060708 264.981179
## Treatment_bisSmart:RegionLuxembourg       -0.037783   0.077036 264.339547
## Treatment_bisMixt_smart:RegionLuxembourg   0.296840   0.099228 274.185928
##                                          t value Pr(>|t|)    
## (Intercept)                               67.404  < 2e-16 ***
## Treatment_bisFull                          0.651  0.51567    
## Treatment_bisSmart                         0.033  0.97368    
## Treatment_bisMixt_smart                   -0.867  0.38667    
## SexMale                                   -1.817  0.07035 .  
## SpeciesOP                                -17.942  < 2e-16 ***
## RegionLuxembourg                           0.731  0.46862    
## Treatment_bisFull:RegionLuxembourg         0.795  0.42717    
## Treatment_bisSmart:RegionLuxembourg       -0.490  0.62422    
## Treatment_bisMixt_smart:RegionLuxembourg   2.991  0.00303 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal SpcsOP RgnLxm T_F:RL T_S:RL
## Trtmnt_bsFl -0.294                                                        
## Trtmnt_bsSm -0.244  0.343                                                 
## Trtmnt_bsM_ -0.241  0.321  0.261                                          
## SexMale     -0.162 -0.086  0.008 -0.029                                   
## SpeciesOP   -0.441  0.019  0.040  0.074  0.002                            
## ReginLxmbrg -0.610  0.236  0.177  0.168 -0.008 -0.007                     
## Trtmnt_F:RL  0.203 -0.679 -0.234 -0.218  0.027 -0.008 -0.357              
## Trtmnt_S:RL  0.169 -0.246 -0.721 -0.187 -0.023 -0.006 -0.298  0.372       
## Trtmn_M_:RL  0.140 -0.209 -0.171 -0.658 -0.021  0.011 -0.261  0.320  0.268
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Total_eaten) ~ Treatment_bis + Sex + Species + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_ref_full))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Total_eaten) ~ Treatment_bis + Sex + Species + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_ref_full
## 
## REML criterion at convergence: 43.2
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.3680 -0.7088 -0.0252  0.5633  4.0709 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.03747  0.1936  
##  Site     (Intercept) 0.00000  0.0000  
##  Room     (Intercept) 0.00000  0.0000  
##  Residual             0.04860  0.2205  
## Number of obs: 304, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                           Estimate Std. Error        df t value
## (Intercept)                                4.18042    0.06333  46.80351  66.012
## Treatment_bisDark                         -0.02694    0.04139 263.71600  -0.651
## Treatment_bisSmart                        -0.02511    0.05680 261.26579  -0.442
## Treatment_bisMixt_smart                   -0.08408    0.06560 263.83927  -1.282
## SexMale                                   -0.04829    0.02658 268.21073  -1.817
## SpeciesOP                                 -1.34106    0.07475  29.05099 -17.942
## RegionLuxembourg                           0.10545    0.08006  47.12933   1.317
## Treatment_bisDark:RegionLuxembourg        -0.04828    0.06071 264.98118  -0.795
## Treatment_bisSmart:RegionLuxembourg       -0.08606    0.07839 262.85878  -1.098
## Treatment_bisMixt_smart:RegionLuxembourg   0.24856    0.09839 269.34321   2.526
##                                          Pr(>|t|)    
## (Intercept)                                <2e-16 ***
## Treatment_bisDark                          0.5157    
## Treatment_bisSmart                         0.6589    
## Treatment_bisMixt_smart                    0.2011    
## SexMale                                    0.0704 .  
## SpeciesOP                                  <2e-16 ***
## RegionLuxembourg                           0.1942    
## Treatment_bisDark:RegionLuxembourg         0.4272    
## Treatment_bisSmart:RegionLuxembourg        0.2733    
## Treatment_bisMixt_smart:RegionLuxembourg   0.0121 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S Trt_M_ SexMal SpcsOP RgnLxm T_D:RL T_S:RL
## Trtmnt_bsDr -0.367                                                        
## Trtmnt_bsSm -0.281  0.392                                                 
## Trtmnt_bsM_ -0.257  0.308  0.270                                          
## SexMale     -0.214  0.086  0.070  0.025                                   
## SpeciesOP   -0.416 -0.019  0.025  0.062  0.002                            
## ReginLxmbrg -0.615  0.284  0.203  0.178  0.012 -0.013                     
## Trtmnt_D:RL  0.246 -0.679 -0.266 -0.210 -0.027  0.008 -0.410              
## Trtmnt_S:RL  0.194 -0.284 -0.724 -0.194 -0.043  0.000 -0.327  0.409       
## Trtmn_M_:RL  0.152 -0.209 -0.180 -0.664 -0.038  0.016 -0.265  0.295  0.269
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Total_eaten) ~ Treatment_bis + Sex + Species + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_ref_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Total_eaten) ~ Treatment_bis + Sex + Species + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_ref_smart
## 
## REML criterion at convergence: 43.2
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.3680 -0.7088 -0.0252  0.5633  4.0709 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.03747  0.1936  
##  Site     (Intercept) 0.00000  0.0000  
##  Room     (Intercept) 0.00000  0.0000  
##  Residual             0.04860  0.2205  
## Number of obs: 304, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                                4.155315   0.072226  76.123886
## Treatment_bisDark                         -0.001837   0.055625 263.489850
## Treatment_bisFull                          0.025105   0.056799 261.265795
## Treatment_bisMixt_smart                   -0.058973   0.074297 262.138708
## SexMale                                   -0.048292   0.026580 268.210731
## SpeciesOP                                 -1.341061   0.074745  29.050986
## RegionLuxembourg                           0.019390   0.091948  79.727756
## Treatment_bisDark:RegionLuxembourg         0.037783   0.077036 264.339547
## Treatment_bisFull:RegionLuxembourg         0.086061   0.078388 262.858779
## Treatment_bisMixt_smart:RegionLuxembourg   0.334623   0.108067 267.149739
##                                          t value Pr(>|t|)    
## (Intercept)                               57.532  < 2e-16 ***
## Treatment_bisDark                         -0.033  0.97368    
## Treatment_bisFull                          0.442  0.65885    
## Treatment_bisMixt_smart                   -0.794  0.42806    
## SexMale                                   -1.817  0.07035 .  
## SpeciesOP                                -17.942  < 2e-16 ***
## RegionLuxembourg                           0.211  0.83352    
## Treatment_bisDark:RegionLuxembourg         0.490  0.62422    
## Treatment_bisFull:RegionLuxembourg         1.098  0.27326    
## Treatment_bisMixt_smart:RegionLuxembourg   3.096  0.00217 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trt_M_ SexMal SpcsOP RgnLxm T_D:RL T_F:RL
## Trtmnt_bsDr -0.562                                                        
## Trtmnt_bsFl -0.540  0.729                                                 
## Trtmnt_bsM_ -0.425  0.517  0.526                                          
## SexMale     -0.133 -0.008 -0.070 -0.032                                   
## SpeciesOP   -0.346 -0.040 -0.025  0.036  0.002                            
## ReginLxmbrg -0.671  0.453  0.440  0.328 -0.026 -0.011                     
## Trtmnt_D:RL  0.411 -0.721 -0.527 -0.375  0.023  0.006 -0.584              
## Trtmnt_F:RL  0.399 -0.528 -0.724 -0.382  0.043  0.000 -0.568  0.695       
## Trtmn_M_:RL  0.282 -0.357 -0.361 -0.685 -0.003  0.015 -0.414  0.466  0.481
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
Info_Total_eaten <- "
Aucun traitement n'a d'effet significatif.
Les chenilles mangent significativement plus dans le traitement Mixt_smart quand elles viennent du luxembourg que quand elles viennent du brabant.
L'espèce OP mange moins que l'espèce AE
Les mangent presquent significativement (P = 0.0659) moins que les femelles.
"
Info_Total_eaten
## [1] "\nAucun traitement n'a d'effet significatif.\nLes chenilles mangent significativement plus dans le traitement Mixt_smart quand elles viennent du luxembourg que quand elles viennent du brabant.\nL'espèce OP mange moins que l'espèce AE\nLes mangent presquent significativement (P = 0.0659) moins que les femelles.\n"

4.9.4 Visualisation

Summary_Total_eaten <- Data %>% 
  filter(Sex != "NA") %>% 
  group_by(Treatment_bis, Species, Sex) %>% 
  summarise(Mean=mean(log(Total_eaten)),
            Var=var(log(Total_eaten)),
            N=n()) %>% 
  mutate(CI_S=Mean+qt(0.975, N-1)*sqrt(Var/N),
         CI_I=Mean-qt(0.975, N-1)*sqrt(Var/N))
ggplot(Summary_Total_eaten, aes(x=Treatment_bis, y=Mean, color = Species))+
  geom_errorbar(aes(ymin=CI_I, ymax=CI_S),width=0.2,size = 1.2, alpha = 0.5) +
  geom_point(alpha = 0.8) +
  facet_wrap(~Sex) +
  labs(title = "Quantité mangée", x = "Traitement", y = "log(Quantitée mangée (morceaux de feuilles))", color = "Species") +
  theme_bw()

Summary_Total_eaten2 <- Data %>% 
  filter(Sex != "NA") %>% 
  group_by(Treatment_bis, Species, Region) %>% 
  summarise(Mean=mean(log(Total_eaten)),
            Var=var(log(Total_eaten)),
            N=n()) %>% 
  mutate(CI_S=Mean+qt(0.975, N-1)*sqrt(Var/N),
         CI_I=Mean-qt(0.975, N-1)*sqrt(Var/N))
ggplot(Summary_Total_eaten2, aes(x=Treatment_bis, y=Mean, color = Species))+
  geom_errorbar(aes(ymin=CI_I, ymax=CI_S),width=0.2,size = 1.2, alpha = 0.5) +
  geom_point(alpha = 0.8) +
  facet_wrap(~Region) +
  labs(title = "Total Eaten", x = "Treatment", y = "log(Total eaten)") +
  theme_bw()

4.10 Pupa_mass * TT_pupation

4.10.1 Test

LM_Pupa_mass_by_TT_pupation <- lmer(Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region + TT_pupation:Species + TT_pupation:Sex + TT_pupation:Region + TT_pupation:Treatment_bis, data = Data)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
summary(LM_Pupa_mass_by_TT_pupation)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Species + Region +  
##     (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Region:Species +  
##     Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region +  
##     TT_pupation:Species + TT_pupation:Sex + TT_pupation:Region +  
##     TT_pupation:Treatment_bis
##    Data: Data
## 
## REML criterion at convergence: -821.2
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -3.3269 -0.4150 -0.0055  0.4755  2.9868 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 3.899e-04 0.019745
##  Site     (Intercept) 3.958e-05 0.006291
##  Room     (Intercept) 0.000e+00 0.000000
##  Residual             1.525e-03 0.039049
## Number of obs: 288, groups:  Mother, 35; Site, 15; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                               1.794e-01  2.338e-02  2.274e+02
## TT_pupation                               3.294e-03  4.753e-04  2.585e+02
## Treatment_bisFull                         2.867e-03  2.893e-02  2.504e+02
## Treatment_bisSmart                        2.476e-02  4.284e-02  2.590e+02
## Treatment_bisMixt_smart                   8.283e-02  4.307e-02  2.617e+02
## SexMale                                   2.783e-03  2.598e-02  2.537e+02
## SpeciesOP                                -5.444e-02  3.332e-02  2.030e+02
## RegionLuxembourg                          8.107e-02  3.168e-02  1.894e+02
## SexMale:SpeciesOP                        -3.426e-03  1.894e-02  2.509e+02
## SpeciesOP:RegionLuxembourg               -5.911e-02  2.644e-02  7.214e+01
## Treatment_bisFull:SpeciesOP              -2.729e-03  2.239e-02  2.452e+02
## Treatment_bisSmart:SpeciesOP             -1.248e-02  2.945e-02  2.593e+02
## Treatment_bisFull:SexMale                -4.715e-03  1.128e-02  2.430e+02
## Treatment_bisSmart:SexMale               -2.113e-02  1.490e-02  2.586e+02
## Treatment_bisMixt_smart:SexMale          -4.986e-02  1.880e-02  2.537e+02
## Treatment_bisFull:RegionLuxembourg       -1.676e-03  1.134e-02  2.395e+02
## Treatment_bisSmart:RegionLuxembourg       9.368e-03  1.452e-02  2.458e+02
## Treatment_bisMixt_smart:RegionLuxembourg  2.335e-02  2.254e-02  2.553e+02
## TT_pupation:SpeciesOP                    -1.448e-03  1.721e-03  2.535e+02
## TT_pupation:SexMale                       3.473e-04  5.505e-04  2.568e+02
## TT_pupation:RegionLuxembourg             -1.821e-03  6.337e-04  2.593e+02
## TT_pupation:Treatment_bisFull             4.949e-04  6.368e-04  2.502e+02
## TT_pupation:Treatment_bisSmart           -1.904e-04  1.021e-03  2.609e+02
## TT_pupation:Treatment_bisMixt_smart      -4.068e-04  9.588e-04  2.634e+02
##                                          t value Pr(>|t|)    
## (Intercept)                                7.674 4.88e-13 ***
## TT_pupation                                6.930 3.33e-11 ***
## Treatment_bisFull                          0.099  0.92114    
## Treatment_bisSmart                         0.578  0.56376    
## Treatment_bisMixt_smart                    1.923  0.05551 .  
## SexMale                                    0.107  0.91478    
## SpeciesOP                                 -1.634  0.10384    
## RegionLuxembourg                           2.559  0.01129 *  
## SexMale:SpeciesOP                         -0.181  0.85663    
## SpeciesOP:RegionLuxembourg                -2.236  0.02846 *  
## Treatment_bisFull:SpeciesOP               -0.122  0.90310    
## Treatment_bisSmart:SpeciesOP              -0.424  0.67214    
## Treatment_bisFull:SexMale                 -0.418  0.67634    
## Treatment_bisSmart:SexMale                -1.418  0.15741    
## Treatment_bisMixt_smart:SexMale           -2.653  0.00848 ** 
## Treatment_bisFull:RegionLuxembourg        -0.148  0.88258    
## Treatment_bisSmart:RegionLuxembourg        0.645  0.51942    
## Treatment_bisMixt_smart:RegionLuxembourg   1.036  0.30136    
## TT_pupation:SpeciesOP                     -0.842  0.40085    
## TT_pupation:SexMale                        0.631  0.52864    
## TT_pupation:RegionLuxembourg              -2.873  0.00440 ** 
## TT_pupation:Treatment_bisFull              0.777  0.43781    
## TT_pupation:Treatment_bisSmart            -0.186  0.85225    
## TT_pupation:Treatment_bisMixt_smart       -0.424  0.67174    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 24 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Test des hypothèses

Normalité des réisuds

qqnorm(resid(LM_Pupa_mass_by_TT_pupation))
qqline(resid(LM_Pupa_mass_by_TT_pupation))

On doit modifier les données (comme dans Pupa_mass en fait)

LM_Pupa_mass_by_TT_pupation <- lmer(log(Pupa_mass) ~ TT_pupation + Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region + TT_pupation:Species + TT_pupation:Sex + TT_pupation:Region + TT_pupation:Treatment_bis, data = Data[-239,])
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
# Honnêtement sans trop savoir pourquoi, la ligne 239 possédait des distance de cook très élevée par rapport au reste des points, nous l'avons donc retirée) 
summary(LM_Pupa_mass_by_TT_pupation)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Pupa_mass) ~ TT_pupation + Treatment_bis + Sex + Species +  
##     Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species +  
##     Region:Species + Treatment_bis:Species + Treatment_bis:Sex +  
##     Treatment_bis:Region + TT_pupation:Species + TT_pupation:Sex +  
##     TT_pupation:Region + TT_pupation:Treatment_bis
##    Data: Data[-239, ]
## 
## REML criterion at convergence: -169.5
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -3.6546 -0.5198  0.0452  0.6318  2.3606 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0054514 0.07383 
##  Site     (Intercept) 0.0002879 0.01697 
##  Room     (Intercept) 0.0003800 0.01949 
##  Residual             0.0176782 0.13296 
## Number of obs: 287, groups:  Mother, 35; Site, 15; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                              -1.587e+00  8.141e-02  1.712e+02
## TT_pupation                               9.778e-03  1.624e-03  2.555e+02
## Treatment_bisFull                         8.045e-02  1.024e-01  2.482e+02
## Treatment_bisSmart                        1.421e-01  1.469e-01  2.569e+02
## Treatment_bisMixt_smart                   3.249e-01  1.492e-01  2.587e+02
## SexMale                                   3.605e-02  8.960e-02  2.528e+02
## SpeciesOP                                -4.404e-01  1.153e-01  2.099e+02
## RegionLuxembourg                          1.505e-01  1.114e-01  2.056e+02
## SexMale:SpeciesOP                        -2.187e-02  6.526e-02  2.510e+02
## SpeciesOP:RegionLuxembourg               -1.357e-01  9.408e-02  8.364e+01
## Treatment_bisFull:SpeciesOP              -2.142e-02  7.796e-02  2.443e+02
## Treatment_bisSmart:SpeciesOP             -6.654e-02  1.008e-01  2.567e+02
## Treatment_bisFull:SexMale                -3.039e-02  3.855e-02  2.432e+02
## Treatment_bisSmart:SexMale               -5.646e-02  5.108e-02  2.576e+02
## Treatment_bisMixt_smart:SexMale          -1.475e-01  6.430e-02  2.521e+02
## Treatment_bisFull:RegionLuxembourg       -2.538e-02  3.869e-02  2.400e+02
## Treatment_bisSmart:RegionLuxembourg       1.734e-02  4.951e-02  2.450e+02
## Treatment_bisMixt_smart:RegionLuxembourg  3.646e-02  7.702e-02  2.536e+02
## TT_pupation:SpeciesOP                    -1.219e-03  5.919e-03  2.563e+02
## TT_pupation:SexMale                       6.251e-04  1.915e-03  2.563e+02
## TT_pupation:RegionLuxembourg             -2.723e-03  2.252e-03  2.623e+02
## TT_pupation:Treatment_bisFull            -4.661e-05  2.271e-03  2.471e+02
## TT_pupation:Treatment_bisSmart           -1.739e-03  3.496e-03  2.580e+02
## TT_pupation:Treatment_bisMixt_smart      -3.240e-03  3.328e-03  2.612e+02
##                                          t value Pr(>|t|)    
## (Intercept)                              -19.490  < 2e-16 ***
## TT_pupation                                6.019 6.05e-09 ***
## Treatment_bisFull                          0.786 0.432709    
## Treatment_bisSmart                         0.967 0.334204    
## Treatment_bisMixt_smart                    2.177 0.030348 *  
## SexMale                                    0.402 0.687776    
## SpeciesOP                                 -3.819 0.000176 ***
## RegionLuxembourg                           1.350 0.178402    
## SexMale:SpeciesOP                         -0.335 0.737831    
## SpeciesOP:RegionLuxembourg                -1.442 0.153030    
## Treatment_bisFull:SpeciesOP               -0.275 0.783733    
## Treatment_bisSmart:SpeciesOP              -0.660 0.509683    
## Treatment_bisFull:SexMale                 -0.788 0.431236    
## Treatment_bisSmart:SexMale                -1.105 0.270043    
## Treatment_bisMixt_smart:SexMale           -2.293 0.022648 *  
## Treatment_bisFull:RegionLuxembourg        -0.656 0.512568    
## Treatment_bisSmart:RegionLuxembourg        0.350 0.726503    
## Treatment_bisMixt_smart:RegionLuxembourg   0.473 0.636326    
## TT_pupation:SpeciesOP                     -0.206 0.836945    
## TT_pupation:SexMale                        0.326 0.744356    
## TT_pupation:RegionLuxembourg              -1.209 0.227852    
## TT_pupation:Treatment_bisFull             -0.021 0.983645    
## TT_pupation:Treatment_bisSmart            -0.497 0.619355    
## TT_pupation:Treatment_bisMixt_smart       -0.973 0.331265    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 24 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
qqnorm(resid(LM_Pupa_mass_by_TT_pupation))
qqline(resid(LM_Pupa_mass_by_TT_pupation))

Homogénité des variances

plot(LM_Pupa_mass_by_TT_pupation)

Distance de cook

plot(cooks.distance(LM_Pupa_mass_by_TT_pupation))

4.10.2 Simplification du modèle

drop1(LM_Pupa_mass_by_TT_pupation)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Pupa_mass) ~ TT_pupation + Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region + TT_pupation:Species + TT_pupation:Sex + TT_pupation:Region + TT_pupation:Treatment_bis
##                             Sum Sq  Mean Sq NumDF   DenDF F value Pr(>F)
## Sex:Species               0.001985 0.001985     1 250.962  0.1123 0.7378
## Species:Region            0.036761 0.036761     1  83.642  2.0794 0.1530
## Treatment_bis:Species     0.007894 0.003947     2 251.745  0.2233 0.8000
## Treatment_bis:Sex         0.097729 0.032576     3 250.714  1.8427 0.1399
## Treatment_bis:Region      0.020074 0.006691     3 246.020  0.3785 0.7686
## TT_pupation:Species       0.000750 0.000750     1 256.293  0.0424 0.8369
## TT_pupation:Sex           0.001884 0.001884     1 256.266  0.1066 0.7444
## TT_pupation:Region        0.025829 0.025829     1 262.299  1.4610 0.2279
## TT_pupation:Treatment_bis 0.019920 0.006640     3 256.153  0.3756 0.7707
LM_Pupa_mass_by_TT_pupation1 <- update(LM_Pupa_mass_by_TT_pupation, . ~ . - Treatment_bis:Species)
drop1(LM_Pupa_mass_by_TT_pupation1)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Pupa_mass) ~ TT_pupation + Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Species:Region + Treatment_bis:Sex + Treatment_bis:Region + TT_pupation:Species + TT_pupation:Sex + TT_pupation:Region + TT_pupation:Treatment_bis
##                             Sum Sq  Mean Sq NumDF   DenDF F value Pr(>F)
## Sex:Species               0.001443 0.001443     1 251.532  0.0821 0.7747
## Species:Region            0.043063 0.043063     1  81.936  2.4513 0.1213
## Treatment_bis:Sex         0.097602 0.032534     3 252.475  1.8519 0.1383
## Treatment_bis:Region      0.020266 0.006755     3 247.619  0.3845 0.7642
## TT_pupation:Species       0.001072 0.001072     1 256.998  0.0610 0.8051
## TT_pupation:Sex           0.003093 0.003093     1 255.639  0.1761 0.6751
## TT_pupation:Region        0.031108 0.031108     1 263.844  1.7708 0.1844
## TT_pupation:Treatment_bis 0.018195 0.006065     3 253.321  0.3452 0.7926
LM_Pupa_mass_by_TT_pupation2 <- update(LM_Pupa_mass_by_TT_pupation1, . ~ . - Sex:Species)
drop1(LM_Pupa_mass_by_TT_pupation2)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Pupa_mass) ~ TT_pupation + Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region + Treatment_bis:Sex + Treatment_bis:Region + TT_pupation:Species + TT_pupation:Sex + TT_pupation:Region + TT_pupation:Treatment_bis
##                             Sum Sq  Mean Sq NumDF   DenDF F value Pr(>F)
## Species:Region            0.044235 0.044235     1  82.113  2.5267 0.1158
## Treatment_bis:Sex         0.096293 0.032098     3 253.896  1.8334 0.1415
## Treatment_bis:Region      0.019830 0.006610     3 248.511  0.3776 0.7693
## TT_pupation:Species       0.000903 0.000903     1 256.864  0.0516 0.8205
## TT_pupation:Sex           0.024855 0.024855     1 253.429  1.4197 0.2346
## TT_pupation:Region        0.033297 0.033297     1 265.257  1.9019 0.1690
## TT_pupation:Treatment_bis 0.017084 0.005695     3 254.057  0.3253 0.8071
LM_Pupa_mass_by_TT_pupation3 <- update(LM_Pupa_mass_by_TT_pupation2, . ~ . - TT_pupation:Treatment_bis)
drop1(LM_Pupa_mass_by_TT_pupation3)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Pupa_mass) ~ TT_pupation + Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region + Treatment_bis:Sex + Treatment_bis:Region + TT_pupation:Species + TT_pupation:Sex + TT_pupation:Region
##                        Sum Sq  Mean Sq NumDF   DenDF F value  Pr(>F)  
## Species:Region       0.056247 0.056247     1  77.793  3.2391 0.07578 .
## Treatment_bis:Sex    0.088611 0.029537     3 256.477  1.7009 0.16727  
## Treatment_bis:Region 0.012252 0.004084     3 250.230  0.2352 0.87180  
## TT_pupation:Species  0.000361 0.000361     1 259.452  0.0208 0.88549  
## TT_pupation:Sex      0.037050 0.037050     1 253.799  2.1336 0.14534  
## TT_pupation:Region   0.048337 0.048337     1 268.287  2.7836 0.09640 .
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Pupa_mass_by_TT_pupation4 <- update(LM_Pupa_mass_by_TT_pupation3, . ~ . - Treatment_bis:Region)
drop1(LM_Pupa_mass_by_TT_pupation4)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Pupa_mass) ~ TT_pupation + Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region + Treatment_bis:Sex + TT_pupation:Species + TT_pupation:Sex + TT_pupation:Region
##                       Sum Sq  Mean Sq NumDF   DenDF F value  Pr(>F)  
## Species:Region      0.064527 0.064527     1  75.041  3.7545 0.05643 .
## Treatment_bis:Sex   0.091127 0.030376     3 259.237  1.7674 0.15380  
## TT_pupation:Species 0.000201 0.000201     1 260.379  0.0117 0.91400  
## TT_pupation:Sex     0.037723 0.037723     1 257.457  2.1949 0.13969  
## TT_pupation:Region  0.058942 0.058942     1 271.293  3.4295 0.06513 .
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Pupa_mass_by_TT_pupation5 <- update(LM_Pupa_mass_by_TT_pupation4, . ~ . - TT_pupation:Species)
drop1(LM_Pupa_mass_by_TT_pupation5)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Pupa_mass) ~ TT_pupation + Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region + Treatment_bis:Sex + TT_pupation:Sex + TT_pupation:Region
##                      Sum Sq  Mean Sq NumDF   DenDF F value  Pr(>F)  
## Species:Region     0.065196 0.065196     1  75.514  3.8071 0.05474 .
## Treatment_bis:Sex  0.091469 0.030490     3 259.817  1.7804 0.15128  
## TT_pupation:Sex    0.037526 0.037526     1 257.804  2.1914 0.14001  
## TT_pupation:Region 0.059161 0.059161     1 272.314  3.4547 0.06415 .
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Pupa_mass_by_TT_pupation6 <- update(LM_Pupa_mass_by_TT_pupation5, . ~ . - TT_pupation:Sex)
drop1(LM_Pupa_mass_by_TT_pupation6)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Pupa_mass) ~ TT_pupation + Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region + Treatment_bis:Sex + TT_pupation:Region
##                      Sum Sq  Mean Sq NumDF  DenDF F value  Pr(>F)  
## Species:Region     0.056033 0.056033     1  74.33  3.2595 0.07506 .
## Treatment_bis:Sex  0.064650 0.021550     3 260.87  1.2536 0.29082  
## TT_pupation:Region 0.043988 0.043988     1 273.20  2.5588 0.11084  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Pupa_mass_by_TT_pupation7 <- update(LM_Pupa_mass_by_TT_pupation6, . ~ . - Treatment_bis:Sex)
drop1(LM_Pupa_mass_by_TT_pupation7)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Pupa_mass) ~ TT_pupation + Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region + TT_pupation:Region
##                      Sum Sq  Mean Sq NumDF   DenDF F value   Pr(>F)   
## Treatment_bis      0.263460 0.087820     3 179.730  5.0593 0.002181 **
## Sex                0.015079 0.015079     1 262.846  0.8687 0.352165   
## Species:Region     0.052682 0.052682     1  78.211  3.0350 0.085419 . 
## TT_pupation:Region 0.039184 0.039184     1 276.350  2.2574 0.134119   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Il n’y a plus d’interactions qui n’ont pas de P-val proche de 0.05, nous décidons d’arrêter la simplification du modèle.

Est ce que cela a été utile

AIC(LM_Pupa_mass_by_TT_pupation7)
## [1] -222.0473
AIC(LM_Pupa_mass_by_TT_pupation)
## [1] -113.4576

Oui ca a été utile

LM_Pupa_mass_by_TT_pupation <- LM_Pupa_mass_by_TT_pupation7

4.10.3 Treatment VS Teatment_bis

AIC(lmer(log(Pupa_mass) ~ TT_pupation + Treatment_bis + Sex + Species +  Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region +  TT_pupation:Region, data = Data[-239, ]))
## [1] -222.0473
AIC(lmer(log(Pupa_mass) ~ TT_pupation + Treatment + Sex + Species +  Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region +  TT_pupation:Region, data = Data[-239, ]))
## [1] -228.6703
summary(lmer(log(Pupa_mass) ~ TT_pupation + Treatment_bis + Sex + Species +  Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region +  TT_pupation:Region, data = Data[-239, ]))$coeff
##                                  Estimate  Std. Error        df     t value
## (Intercept)                  -1.547771401 0.064737203  97.97408 -23.9085308
## TT_pupation                   0.009558839 0.001293654 271.80224   7.3890239
## Treatment_bisFull             0.043837913 0.018740127 256.16154   2.3392538
## Treatment_bisSmart            0.045327051 0.025261519 192.00066   1.7943122
## Treatment_bisMixt_smart       0.113047807 0.031811171 213.66832   3.5537141
## SexMale                       0.015146918 0.016251137 262.84560   0.9320528
## SpeciesOP                    -0.494393265 0.056804500  62.78089  -8.7034173
## RegionLuxembourg              0.157038324 0.093896862 199.90792   1.6724555
## SpeciesOP:RegionLuxembourg   -0.148618061 0.085308846  78.21129  -1.7421178
## TT_pupation:RegionLuxembourg -0.002853817 0.001899422 276.35014  -1.5024660
##                                  Pr(>|t|)
## (Intercept)                  1.120606e-42
## TT_pupation                  1.825583e-12
## Treatment_bisFull            2.009134e-02
## Treatment_bisSmart           7.433663e-02
## Treatment_bisMixt_smart      4.674550e-04
## SexMale                      3.521645e-01
## SpeciesOP                    2.175405e-12
## RegionLuxembourg             9.599884e-02
## SpeciesOP:RegionLuxembourg   8.541896e-02
## TT_pupation:RegionLuxembourg 1.341186e-01
summary(lmer(log(Pupa_mass) ~ TT_pupation + Treatment + Sex + Species +  Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region +  TT_pupation:Region, data = Data[-239, ]))$coeff
##                                  Estimate  Std. Error        df    t value
## (Intercept)                  -1.550743349 0.065084697  89.78554 -23.826543
## TT_pupation                   0.009553083 0.001289698 274.37716   7.407225
## TreatmentFull                 0.053087820 0.019506369 256.49045   2.721563
## TreatmentSmart                0.074016135 0.019582554 259.89089   3.779698
## SexMale                       0.019457352 0.016211507 263.08195   1.200219
## SpeciesOP                    -0.513696512 0.056012610  60.89865  -9.171087
## RegionLuxembourg              0.124370484 0.091095223 231.10858   1.365280
## SpeciesOP:RegionLuxembourg   -0.125697749 0.084027319  77.06904  -1.495915
## TT_pupation:RegionLuxembourg -0.002184368 0.001842344 277.04849  -1.185646
##                                  Pr(>|t|)
## (Intercept)                  1.371737e-40
## TT_pupation                  1.594799e-12
## TreatmentFull                6.942490e-03
## TreatmentSmart               1.947912e-04
## SexMale                      2.311341e-01
## SpeciesOP                    4.451227e-13
## RegionLuxembourg             1.734925e-01
## SpeciesOP:RegionLuxembourg   1.387597e-01
## TT_pupation:RegionLuxembourg 2.367780e-01

L’AIC suggère de prendre Treatment mais les p-val disent que Mixt_Smart a un effet fort significatif Je vais rester avec Treatment_bis

Analyse des pval

summary(lmer(log(Pupa_mass) ~ TT_pupation + Treatment_bis + Sex + Species +  Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region +  TT_pupation:Region, data = Data[-239, ]))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Pupa_mass) ~ TT_pupation + Treatment_bis + Sex + Species +  
##     Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region +  
##     TT_pupation:Region
##    Data: Data[-239, ]
## 
## REML criterion at convergence: -250
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -3.6241 -0.5310  0.0713  0.5905  2.4619 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0051734 0.07193 
##  Site     (Intercept) 0.0001168 0.01081 
##  Room     (Intercept) 0.0004170 0.02042 
##  Residual             0.0173582 0.13175 
## Number of obs: 287, groups:  Mother, 35; Site, 15; Room, 2
## 
## Fixed effects:
##                                Estimate Std. Error         df t value Pr(>|t|)
## (Intercept)                   -1.547771   0.064737  97.974081 -23.909  < 2e-16
## TT_pupation                    0.009559   0.001294 271.802239   7.389 1.83e-12
## Treatment_bisFull              0.043838   0.018740 256.161545   2.339 0.020091
## Treatment_bisSmart             0.045327   0.025262 192.000658   1.794 0.074337
## Treatment_bisMixt_smart        0.113048   0.031811 213.668324   3.554 0.000467
## SexMale                        0.015147   0.016251 262.845603   0.932 0.352165
## SpeciesOP                     -0.494393   0.056804  62.780890  -8.703 2.18e-12
## RegionLuxembourg               0.157038   0.093897 199.907918   1.672 0.095999
## SpeciesOP:RegionLuxembourg    -0.148618   0.085309  78.211290  -1.742 0.085419
## TT_pupation:RegionLuxembourg  -0.002854   0.001899 276.350138  -1.502 0.134119
##                                 
## (Intercept)                  ***
## TT_pupation                  ***
## Treatment_bisFull            *  
## Treatment_bisSmart           .  
## Treatment_bisMixt_smart      ***
## SexMale                         
## SpeciesOP                    ***
## RegionLuxembourg             .  
## SpeciesOP:RegionLuxembourg   .  
## TT_pupation:RegionLuxembourg    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TT_ppt Trtm_F Trtm_S Trt_M_ SexMal SpcsOP RgnLxm SOP:RL
## TT_pupation -0.860                                                        
## Trtmnt_bsFl -0.183  0.055                                                 
## Trtmnt_bsSm -0.164  0.062  0.358                                          
## Trtmnt_bsM_ -0.197  0.092  0.311  0.140                                   
## SexMale     -0.122  0.027 -0.083  0.011 -0.039                            
## SpeciesOP   -0.748  0.633  0.067  0.079  0.157  0.014                     
## ReginLxmbrg -0.633  0.585  0.080 -0.087  0.199  0.055  0.511              
## SpcsOP:RgnL  0.501 -0.420 -0.069  0.048 -0.149 -0.048 -0.666 -0.792       
## TT_pptn:RgL  0.608 -0.689 -0.082  0.071 -0.223 -0.064 -0.448 -0.911  0.670
summary(lmer(log(Pupa_mass) ~ TT_pupation + Treatment_bis + Sex + Species +  Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region +  TT_pupation:Region, data = Data_ref_full[-239, ]))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Pupa_mass) ~ TT_pupation + Treatment_bis + Sex + Species +  
##     Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region +  
##     TT_pupation:Region
##    Data: Data_ref_full[-239, ]
## 
## REML criterion at convergence: -250
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -3.6241 -0.5310  0.0713  0.5905  2.4619 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0051734 0.07193 
##  Site     (Intercept) 0.0001168 0.01081 
##  Room     (Intercept) 0.0004170 0.02042 
##  Residual             0.0173582 0.13175 
## Number of obs: 287, groups:  Mother, 35; Site, 15; Room, 2
## 
## Fixed effects:
##                                Estimate Std. Error         df t value Pr(>|t|)
## (Intercept)                   -1.503933   0.064015  94.547793 -23.494  < 2e-16
## TT_pupation                    0.009559   0.001294 271.802240   7.389 1.83e-12
## Treatment_bisDark             -0.043838   0.018740 256.161545  -2.339   0.0201
## Treatment_bisSmart             0.001489   0.025511 211.071795   0.058   0.9535
## Treatment_bisMixt_smart        0.069210   0.031501 195.364408   2.197   0.0292
## SexMale                        0.015147   0.016251 262.845603   0.932   0.3522
## SpeciesOP                     -0.494393   0.056804  62.780890  -8.703 2.18e-12
## RegionLuxembourg               0.157038   0.093897 199.907914   1.672   0.0960
## SpeciesOP:RegionLuxembourg    -0.148618   0.085309  78.211290  -1.742   0.0854
## TT_pupation:RegionLuxembourg  -0.002854   0.001899 276.350137  -1.502   0.1341
##                                 
## (Intercept)                  ***
## TT_pupation                  ***
## Treatment_bisDark            *  
## Treatment_bisSmart              
## Treatment_bisMixt_smart      *  
## SexMale                         
## SpeciesOP                    ***
## RegionLuxembourg             .  
## SpeciesOP:RegionLuxembourg   .  
## TT_pupation:RegionLuxembourg    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TT_ppt Trtm_D Trtm_S Trt_M_ SexMal SpcsOP RgnLxm SOP:RL
## TT_pupation -0.853                                                        
## Trtmnt_bsDr -0.108 -0.055                                                 
## Trtmnt_bsSm -0.139  0.021  0.381                                          
## Trtmnt_bsM_ -0.173  0.060  0.281  0.136                                   
## SexMale     -0.148  0.027  0.083  0.072  0.010                            
## SpeciesOP   -0.737  0.633 -0.067  0.029  0.119  0.014                     
## ReginLxmbrg -0.617  0.585 -0.080 -0.144  0.154  0.055  0.511              
## SpcsOP:RgnL  0.486 -0.420  0.069  0.098 -0.110 -0.048 -0.666 -0.792       
## TT_pptn:RgL  0.591 -0.689  0.082  0.130 -0.177 -0.064 -0.448 -0.911  0.670
summary(lmer(log(Pupa_mass) ~ TT_pupation + Treatment_bis + Sex + Species +  Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region +  TT_pupation:Region, data = Data_ref_smart[-239, ]))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Pupa_mass) ~ TT_pupation + Treatment_bis + Sex + Species +  
##     Region + (1 | Mother) + (1 | Site) + (1 | Room) + Species:Region +  
##     TT_pupation:Region
##    Data: Data_ref_smart[-239, ]
## 
## REML criterion at convergence: -250
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -3.6241 -0.5310  0.0713  0.5905  2.4619 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0051734 0.07193 
##  Site     (Intercept) 0.0001168 0.01081 
##  Room     (Intercept) 0.0004170 0.02042 
##  Residual             0.0173582 0.13175 
## Number of obs: 287, groups:  Mother, 35; Site, 15; Room, 2
## 
## Fixed effects:
##                                Estimate Std. Error         df t value Pr(>|t|)
## (Intercept)                   -1.502444   0.065528  90.683165 -22.928  < 2e-16
## TT_pupation                    0.009559   0.001294 271.802245   7.389 1.83e-12
## Treatment_bisDark             -0.045327   0.025262 192.000658  -1.794   0.0743
## Treatment_bisFull             -0.001489   0.025511 211.071795  -0.058   0.9535
## Treatment_bisMixt_smart        0.067721   0.037746  97.773751   1.794   0.0759
## SexMale                        0.015147   0.016251 262.845604   0.932   0.3522
## SpeciesOP                     -0.494393   0.056804  62.780890  -8.703 2.18e-12
## RegionLuxembourg               0.157038   0.093897 199.907920   1.672   0.0960
## SpeciesOP:RegionLuxembourg    -0.148618   0.085309  78.211291  -1.742   0.0854
## TT_pupation:RegionLuxembourg  -0.002854   0.001899 276.350138  -1.502   0.1341
##                                 
## (Intercept)                  ***
## TT_pupation                  ***
## Treatment_bisDark            .  
## Treatment_bisFull               
## Treatment_bisMixt_smart      .  
## SexMale                         
## SpeciesOP                    ***
## RegionLuxembourg             .  
## SpeciesOP:RegionLuxembourg   .  
## TT_pupation:RegionLuxembourg    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TT_ppt Trtm_D Trtm_F Trt_M_ SexMal SpcsOP RgnLxm SOP:RL
## TT_pupation -0.825                                                        
## Trtmnt_bsDr -0.224 -0.062                                                 
## Trtmnt_bsFl -0.253 -0.021  0.728                                          
## Trtmnt_bsM_ -0.268  0.036  0.551  0.562                                   
## SexMale     -0.116  0.027 -0.011 -0.072 -0.040                            
## SpeciesOP   -0.709  0.633 -0.079 -0.029  0.080  0.014                     
## ReginLxmbrg -0.659  0.585  0.087  0.144  0.226  0.055  0.511              
## SpcsOP:RgnL  0.513 -0.420 -0.048 -0.098 -0.158 -0.048 -0.666 -0.792       
## TT_pptn:RgL  0.628 -0.689 -0.071 -0.130 -0.236 -0.064 -0.448 -0.911  0.670
Info_Pupa_mass_by_TT_pupation <- "
Au plus le temps pour entrer en chrysalide est élevé, au plus la chrysalide sera lourde.
ordre de croissance de masse : Dark < Full et Smart (les deux sont très simillaires) < Mixt_smart
OP est plus légère
Les chrysalides provenants de la région Luxembourg sont quasiment significativement (pval = 0.065) plus lourde.
L'impacte de la région Luxembourg est presque significativement différent (pval = 0.068) en fonction de l'espèce (OP plus légère)
L'impacte du temps avant d'atteindre la chrysalide est quasiment significativement différent fonction de la région d'ou vient la chenille (luxembourgeoise plus légère pour un même temps d'atteinte de chrysalide)
"
Info_Pupa_mass_by_TT_pupation
## [1] "\nAu plus le temps pour entrer en chrysalide est élevé, au plus la chrysalide sera lourde.\nordre de croissance de masse : Dark < Full et Smart (les deux sont très simillaires) < Mixt_smart\nOP est plus légère\nLes chrysalides provenants de la région Luxembourg sont quasiment significativement (pval = 0.065) plus lourde.\nL'impacte de la région Luxembourg est presque significativement différent (pval = 0.068) en fonction de l'espèce (OP plus légère)\nL'impacte du temps avant d'atteindre la chrysalide est quasiment significativement différent fonction de la région d'ou vient la chenille (luxembourgeoise plus légère pour un même temps d'atteinte de chrysalide)\n"

4.10.4 Visualisation

ggplot(data = Data[-239,], aes(x = TT_pupation, y = Pupa_mass)) +
  geom_point(aes(color = Treatment_bis, shape = Species)) +
  geom_smooth(method = "lm", aes(linetype = Species)) +
  labs(title = "Masse des chrysalides en fonction du temps passé pour entrer en chrysalide", x = "Temps pour entrer en chrysalide (jours)", y = "Poids des chrysalides (g)", color = "Traitement", linetype = "Espèce", shape = "Espèce") +
  theme_bw()
## `geom_smooth()` using formula = 'y ~ x'
## Warning: Removed 158 rows containing non-finite values (`stat_smooth()`).
## Warning: Removed 158 rows containing missing values (`geom_point()`).

ggplot(data = Data[-239,], aes(x = TT_pupation, y = log(Pupa_mass))) +
  geom_point(aes(color = Treatment_bis, shape = Species)) +
  geom_smooth(method = "lm", aes(color= Treatment_bis, linetype = Species)) +
  facet_wrap(~Region) +
  labs(title = "Pupa Mass by Time to pupa", x = "Time to pupation", y = "log(Pupa_mass)") +
  theme_bw()
## `geom_smooth()` using formula = 'y ~ x'
## Warning: Removed 158 rows containing non-finite values (`stat_smooth()`).
## Warning: Removed 158 rows containing missing values (`geom_point()`).

4.11 Mass_by_Time

Dévelloppement du jeux de données

Data_mass <- Data[,1:31] %>% pivot_longer(cols = M0:M20, names_to = "Numéro_de_masse", values_to = "Mass")
Data_mass$Time <- rep(0:20, length.out = nrow(Data_mass))
Data_mass_ref_smart <- Data_mass
Data_mass_ref_smart$Treatment <- relevel(Data_mass$Treatment, ref = "Smart")
Data_mass_ref_smart$Treatment_bis <- relevel(Data_mass$Treatment_bis, ref = "Smart")

Data_mass_ref_full <- Data_mass
Data_mass_ref_full$Treatment <- relevel(Data_mass$Treatment, ref = "Full")
Data_mass_ref_full$Treatment_bis <- relevel(Data_mass$Treatment_bis, ref = "Full")

4.11.1 Test

LM_mass_by_time <- lmer(Mass ~ Time + Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region + Time:Species + Time:Sex + Time:Region + Time:Treatment_bis, data = Data_mass)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
summary(LM_mass_by_time)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Mass ~ Time + Treatment_bis + Sex + Species + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Sex:Species + Region:Species +  
##     Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region +  
##     Time:Species + Time:Sex + Time:Region + Time:Treatment_bis
##    Data: Data_mass
## 
## REML criterion at convergence: -1873.8
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -4.0175 -0.5296 -0.1481  0.3834  4.4012 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.001171 0.03422 
##  Site     (Intercept) 0.000000 0.00000 
##  Room     (Intercept) 0.000000 0.00000 
##  Residual             0.019175 0.13847 
## Number of obs: 1863, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                               2.428e-02  1.710e-02  1.245e+02
## Time                                      5.480e-02  2.146e-03  1.836e+03
## Treatment_bisFull                        -2.017e-02  1.759e-02  1.839e+03
## Treatment_bisSmart                       -8.095e-02  2.227e-02  1.837e+03
## Treatment_bisMixt_smart                  -3.022e-02  2.182e-02  1.839e+03
## SexMale                                  -2.664e-02  1.607e-02  1.832e+03
## SpeciesOP                                 3.325e-02  2.694e-02  8.059e+01
## RegionLuxembourg                         -6.650e-03  2.131e-02  7.580e+01
## SexMale:SpeciesOP                         2.400e-02  1.940e-02  1.839e+03
## SpeciesOP:RegionLuxembourg                4.669e-03  3.163e-02  3.937e+01
## Treatment_bisFull:SpeciesOP               3.754e-02  2.154e-02  1.832e+03
## Treatment_bisSmart:SpeciesOP              4.433e-03  2.858e-02  1.838e+03
## Treatment_bisFull:SexMale                -4.356e-03  1.633e-02  1.822e+03
## Treatment_bisSmart:SexMale               -8.969e-03  2.146e-02  1.725e+03
## Treatment_bisMixt_smart:SexMale           1.046e-02  2.178e-02  1.775e+03
## Treatment_bisFull:RegionLuxembourg       -2.995e-02  1.630e-02  1.823e+03
## Treatment_bisSmart:RegionLuxembourg       7.347e-02  2.007e-02  1.838e+03
## Treatment_bisMixt_smart:RegionLuxembourg -4.617e-02  2.138e-02  1.809e+03
## Time:SpeciesOP                            6.469e-02  1.034e-02  1.829e+03
## Time:SexMale                              5.026e-03  2.188e-03  1.823e+03
## Time:RegionLuxembourg                    -6.661e-03  2.251e-03  1.838e+03
## Time:Treatment_bisFull                    1.249e-02  2.601e-03  1.830e+03
## Time:Treatment_bisSmart                   2.782e-02  3.730e-03  1.824e+03
## Time:Treatment_bisMixt_smart              1.744e-02  3.163e-03  1.822e+03
##                                          t value Pr(>|t|)    
## (Intercept)                                1.420 0.158191    
## Time                                      25.539  < 2e-16 ***
## Treatment_bisFull                         -1.146 0.251820    
## Treatment_bisSmart                        -3.635 0.000286 ***
## Treatment_bisMixt_smart                   -1.385 0.166227    
## SexMale                                   -1.657 0.097604 .  
## SpeciesOP                                  1.235 0.220579    
## RegionLuxembourg                          -0.312 0.755882    
## SexMale:SpeciesOP                          1.237 0.216189    
## SpeciesOP:RegionLuxembourg                 0.148 0.883382    
## Treatment_bisFull:SpeciesOP                1.743 0.081502 .  
## Treatment_bisSmart:SpeciesOP               0.155 0.876744    
## Treatment_bisFull:SexMale                 -0.267 0.789701    
## Treatment_bisSmart:SexMale                -0.418 0.676009    
## Treatment_bisMixt_smart:SexMale            0.480 0.631071    
## Treatment_bisFull:RegionLuxembourg        -1.838 0.066250 .  
## Treatment_bisSmart:RegionLuxembourg        3.660 0.000260 ***
## Treatment_bisMixt_smart:RegionLuxembourg  -2.159 0.030969 *  
## Time:SpeciesOP                             6.256 4.91e-10 ***
## Time:SexMale                               2.297 0.021729 *  
## Time:RegionLuxembourg                     -2.959 0.003123 ** 
## Time:Treatment_bisFull                     4.804 1.68e-06 ***
## Time:Treatment_bisSmart                    7.459 1.34e-13 ***
## Time:Treatment_bisMixt_smart               5.513 4.04e-08 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 24 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Vérification des hypothèses

qqnorm(resid(LM_mass_by_time))
qqline(resid(LM_mass_by_time))

Il faudrait modifier les données

LM_mass_by_time <- lmer(log(Mass) ~ sqrt(Time) + Treatment_bis + Sex + Species + Region + (1|Mother) + (1|Site) + (1|Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region + Time:Species + Time:Sex + Time:Region + Time:Treatment_bis, data = Data_mass)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
#summary(LM_mass_by_time)
qqnorm(resid(LM_mass_by_time))
qqline(resid(LM_mass_by_time))

Homogénité des variances

plot(LM_mass_by_time)

Distance de cook

plot(cooks.distance(LM_mass_by_time))

On pourrait retirer quelques outlier mais cela semle bon

4.11.2 Simplification du modèle

drop1(LM_mass_by_time)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Mass) ~ sqrt(Time) + Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Region:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region + Time:Species + Time:Sex + Time:Region + Time:Treatment_bis
##                       Sum Sq Mean Sq NumDF   DenDF   F value    Pr(>F)    
## sqrt(Time)            388.31  388.31     1 1808.32 1447.1310 < 2.2e-16 ***
## Sex:Species             0.45    0.45     1 1829.32    1.6611   0.19762    
## Species:Region          0.03    0.03     1   33.41    0.1274   0.72337    
## Treatment_bis:Species   1.44    0.72     2 1827.60    2.6822   0.06868 .  
## Treatment_bis:Sex       1.08    0.36     3 1833.87    1.3365   0.26080    
## Treatment_bis:Region   14.63    4.88     3 1828.35   18.1705 1.281e-11 ***
## Species:Time          523.11  261.56     2 1813.45  974.7464 < 2.2e-16 ***
## Sex:Time                0.52    0.52     1 1810.94    1.9561   0.16211    
## Region:Time             0.06    0.06     1 1821.25    0.2160   0.64215    
## Treatment_bis:Time     12.73    4.24     3 1811.10   15.8120 3.762e-10 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_mass_by_time1 <- update(LM_mass_by_time, . ~ . - Species:Region)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
drop1(LM_mass_by_time1)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Mass) ~ sqrt(Time) + Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region + Species:Time + Sex:Time + Region:Time + Treatment_bis:Time
##                       Sum Sq Mean Sq NumDF  DenDF   F value    Pr(>F)    
## sqrt(Time)            388.36  388.36     1 1809.6 1447.4462 < 2.2e-16 ***
## Sex:Species             0.45    0.45     1 1830.0    1.6661   0.19695    
## Treatment_bis:Species   1.44    0.72     2 1830.0    2.6782   0.06896 .  
## Treatment_bis:Sex       1.08    0.36     3 1834.8    1.3361   0.26091    
## Treatment_bis:Region   14.62    4.87     3 1829.8   18.1613 1.298e-11 ***
## Species:Time          523.11  261.56     2 1814.3  974.8424 < 2.2e-16 ***
## Sex:Time                0.53    0.53     1 1811.6    1.9599   0.16169    
## Region:Time             0.08    0.08     1 1801.5    0.2904   0.59006    
## Treatment_bis:Time     12.77    4.26     3 1813.1   15.8641 3.491e-10 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_mass_by_time2 <- update(LM_mass_by_time1, . ~ . - Region:Time)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
drop1(LM_mass_by_time2)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Mass) ~ sqrt(Time) + Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Treatment_bis:Species + Treatment_bis:Sex + Treatment_bis:Region + Species:Time + Sex:Time + Treatment_bis:Time
##                       Sum Sq Mean Sq NumDF  DenDF   F value    Pr(>F)    
## sqrt(Time)            393.59  393.59     1 1809.7 1467.5926 < 2.2e-16 ***
## Sex:Species             0.44    0.44     1 1830.9    1.6462   0.19964    
## Treatment_bis:Species   1.41    0.71     2 1830.9    2.6325   0.07217 .  
## Treatment_bis:Sex       1.11    0.37     3 1835.7    1.3779   0.24776    
## Treatment_bis:Region   14.88    4.96     3 1831.1   18.4954 8.047e-12 ***
## Species:Time          528.46  264.23     2 1814.9  985.2394 < 2.2e-16 ***
## Sex:Time                0.50    0.50     1 1812.5    1.8585   0.17297    
## Treatment_bis:Time     12.69    4.23     3 1813.0   15.7734 3.975e-10 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_mass_by_time3 <- update(LM_mass_by_time2, . ~ . - Treatment_bis:Sex)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
drop1(LM_mass_by_time3)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Mass) ~ sqrt(Time) + Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Species + Treatment_bis:Species + Treatment_bis:Region + Species:Time + Sex:Time + Treatment_bis:Time
##                       Sum Sq Mean Sq NumDF  DenDF   F value    Pr(>F)    
## sqrt(Time)            394.21  394.21     1 1812.9 1468.5471 < 2.2e-16 ***
## Sex:Species             0.30    0.30     1 1832.1    1.1291   0.28811    
## Treatment_bis:Species   1.54    0.77     2 1833.5    2.8731   0.05678 .  
## Treatment_bis:Region   14.50    4.83     3 1833.8   18.0059 1.620e-11 ***
## Species:Time          529.01  264.51     2 1818.1  985.3598 < 2.2e-16 ***
## Sex:Time                0.57    0.57     1 1816.1    2.1394   0.14373    
## Treatment_bis:Time     12.54    4.18     3 1816.2   15.5681 5.331e-10 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_mass_by_time4 <- update(LM_mass_by_time3, . ~ . - Sex:Species)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
drop1(LM_mass_by_time4)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Mass) ~ sqrt(Time) + Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Species + Treatment_bis:Region + Species:Time + Sex:Time + Treatment_bis:Time
##                       Sum Sq Mean Sq NumDF  DenDF   F value    Pr(>F)    
## sqrt(Time)            394.41  394.41     1 1813.9 1469.3043 < 2.2e-16 ***
## Treatment_bis:Species   1.65    0.83     2 1834.1    3.0767   0.04635 *  
## Treatment_bis:Region   14.62    4.87     3 1834.6   18.1498 1.318e-11 ***
## Species:Time          528.91  264.45     2 1819.0  985.1865 < 2.2e-16 ***
## Sex:Time                0.34    0.34     1 1823.5    1.2534   0.26305    
## Treatment_bis:Time     12.50    4.17     3 1817.3   15.5213 5.700e-10 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_mass_by_time5 <- update(LM_mass_by_time4, . ~ . - Sex:Time)
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
drop1(LM_mass_by_time5)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Mass) ~ sqrt(Time) + Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Species + Treatment_bis:Region + Species:Time + Treatment_bis:Time
##                       Sum Sq Mean Sq NumDF  DenDF   F value    Pr(>F)    
## sqrt(Time)            395.39  395.39     1 1814.8 1472.5616 < 2.2e-16 ***
## Sex                     0.03    0.03     1 1844.8    0.1214   0.72760    
## Treatment_bis:Species   1.68    0.84     2 1835.1    3.1275   0.04406 *  
## Treatment_bis:Region   14.65    4.88     3 1835.7   18.1881 1.248e-11 ***
## Species:Time          530.24  265.12     2 1820.0  987.4125 < 2.2e-16 ***
## Treatment_bis:Time     12.36    4.12     3 1818.2   15.3499 7.284e-10 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_mass_by_time6 <- update(LM_mass_by_time5, . ~ . - Treatment_bis:Species)
## boundary (singular) fit: see help('isSingular')
drop1(LM_mass_by_time6)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Mass) ~ sqrt(Time) + Treatment_bis + Sex + Species + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region + Species:Time + Treatment_bis:Time
##                      Sum Sq Mean Sq NumDF  DenDF   F value    Pr(>F)    
## sqrt(Time)           395.60  395.60     1 1816.5 1470.3721 < 2.2e-16 ***
## Sex                    0.03    0.03     1 1846.7    0.1111     0.739    
## Treatment_bis:Region  14.22    4.74     3 1837.4   17.6237 2.798e-11 ***
## Species:Time          27.00   13.50     2 1827.4   50.1861 < 2.2e-16 ***
## Treatment_bis:Time    15.26    5.09     3 1824.4   18.9102 4.453e-12 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Plus aucune interaction ne peut être retirée, on arrête la simplification ici.

A-t-elle été utile ?

AIC(LM_mass_by_time6)
## [1] 3026.15
AIC(LM_mass_by_time)
## [1] 3068.17

Oui

LM_mass_by_time <- LM_mass_by_time6

4.11.3 Treatment VS Teatment_bis

AIC(lmer(log(Mass) ~ sqrt(Time) + Treatment_bis + Sex + Species + Region +  (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Species:Time + Treatment_bis:Time, data = Data_mass))
## boundary (singular) fit: see help('isSingular')
## [1] 3026.15
AIC(lmer(log(Mass) ~ sqrt(Time) + Treatment + Sex + Species + Region +  (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Species:Time + Treatment:Time, data = Data_mass))
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
## [1] 3035.473
summary(lmer(log(Mass) ~ sqrt(Time) + Treatment_bis + Sex + Species + Region +  (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Species:Time + Treatment_bis:Time, data = Data_mass))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Mass) ~ sqrt(Time) + Treatment_bis + Sex + Species + Region +  
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  
##     Species:Time + Treatment_bis:Time
##    Data: Data_mass
## 
## REML criterion at convergence: 2986.1
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -4.5577 -0.6370  0.0238  0.7028  2.4030 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.04871  0.2207  
##  Site     (Intercept) 0.00000  0.0000  
##  Room     (Intercept) 0.00000  0.0000  
##  Residual             0.26905  0.5187  
## Number of obs: 1863, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                              -4.589e+00  7.752e-02  7.049e+01
## sqrt(Time)                                1.648e+00  4.297e-02  1.817e+03
## Treatment_bisFull                        -2.681e-02  5.089e-02  1.835e+03
## Treatment_bisSmart                       -3.438e-01  6.988e-02  1.831e+03
## Treatment_bisMixt_smart                  -2.860e-04  7.135e-02  1.834e+03
## SexMale                                  -8.582e-03  2.575e-02  1.847e+03
## SpeciesOP                                 1.301e+00  9.684e-02  5.280e+01
## RegionLuxembourg                         -1.871e-01  8.523e-02  4.018e+01
## Treatment_bisFull:RegionLuxembourg       -8.154e-02  6.130e-02  1.845e+03
## Treatment_bisSmart:RegionLuxembourg       3.997e-01  7.474e-02  1.837e+03
## Treatment_bisMixt_smart:RegionLuxembourg -1.824e-01  8.044e-02  1.846e+03
## SpeciesAE:Time                           -1.104e-01  1.262e-02  1.827e+03
## SpeciesOP:Time                           -5.760e-02  5.038e-02  1.825e+03
## Treatment_bisFull:Time                    2.627e-02  8.552e-03  1.832e+03
## Treatment_bisSmart:Time                   9.477e-02  1.296e-02  1.826e+03
## Treatment_bisMixt_smart:Time              3.932e-02  1.147e-02  1.821e+03
##                                          t value Pr(>|t|)    
## (Intercept)                              -59.196  < 2e-16 ***
## sqrt(Time)                                38.345  < 2e-16 ***
## Treatment_bisFull                         -0.527 0.598402    
## Treatment_bisSmart                        -4.920 9.44e-07 ***
## Treatment_bisMixt_smart                   -0.004 0.996802    
## SexMale                                   -0.333 0.738977    
## SpeciesOP                                 13.433  < 2e-16 ***
## RegionLuxembourg                          -2.195 0.034023 *  
## Treatment_bisFull:RegionLuxembourg        -1.330 0.183608    
## Treatment_bisSmart:RegionLuxembourg        5.347 1.00e-07 ***
## Treatment_bisMixt_smart:RegionLuxembourg  -2.267 0.023496 *  
## SpeciesAE:Time                            -8.744  < 2e-16 ***
## SpeciesOP:Time                            -1.143 0.253072    
## Treatment_bisFull:Time                     3.072 0.002160 ** 
## Treatment_bisSmart:Time                    7.310 3.97e-13 ***
## Treatment_bisMixt_smart:Time               3.427 0.000623 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 16 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Mass) ~ sqrt(Time) + Treatment + Sex + Species + Region +  (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Species:Time + Treatment:Time, data = Data_mass))
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Mass) ~ sqrt(Time) + Treatment + Sex + Species + Region +  
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  
##     Species:Time + Treatment:Time
##    Data: Data_mass
## 
## REML criterion at convergence: 2995.5
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -4.5774 -0.6274  0.0307  0.6941  2.6562 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 4.854e-02 0.220307
##  Site     (Intercept) 0.000e+00 0.000000
##  Room     (Intercept) 6.679e-05 0.008172
##  Residual             2.709e-01 0.520485
## Number of obs: 1863, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                              -4.582e+00  7.810e-02  6.236e+01
## sqrt(Time)                                1.661e+00  4.296e-02  1.815e+03
## TreatmentFull                            -1.246e-01  5.725e-02  1.834e+03
## TreatmentSmart                           -1.397e-01  7.714e-02  4.376e+02
## SexMale                                  -9.992e-03  2.587e-02  1.844e+03
## SpeciesOP                                 1.313e+00  9.748e-02  5.427e+01
## RegionLuxembourg                         -1.867e-01  8.521e-02  4.015e+01
## RegionBrabant:Treatment_bisFull           8.317e-02  6.156e-02  1.845e+03
## RegionBrabant:Treatment_bisSmart         -9.974e-02  9.043e-02  8.647e+01
## RegionLuxembourg:Treatment_bisSmart       2.798e-01  8.852e-02  1.129e+02
## RegionBrabant:Treatment_bisMixt_smart     3.370e-02  9.322e-02  1.828e+03
## RegionLuxembourg:Treatment_bisMixt_smart -1.801e-01  9.667e-02  1.839e+03
## SpeciesAE:Time                           -1.157e-01  1.263e-02  1.826e+03
## SpeciesOP:Time                           -7.683e-02  5.049e-02  1.824e+03
## TreatmentFull:Time                        2.780e-02  8.719e-03  1.825e+03
## TreatmentSmart:Time                       6.339e-02  9.612e-03  1.825e+03
##                                          t value Pr(>|t|)    
## (Intercept)                              -58.670  < 2e-16 ***
## sqrt(Time)                                38.663  < 2e-16 ***
## TreatmentFull                             -2.176  0.02968 *  
## TreatmentSmart                            -1.811  0.07082 .  
## SexMale                                   -0.386  0.69940    
## SpeciesOP                                 13.466  < 2e-16 ***
## RegionLuxembourg                          -2.191  0.03433 *  
## RegionBrabant:Treatment_bisFull            1.351  0.17684    
## RegionBrabant:Treatment_bisSmart          -1.103  0.27310    
## RegionLuxembourg:Treatment_bisSmart        3.161  0.00202 ** 
## RegionBrabant:Treatment_bisMixt_smart      0.362  0.71771    
## RegionLuxembourg:Treatment_bisMixt_smart  -1.863  0.06261 .  
## SpeciesAE:Time                            -9.161  < 2e-16 ***
## SpeciesOP:Time                            -1.522  0.12825    
## TreatmentFull:Time                         3.189  0.00145 ** 
## TreatmentSmart:Time                        6.595 5.56e-11 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 16 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

On a des p-val plus intéressentes avec le treatment mais treatment_bis montre des effets différents pour smart et mixt_smart. Si je me base sur les AIC je continue avec treatment_bis

Analyse des P-val

summary(lmer(log(Mass) ~ sqrt(Time) + Treatment_bis + Sex + Species + Region +  (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Species:Time + Treatment_bis:Time, data = Data_mass))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Mass) ~ sqrt(Time) + Treatment_bis + Sex + Species + Region +  
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  
##     Species:Time + Treatment_bis:Time
##    Data: Data_mass
## 
## REML criterion at convergence: 2986.1
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -4.5577 -0.6370  0.0238  0.7028  2.4030 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.04871  0.2207  
##  Site     (Intercept) 0.00000  0.0000  
##  Room     (Intercept) 0.00000  0.0000  
##  Residual             0.26905  0.5187  
## Number of obs: 1863, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                              -4.589e+00  7.752e-02  7.049e+01
## sqrt(Time)                                1.648e+00  4.297e-02  1.817e+03
## Treatment_bisFull                        -2.681e-02  5.089e-02  1.835e+03
## Treatment_bisSmart                       -3.438e-01  6.988e-02  1.831e+03
## Treatment_bisMixt_smart                  -2.860e-04  7.135e-02  1.834e+03
## SexMale                                  -8.582e-03  2.575e-02  1.847e+03
## SpeciesOP                                 1.301e+00  9.684e-02  5.280e+01
## RegionLuxembourg                         -1.871e-01  8.523e-02  4.018e+01
## Treatment_bisFull:RegionLuxembourg       -8.154e-02  6.130e-02  1.845e+03
## Treatment_bisSmart:RegionLuxembourg       3.997e-01  7.474e-02  1.837e+03
## Treatment_bisMixt_smart:RegionLuxembourg -1.824e-01  8.044e-02  1.846e+03
## SpeciesAE:Time                           -1.104e-01  1.262e-02  1.827e+03
## SpeciesOP:Time                           -5.760e-02  5.038e-02  1.825e+03
## Treatment_bisFull:Time                    2.627e-02  8.552e-03  1.832e+03
## Treatment_bisSmart:Time                   9.477e-02  1.296e-02  1.826e+03
## Treatment_bisMixt_smart:Time              3.932e-02  1.147e-02  1.821e+03
##                                          t value Pr(>|t|)    
## (Intercept)                              -59.196  < 2e-16 ***
## sqrt(Time)                                38.345  < 2e-16 ***
## Treatment_bisFull                         -0.527 0.598402    
## Treatment_bisSmart                        -4.920 9.44e-07 ***
## Treatment_bisMixt_smart                   -0.004 0.996802    
## SexMale                                   -0.333 0.738977    
## SpeciesOP                                 13.433  < 2e-16 ***
## RegionLuxembourg                          -2.195 0.034023 *  
## Treatment_bisFull:RegionLuxembourg        -1.330 0.183608    
## Treatment_bisSmart:RegionLuxembourg        5.347 1.00e-07 ***
## Treatment_bisMixt_smart:RegionLuxembourg  -2.267 0.023496 *  
## SpeciesAE:Time                            -8.744  < 2e-16 ***
## SpeciesOP:Time                            -1.143 0.253072    
## Treatment_bisFull:Time                     3.072 0.002160 ** 
## Treatment_bisSmart:Time                    7.310 3.97e-13 ***
## Treatment_bisMixt_smart:Time               3.427 0.000623 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 16 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Mass) ~ sqrt(Time) + Treatment_bis + Sex + Species + Region +  (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Species:Time + Treatment_bis:Time, data = Data_mass_ref_full))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Mass) ~ sqrt(Time) + Treatment_bis + Sex + Species + Region +  
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  
##     Species:Time + Treatment_bis:Time
##    Data: Data_mass_ref_full
## 
## REML criterion at convergence: 2986.1
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -4.5577 -0.6370  0.0238  0.7028  2.4030 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.04871  0.2207  
##  Site     (Intercept) 0.00000  0.0000  
##  Room     (Intercept) 0.00000  0.0000  
##  Residual             0.26905  0.5187  
## Number of obs: 1863, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                              -4.616e+00  7.862e-02  7.404e+01
## sqrt(Time)                                1.648e+00  4.297e-02  1.817e+03
## Treatment_bisDark                         2.681e-02  5.089e-02  1.835e+03
## Treatment_bisSmart                       -3.170e-01  7.047e-02  1.822e+03
## Treatment_bisMixt_smart                   2.652e-02  7.072e-02  1.822e+03
## SexMale                                  -8.582e-03  2.575e-02  1.847e+03
## SpeciesOP                                 1.301e+00  9.684e-02  5.280e+01
## RegionLuxembourg                         -2.686e-01  8.721e-02  4.378e+01
## Treatment_bisDark:RegionLuxembourg        8.154e-02  6.130e-02  1.845e+03
## Treatment_bisSmart:RegionLuxembourg       4.812e-01  7.536e-02  1.827e+03
## Treatment_bisMixt_smart:RegionLuxembourg -1.008e-01  7.915e-02  1.841e+03
## SpeciesAE:Time                           -8.410e-02  1.321e-02  1.822e+03
## SpeciesOP:Time                           -3.133e-02  5.071e-02  1.825e+03
## Treatment_bisDark:Time                   -2.627e-02  8.552e-03  1.832e+03
## Treatment_bisSmart:Time                   6.850e-02  1.320e-02  1.823e+03
## Treatment_bisMixt_smart:Time              1.305e-02  1.179e-02  1.819e+03
##                                          t value Pr(>|t|)    
## (Intercept)                              -58.709  < 2e-16 ***
## sqrt(Time)                                38.345  < 2e-16 ***
## Treatment_bisDark                          0.527  0.59840    
## Treatment_bisSmart                        -4.498 7.29e-06 ***
## Treatment_bisMixt_smart                    0.375  0.70765    
## SexMale                                   -0.333  0.73898    
## SpeciesOP                                 13.433  < 2e-16 ***
## RegionLuxembourg                          -3.080  0.00357 ** 
## Treatment_bisDark:RegionLuxembourg         1.330  0.18361    
## Treatment_bisSmart:RegionLuxembourg        6.385 2.17e-10 ***
## Treatment_bisMixt_smart:RegionLuxembourg  -1.274  0.20283    
## SpeciesAE:Time                            -6.369 2.41e-10 ***
## SpeciesOP:Time                            -0.618  0.53675    
## Treatment_bisDark:Time                    -3.072  0.00216 ** 
## Treatment_bisSmart:Time                    5.190 2.34e-07 ***
## Treatment_bisMixt_smart:Time               1.107  0.26841    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 16 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Mass) ~ sqrt(Time) + Treatment_bis + Sex + Species + Region +  (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Species:Time + Treatment_bis:Time, data = Data_mass_ref_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Mass) ~ sqrt(Time) + Treatment_bis + Sex + Species + Region +  
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  
##     Species:Time + Treatment_bis:Time
##    Data: Data_mass_ref_smart
## 
## REML criterion at convergence: 2986.1
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -4.5577 -0.6370  0.0238  0.7028  2.4030 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.04871  0.2207  
##  Site     (Intercept) 0.00000  0.0000  
##  Room     (Intercept) 0.00000  0.0000  
##  Residual             0.26905  0.5187  
## Number of obs: 1863, groups:  Mother, 36; Site, 15; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                              -4.933e+00  8.970e-02  1.225e+02
## sqrt(Time)                                1.648e+00  4.297e-02  1.817e+03
## Treatment_bisDark                         3.438e-01  6.988e-02  1.831e+03
## Treatment_bisFull                         3.170e-01  7.047e-02  1.822e+03
## Treatment_bisMixt_smart                   3.435e-01  8.511e-02  1.821e+03
## SexMale                                  -8.582e-03  2.575e-02  1.847e+03
## SpeciesOP                                 1.301e+00  9.684e-02  5.280e+01
## RegionLuxembourg                          2.126e-01  9.742e-02  6.774e+01
## Treatment_bisDark:RegionLuxembourg       -3.997e-01  7.474e-02  1.837e+03
## Treatment_bisFull:RegionLuxembourg       -4.812e-01  7.536e-02  1.827e+03
## Treatment_bisMixt_smart:RegionLuxembourg -5.821e-01  9.070e-02  1.838e+03
## SpeciesAE:Time                           -1.561e-02  1.750e-02  1.824e+03
## SpeciesOP:Time                            3.717e-02  5.267e-02  1.825e+03
## Treatment_bisDark:Time                   -9.477e-02  1.296e-02  1.826e+03
## Treatment_bisFull:Time                   -6.850e-02  1.320e-02  1.823e+03
## Treatment_bisMixt_smart:Time             -5.545e-02  1.516e-02  1.819e+03
##                                          t value Pr(>|t|)    
## (Intercept)                              -54.990  < 2e-16 ***
## sqrt(Time)                                38.345  < 2e-16 ***
## Treatment_bisDark                          4.920 9.44e-07 ***
## Treatment_bisFull                          4.498 7.29e-06 ***
## Treatment_bisMixt_smart                    4.036 5.67e-05 ***
## SexMale                                   -0.333 0.738977    
## SpeciesOP                                 13.433  < 2e-16 ***
## RegionLuxembourg                           2.182 0.032556 *  
## Treatment_bisDark:RegionLuxembourg        -5.347 1.00e-07 ***
## Treatment_bisFull:RegionLuxembourg        -6.385 2.17e-10 ***
## Treatment_bisMixt_smart:RegionLuxembourg  -6.418 1.76e-10 ***
## SpeciesAE:Time                            -0.892 0.372689    
## SpeciesOP:Time                             0.706 0.480475    
## Treatment_bisDark:Time                    -7.310 3.97e-13 ***
## Treatment_bisFull:Time                    -5.190 2.34e-07 ***
## Treatment_bisMixt_smart:Time              -3.656 0.000263 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 16 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
Info_Mass_by_Time <- "
temps a un effet significatif positif
Pour un même temps, Les smart sont significativements plus légère que les Dark
Pour un même temps, l'Espèce OP est plus lourde.
Pour un même temps, les individus de la région Luxembourg sont moins lourds
Les individus Smart réagissent différement en fonction de si ils viennent du Luxembourg ou pas (si ils viennent du Luxembourg ils sont plus lourds pour un même temps).
Idem pour Mixt_smart mais ils sont moinds lourds
L'espèce AE réagit différement que OP à l'augmentation de temps (les p val)
"
Info_Mass_by_Time
## [1] "\ntemps a un effet significatif positif\nPour un même temps, Les smart sont significativements plus légère que les Dark\nPour un même temps, l'Espèce OP est plus lourde.\nPour un même temps, les individus de la région Luxembourg sont moins lourds\nLes individus Smart réagissent différement en fonction de si ils viennent du Luxembourg ou pas (si ils viennent du Luxembourg ils sont plus lourds pour un même temps).\nIdem pour Mixt_smart mais ils sont moinds lourds\nL'espèce AE réagit différement que OP à l'augmentation de temps (les p val)\n"

4.11.4 Visualisation

ggplot(data = Data_mass, aes(x = log(Time), y = log(Mass))) +
  geom_jitter(aes(color = Treatment_bis, shape = Region), alpha = 0.33) +
  geom_smooth(method = "lm", aes(linetype = Region)) +
  facet_wrap(~Species) +
  labs(title = "Poids des individus en fonction du temps", x = "Temps (log(Numéro de mesure))", y = "log(Poids (g))", color = "Traitement", linetype = "Région", shape = "Région") +
  theme_bw()
## `geom_smooth()` using formula = 'y ~ x'
## Warning: Removed 7160 rows containing non-finite values (`stat_smooth()`).
## Warning: Removed 6710 rows containing missing values (`geom_point()`).

ggplot(data = Data_mass, aes(x = sqrt(Time), y = log(Mass))) +
  geom_point(aes(color = Treatment_bis, shape = Species), alpha = 0.5) +
  geom_smooth(method = "lm", aes(color= Treatment_bis, linetype = Species)) +
  facet_wrap(~Region) +
  labs(title = "Mass by Time", x = "Time (sqrt(Weeks)", y = "log(Mass)") +
  theme_bw()
## `geom_smooth()` using formula = 'y ~ x'
## Warning: Removed 6710 rows containing non-finite values (`stat_smooth()`).
## Warning: Removed 6710 rows containing missing values (`geom_point()`).

5 Analyses Lumière

5.1 Jeux de donnée avec références

Data_refFTL_Night <- Data
Data_refFTL_Night$Treatment_FTL <- relevel(Data$Treatment_FTL, ref = "Night")
Data_refFTL_Night$Treatment_FTL <- relevel(Data$Treatment_FTL, ref = "Night")

Data_refFTL_Mix <- Data
Data_refFTL_Mix$Treatment_FTL <- relevel(Data$Treatment_FTL, ref = "Mix")
Data_refFTL_Mix$Treatment_FTL <- relevel(Data$Treatment_FTL, ref = "Mix")

5.2 Did_move

5.2.1 Test

GLM_Did_move <- glmer(Did_move ~ Treatment_bis + Sex  + Region + Treatment_FTL + Light_orientation + (1|Mother) + (1|Site) + (1|Room)  + Treatment_bis:Sex + Treatment_bis:Region + Treatment_FTL:Sex + Treatment_FTL:Region + Treatment_FTL:Treatment_bis + Light_orientation:Sex + Light_orientation:Region + Light_orientation:Treatment_bis, family = binomial, data = Data)
summary(GLM_Did_move)
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: 
## Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex +  
##     Treatment_bis:Region + Treatment_FTL:Sex + Treatment_FTL:Region +  
##     Treatment_FTL:Treatment_bis + Light_orientation:Sex + Light_orientation:Region +  
##     Light_orientation:Treatment_bis
##    Data: Data
## 
##      AIC      BIC   logLik deviance df.resid 
##     82.8    174.3     -8.4     16.8       85 
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -1.46643  0.00000  0.00000  0.00006  0.68193 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev.
##  Mother (Intercept) 5.186e-06 0.002277
##  Site   (Intercept) 2.288e+01 4.783051
##  Room   (Intercept) 3.841e+00 1.959892
## Number of obs: 118, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                                  Estimate Std. Error z value
## (Intercept)                                    -1.245e-01  4.374e+00  -0.028
## Treatment_bisFull                               4.224e+01  1.792e+05   0.000
## Treatment_bisSmart                              2.513e+01  3.133e+04   0.001
## Treatment_bisMixt_smart                         3.993e+01  1.878e+07   0.000
## SexMale                                         2.833e+01  6.058e+04   0.000
## RegionLuxembourg                                2.899e+01  5.317e+05   0.000
## Treatment_FTLMix                                8.404e+00  4.910e+00   1.711
## Treatment_FTLNight                              2.522e+01  1.516e+04   0.002
## Light_orientationSouth                         -1.542e+00  2.623e+00  -0.588
## Treatment_bisFull:SexMale                      -1.202e+01  5.961e+04   0.000
## Treatment_bisSmart:SexMale                     -2.898e+01  6.058e+04   0.000
## Treatment_bisMixt_smart:SexMale                 6.995e+00  1.399e+05   0.000
## Treatment_bisFull:RegionLuxembourg             -3.109e+01  5.318e+05   0.000
## Treatment_bisSmart:RegionLuxembourg            -4.115e+01  5.326e+05   0.000
## Treatment_bisMixt_smart:RegionLuxembourg       -1.471e+02  1.878e+07   0.000
## SexMale:Treatment_FTLMix                       -9.663e+00  1.121e+04  -0.001
## SexMale:Treatment_FTLNight                      1.558e+01  1.643e+07   0.000
## RegionLuxembourg:Treatment_FTLMix              -6.756e+00  1.129e+04  -0.001
## RegionLuxembourg:Treatment_FTLNight             2.178e+01  2.630e+05   0.000
## Treatment_bisFull:Treatment_FTLMix             -3.151e+01  1.792e+05   0.000
## Treatment_bisSmart:Treatment_FTLMix             1.002e+01  1.268e+03   0.008
## Treatment_bisMixt_smart:Treatment_FTLMix        7.479e+01  1.616e+05   0.000
## Treatment_bisFull:Treatment_FTLNight           -4.782e+01  1.798e+05   0.000
## Treatment_bisSmart:Treatment_FTLNight          -3.107e+01  3.481e+04  -0.001
## Treatment_bisMixt_smart:Treatment_FTLNight      2.322e+01  2.943e+05   0.000
## SexMale:Light_orientationSouth                  3.548e+00  3.838e+03   0.001
## RegionLuxembourg:Light_orientationSouth         1.809e+01  3.118e+04   0.001
## Treatment_bisFull:Light_orientationSouth       -1.420e+01  2.045e+03  -0.007
## Treatment_bisSmart:Light_orientationSouth      -2.162e+01  3.133e+04  -0.001
## Treatment_bisMixt_smart:Light_orientationSouth  9.310e+00  1.050e+05   0.000
##                                                Pr(>|z|)  
## (Intercept)                                       0.977  
## Treatment_bisFull                                 1.000  
## Treatment_bisSmart                                0.999  
## Treatment_bisMixt_smart                           1.000  
## SexMale                                           1.000  
## RegionLuxembourg                                  1.000  
## Treatment_FTLMix                                  0.087 .
## Treatment_FTLNight                                0.999  
## Light_orientationSouth                            0.557  
## Treatment_bisFull:SexMale                         1.000  
## Treatment_bisSmart:SexMale                        1.000  
## Treatment_bisMixt_smart:SexMale                   1.000  
## Treatment_bisFull:RegionLuxembourg                1.000  
## Treatment_bisSmart:RegionLuxembourg               1.000  
## Treatment_bisMixt_smart:RegionLuxembourg          1.000  
## SexMale:Treatment_FTLMix                          0.999  
## SexMale:Treatment_FTLNight                        1.000  
## RegionLuxembourg:Treatment_FTLMix                 1.000  
## RegionLuxembourg:Treatment_FTLNight               1.000  
## Treatment_bisFull:Treatment_FTLMix                1.000  
## Treatment_bisSmart:Treatment_FTLMix               0.994  
## Treatment_bisMixt_smart:Treatment_FTLMix          1.000  
## Treatment_bisFull:Treatment_FTLNight              1.000  
## Treatment_bisSmart:Treatment_FTLNight             0.999  
## Treatment_bisMixt_smart:Treatment_FTLNight        1.000  
## SexMale:Light_orientationSouth                    0.999  
## RegionLuxembourg:Light_orientationSouth           1.000  
## Treatment_bisFull:Light_orientationSouth          0.994  
## Treatment_bisSmart:Light_orientationSouth         0.999  
## Treatment_bisMixt_smart:Light_orientationSouth    1.000  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## optimizer (Nelder_Mead) convergence code: 4 (failure to converge in 10000 evaluations)
## unable to evaluate scaled gradient
## Model failed to converge: degenerate  Hessian with 7 negative eigenvalues
## failure to converge in 10000 evaluations

5.2.2 Simplification du modèle

Simplification par AIC/BIC

drop1(GLM_Did_move)
## Single term deletions
## 
## Model:
## Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + 
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + 
##     Treatment_bis:Region + Treatment_FTL:Sex + Treatment_FTL:Region + 
##     Treatment_FTL:Treatment_bis + Light_orientation:Sex + Light_orientation:Region + 
##     Light_orientation:Treatment_bis
##                                 npar    AIC
## <none>                               82.840
## Treatment_bis:Sex                  3 76.836
## Treatment_bis:Region               3 84.454
## Sex:Treatment_FTL                  2 78.847
## Region:Treatment_FTL               2 78.842
## Treatment_bis:Treatment_FTL        6 75.965
## Sex:Light_orientation              1 80.851
## Region:Light_orientation           1 80.846
## Treatment_bis:Light_orientation    3 77.030
GLM_Did_move2 <- update(GLM_Did_move, . ~ . - Treatment_bis:Treatment_FTL)
drop1(GLM_Did_move2)
## Single term deletions
## 
## Model:
## Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + 
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + 
##     Treatment_bis:Region + Sex:Treatment_FTL + Region:Treatment_FTL + 
##     Sex:Light_orientation + Region:Light_orientation + Treatment_bis:Light_orientation
##                                 npar    AIC
## <none>                               75.965
## Treatment_bis:Sex                  3 69.951
## Treatment_bis:Region               3 78.097
## Sex:Treatment_FTL                  2 71.927
## Region:Treatment_FTL               2 71.961
## Sex:Light_orientation              1 73.979
## Region:Light_orientation           1 73.984
## Treatment_bis:Light_orientation    3 72.157
GLM_Did_move3 <- update(GLM_Did_move2, . ~ . - Treatment_bis:Sex)
drop1(GLM_Did_move3)
## Single term deletions
## 
## Model:
## Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + 
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region + 
##     Sex:Treatment_FTL + Region:Treatment_FTL + Sex:Light_orientation + 
##     Region:Light_orientation + Treatment_bis:Light_orientation
##                                 npar    AIC
## <none>                               69.951
## Treatment_bis:Region               3 76.656
## Sex:Treatment_FTL                  2 65.930
## Region:Treatment_FTL               2 70.348
## Sex:Light_orientation              1 67.958
## Region:Light_orientation           1 67.958
## Treatment_bis:Light_orientation    3 66.157
GLM_Did_move4 <- update(GLM_Did_move3, . ~ . - Sex:Treatment_FTL)
drop1(GLM_Did_move4)
## Single term deletions
## 
## Model:
## Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + 
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region + 
##     Region:Treatment_FTL + Sex:Light_orientation + Region:Light_orientation + 
##     Treatment_bis:Light_orientation
##                                 npar    AIC
## <none>                               65.930
## Treatment_bis:Region               3 74.694
## Region:Treatment_FTL               2 66.715
## Sex:Light_orientation              1 63.942
## Region:Light_orientation           1 63.926
## Treatment_bis:Light_orientation    3 62.157
GLM_Did_move5 <- update(GLM_Did_move4, . ~ . - Treatment_bis:Light_orientation)
drop1(GLM_Did_move5)
## Single term deletions
## 
## Model:
## Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + 
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region + 
##     Region:Treatment_FTL + Sex:Light_orientation + Region:Light_orientation
##                          npar    AIC
## <none>                        62.157
## Treatment_bis:Region        3 71.755
## Region:Treatment_FTL        2 62.432
## Sex:Light_orientation       1 60.157
## Region:Light_orientation    1 63.258

Est ce qu’il faut pas juste retirer toutes les interactions ?

BIC(glmer(Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data, family = binomial))
## [1] 100.0252
BIC(GLM_Did_move5)
## [1] 114.8
BIC(GLM_Did_move4)
## [1] 126.8855
BIC(GLM_Did_move3)
## [1] 136.4479
BIC(GLM_Did_move2)
## [1] 150.7731
BIC(GLM_Did_move)
## [1] 174.2725

Si

GLM_Did_move <- glmer(Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data, family = binomial)

5.2.3 Treatment VS Treatment_bis

AIC(glmer(Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data, family = binomial))
## [1] 66.77695
AIC(glmer(Did_move ~ Treatment + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data, family = binomial))
## [1] 65.0217
summary(glmer(Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data, family = binomial))
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: 
## Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  
##     (1 | Mother) + (1 | Site) + (1 | Room)
##    Data: Data
## 
##      AIC      BIC   logLik deviance df.resid 
##     66.8    100.0    -21.4     42.8      106 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -5.5255  0.1076  0.1483  0.2316  0.4602 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev.
##  Mother (Intercept) 5.231e-01 0.723250
##  Site   (Intercept) 1.574e-02 0.125457
##  Room   (Intercept) 5.221e-06 0.002285
## Number of obs: 118, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                         Estimate Std. Error z value Pr(>|z|)  
## (Intercept)               2.3901     1.2336   1.937   0.0527 .
## Treatment_bisFull         0.7011     1.3140   0.534   0.5936  
## Treatment_bisSmart        0.3476     1.3507   0.257   0.7969  
## Treatment_bisMixt_smart  -0.3041     1.1123  -0.273   0.7845  
## SexMale                   1.2964     1.1539   1.123   0.2612  
## RegionLuxembourg          0.3085     1.1939   0.258   0.7961  
## Treatment_FTLMix          0.4637     1.4721   0.315   0.7528  
## Treatment_FTLNight        1.3724     1.5201   0.903   0.3666  
## Light_orientationSouth   -0.6529     0.9700  -0.673   0.5009  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_FTLM T_FTLN
## Trtmnt_bsFl -0.386                                                 
## Trtmnt_bsSm -0.348  0.350                                          
## Trtmnt_bsM_ -0.358  0.416  0.412                                   
## SexMale     -0.210 -0.015  0.105  0.004                            
## ReginLxmbrg -0.261 -0.061 -0.132 -0.106 -0.047                     
## Trtmnt_FTLM -0.078  0.166  0.151  0.083  0.032 -0.448              
## Trtmnt_FTLN -0.003  0.054  0.101  0.002  0.049 -0.323  0.602       
## Lght_rnttnS -0.500 -0.023 -0.093 -0.147  0.056  0.215 -0.077 -0.131
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## Model failed to converge with max|grad| = 0.0048478 (tol = 0.002, component 1)
summary(glmer(Did_move ~ Treatment + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data, family = binomial))
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: 
## Did_move ~ Treatment + Sex + Region + Treatment_FTL + Light_orientation +  
##     (1 | Mother) + (1 | Site) + (1 | Room)
##    Data: Data
## 
##      AIC      BIC   logLik deviance df.resid 
##     65.0     95.5    -21.5     43.0      107 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -5.3716  0.1081  0.1500  0.2389  0.4639 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev.
##  Mother (Intercept) 5.400e-01 0.734872
##  Site   (Intercept) 2.445e-02 0.156362
##  Room   (Intercept) 4.613e-05 0.006792
## Number of obs: 118, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                        Estimate Std. Error z value Pr(>|z|)  
## (Intercept)             2.43282    1.23907   1.963   0.0496 *
## TreatmentFull           0.69939    1.31477   0.532   0.5948  
## TreatmentSmart         -0.04876    1.01580  -0.048   0.9617  
## SexMale                 1.24235    1.14705   1.083   0.2788  
## RegionLuxembourg        0.33512    1.15604   0.290   0.7719  
## Treatment_FTLMix        0.42982    1.42766   0.301   0.7634  
## Treatment_FTLNight      1.32599    1.48284   0.894   0.3712  
## Light_orientationSouth -0.67145    0.97231  -0.691   0.4898  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TrtmnF TrtmnS SexMal RgnLxm T_FTLM T_FTLN
## TreatmntFll -0.377                                          
## TretmntSmrt -0.426  0.460                                   
## SexMale     -0.213 -0.027  0.065                            
## ReginLxmbrg -0.247 -0.051 -0.152 -0.057                     
## Trtmnt_FTLM -0.098  0.169  0.141  0.000 -0.388              
## Trtmnt_FTLN -0.026  0.054  0.055  0.022 -0.295  0.589       
## Lght_rnttnS -0.500 -0.032 -0.148  0.051  0.238 -0.103 -0.135
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## Model failed to converge with max|grad| = 0.0182943 (tol = 0.002, component 1)

Aucune grosse différence mais vu qu’on a utilisé treatment_bis dans les autres tests, nous allons continuer avec treatment.

5.2.4 Résultats

Analyse des p-val

summary(glmer(Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data, family = binomial))
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## Model failed to converge with max|grad| = 0.0048478 (tol = 0.002, component 1)
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: 
## Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  
##     (1 | Mother) + (1 | Site) + (1 | Room)
##    Data: Data
## 
##      AIC      BIC   logLik deviance df.resid 
##     66.8    100.0    -21.4     42.8      106 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -5.5255  0.1076  0.1483  0.2316  0.4602 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev.
##  Mother (Intercept) 5.231e-01 0.723250
##  Site   (Intercept) 1.574e-02 0.125457
##  Room   (Intercept) 5.221e-06 0.002285
## Number of obs: 118, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                         Estimate Std. Error z value Pr(>|z|)  
## (Intercept)               2.3901     1.2336   1.937   0.0527 .
## Treatment_bisFull         0.7011     1.3140   0.534   0.5936  
## Treatment_bisSmart        0.3476     1.3507   0.257   0.7969  
## Treatment_bisMixt_smart  -0.3041     1.1123  -0.273   0.7845  
## SexMale                   1.2964     1.1539   1.123   0.2612  
## RegionLuxembourg          0.3085     1.1939   0.258   0.7961  
## Treatment_FTLMix          0.4637     1.4721   0.315   0.7528  
## Treatment_FTLNight        1.3724     1.5201   0.903   0.3666  
## Light_orientationSouth   -0.6529     0.9700  -0.673   0.5009  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_FTLM T_FTLN
## Trtmnt_bsFl -0.386                                                 
## Trtmnt_bsSm -0.348  0.350                                          
## Trtmnt_bsM_ -0.358  0.416  0.412                                   
## SexMale     -0.210 -0.015  0.105  0.004                            
## ReginLxmbrg -0.261 -0.061 -0.132 -0.106 -0.047                     
## Trtmnt_FTLM -0.078  0.166  0.151  0.083  0.032 -0.448              
## Trtmnt_FTLN -0.003  0.054  0.101  0.002  0.049 -0.323  0.602       
## Lght_rnttnS -0.500 -0.023 -0.093 -0.147  0.056  0.215 -0.077 -0.131
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## Model failed to converge with max|grad| = 0.0048478 (tol = 0.002, component 1)
summary(glmer(Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data_ref_full, family = binomial))
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## Model failed to converge with max|grad| = 0.0707921 (tol = 0.002, component 1)
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: 
## Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  
##     (1 | Mother) + (1 | Site) + (1 | Room)
##    Data: Data_ref_full
## 
##      AIC      BIC   logLik deviance df.resid 
##     66.8    100.0    -21.4     42.8      106 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -5.4542  0.1148  0.1497  0.2430  0.5059 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev. 
##  Mother (Intercept) 3.009e-01 0.5485201
##  Site   (Intercept) 1.399e-01 0.3740368
##  Room   (Intercept) 3.607e-07 0.0006006
## Number of obs: 118, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                         Estimate Std. Error z value Pr(>|z|)  
## (Intercept)               3.0908     1.4171   2.181   0.0292 *
## Treatment_bisDark        -0.7080     1.3126  -0.539   0.5896  
## Treatment_bisSmart       -0.3731     1.5083  -0.247   0.8046  
## Treatment_bisMixt_smart  -1.0085     1.3215  -0.763   0.4454  
## SexMale                   1.2829     1.1474   1.118   0.2635  
## RegionLuxembourg          0.2861     1.1205   0.255   0.7984  
## Treatment_FTLMix          0.4681     1.4047   0.333   0.7390  
## Treatment_FTLNight        1.3641     1.5157   0.900   0.3681  
## Light_orientationSouth   -0.6667     0.9584  -0.696   0.4866  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S Trt_M_ SexMal RgnLxm T_FTLM T_FTLN
## Trtmnt_bsDr -0.590                                                 
## Trtmnt_bsSm -0.495  0.559                                          
## Trtmnt_bsM_ -0.533  0.647  0.560                                   
## SexMale     -0.198  0.018  0.103  0.025                            
## ReginLxmbrg -0.289  0.062 -0.060 -0.022 -0.059                     
## Trtmnt_FTLM  0.092 -0.172 -0.025 -0.106  0.040 -0.384              
## Trtmnt_FTLN  0.062 -0.058  0.030 -0.054  0.049 -0.291  0.596       
## Lght_rnttnS -0.452  0.021 -0.061 -0.101  0.052  0.189 -0.042 -0.111
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## Model failed to converge with max|grad| = 0.0707921 (tol = 0.002, component 1)
summary(glmer(Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data_ref_smart, family = binomial))
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## Model failed to converge with max|grad| = 0.00344854 (tol = 0.002, component 1)
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: 
## Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  
##     (1 | Mother) + (1 | Site) + (1 | Room)
##    Data: Data_ref_smart
## 
##      AIC      BIC   logLik deviance df.resid 
##     66.8    100.0    -21.4     42.8      106 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -5.5288  0.1076  0.1482  0.2319  0.4606 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev. 
##  Mother (Intercept) 5.201e-01 0.7211608
##  Site   (Intercept) 1.796e-02 0.1340225
##  Room   (Intercept) 4.601e-08 0.0002145
## Number of obs: 118, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                         Estimate Std. Error z value Pr(>|z|)  
## (Intercept)               2.7363     1.4782   1.851   0.0642 .
## Treatment_bisDark        -0.3477     1.3507  -0.257   0.7968  
## Treatment_bisFull         0.3546     1.5193   0.233   0.8154  
## Treatment_bisMixt_smart  -0.6528     1.3502  -0.483   0.6288  
## SexMale                   1.2969     1.1541   1.124   0.2611  
## RegionLuxembourg          0.3092     1.1833   0.261   0.7939  
## Treatment_FTLMix          0.4653     1.4598   0.319   0.7499  
## Treatment_FTLNight        1.3740     1.5162   0.906   0.3648  
## Light_orientationSouth   -0.6522     0.9688  -0.673   0.5008  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trt_M_ SexMal RgnLxm T_FTLM T_FTLN
## Trtmnt_bsDr -0.623                                                 
## Trtmnt_bsFl -0.556  0.586                                          
## Trtmnt_bsM_ -0.560  0.661  0.580                                   
## SexMale     -0.079 -0.105 -0.106 -0.102                            
## ReginLxmbrg -0.337  0.132  0.065  0.045 -0.049                     
## Trtmnt_FTLM  0.069 -0.151  0.009 -0.083  0.034 -0.437              
## Trtmnt_FTLN  0.088 -0.100 -0.043 -0.100  0.050 -0.316  0.599       
## Lght_rnttnS -0.501  0.093  0.063 -0.028  0.056  0.210 -0.071 -0.127
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## Model failed to converge with max|grad| = 0.00344854 (tol = 0.002, component 1)
summary(glmer(Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data_ref_mixt_smart, family = binomial))
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## Model failed to converge with max|grad| = 0.00443571 (tol = 0.002, component 1)
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: 
## Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  
##     (1 | Mother) + (1 | Site) + (1 | Room)
##    Data: Data_ref_mixt_smart
## 
##      AIC      BIC   logLik deviance df.resid 
##     66.8    100.0    -21.4     42.8      106 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -5.5214  0.1078  0.1479  0.2331  0.4604 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev. 
##  Mother (Intercept) 5.037e-01 0.7097328
##  Site   (Intercept) 3.352e-02 0.1830893
##  Room   (Intercept) 8.342e-07 0.0009133
## Number of obs: 118, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                        Estimate Std. Error z value Pr(>|z|)
## (Intercept)              2.0874     1.3300   1.569    0.117
## Treatment_bisDark        0.3036     1.1117   0.273    0.785
## Treatment_bisFull        1.0084     1.3236   0.762    0.446
## Treatment_bisSmart       0.6503     1.3494   0.482    0.630
## SexMale                  1.2954     1.1535   1.123    0.261
## RegionLuxembourg         0.3023     1.1421   0.265    0.791
## Treatment_FTLMix         0.4698     1.4074   0.334    0.739
## Treatment_FTLNight       1.3785     1.4984   0.920    0.358
## Light_orientationSouth  -0.6549     0.9643  -0.679    0.497
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trtm_S SexMal RgnLxm T_FTLM T_FTLN
## Trtmnt_bsDr -0.502                                                 
## Trtmnt_bsFl -0.434  0.428                                          
## Trtmnt_bsSm -0.392  0.412  0.354                                   
## SexMale     -0.190 -0.005 -0.018  0.101                            
## ReginLxmbrg -0.323  0.102  0.029 -0.049 -0.057                     
## Trtmnt_FTLM -0.026 -0.079  0.099  0.087  0.041 -0.397              
## Trtmnt_FTLN -0.013  0.002  0.053  0.101  0.054 -0.291  0.586       
## Lght_rnttnS -0.582  0.145  0.102  0.028  0.053  0.193 -0.048 -0.116
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## Model failed to converge with max|grad| = 0.00443571 (tol = 0.002, component 1)
summary(glmer(Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data_refFTL_Mix, family = binomial))
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## Model failed to converge with max|grad| = 0.0153663 (tol = 0.002, component 1)
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: 
## Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  
##     (1 | Mother) + (1 | Site) + (1 | Room)
##    Data: Data_refFTL_Mix
## 
##      AIC      BIC   logLik deviance df.resid 
##     66.8    100.0    -21.4     42.8      106 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -5.4845  0.1078  0.1485  0.2368  0.4704 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev. 
##  Mother (Intercept) 4.567e-01 0.6758202
##  Site   (Intercept) 6.981e-02 0.2642145
##  Room   (Intercept) 2.416e-08 0.0001555
## Number of obs: 118, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                         Estimate Std. Error z value Pr(>|z|)
## (Intercept)               2.8705     1.7675   1.624    0.104
## Treatment_bisFull         0.7036     1.3137   0.536    0.592
## Treatment_bisSmart        0.3510     1.3490   0.260    0.795
## Treatment_bisMixt_smart  -0.3028     1.1113  -0.272    0.785
## SexMale                   1.2957     1.1534   1.123    0.261
## RegionLuxembourg          0.2926     1.1309   0.259    0.796
## Treatment_FTLDay         -0.4807     1.3925  -0.345    0.730
## Treatment_FTLNight        0.9030     1.3218   0.683    0.495
## Light_orientationSouth   -0.6567     0.9627  -0.682    0.495
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_FTLD T_FTLN
## Trtmnt_bsFl -0.138                                                 
## Trtmnt_bsSm -0.124  0.350                                          
## Trtmnt_bsM_ -0.191  0.415  0.411                                   
## SexMale     -0.110 -0.015  0.103  0.005                            
## ReginLxmbrg -0.486 -0.057 -0.132 -0.099 -0.060                     
## Trtmnt_FTLD -0.718 -0.169 -0.151 -0.078 -0.044  0.384              
## Trtmnt_FTLN -0.246 -0.119 -0.048 -0.084  0.016  0.082  0.395       
## Lght_rnttnS -0.380 -0.021 -0.092 -0.146  0.052  0.189  0.043 -0.083
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## Model failed to converge with max|grad| = 0.0153663 (tol = 0.002, component 1)
summary(glmer(Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data_refFTL_Night, family = binomial))
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## unable to evaluate scaled gradient
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## Model failed to converge: degenerate Hessian with 1 negative eigenvalues
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: 
## Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  
##     (1 | Mother) + (1 | Site) + (1 | Room)
##    Data: Data_refFTL_Night
## 
##      AIC      BIC   logLik deviance df.resid 
##     66.8    100.0    -21.4     42.8      106 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -5.5406  0.1075  0.1482  0.2310  0.4605 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev.
##  Mother (Intercept) 5.311e-01 0.728754
##  Site   (Intercept) 6.561e-03 0.081001
##  Room   (Intercept) 2.873e-07 0.000536
## Number of obs: 118, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                         Estimate Std. Error z value Pr(>|z|)  
## (Intercept)               3.7597     1.8451   2.038   0.0416 *
## Treatment_bisFull         0.7019     1.3125   0.535   0.5928  
## Treatment_bisSmart        0.3490     1.3507   0.258   0.7961  
## Treatment_bisMixt_smart  -0.3047     1.1102  -0.274   0.7837  
## SexMale                   1.2972     1.1530   1.125   0.2605  
## RegionLuxembourg          0.3121     0.9685   0.322   0.7472  
## Treatment_FTLDay         -1.3715     1.4381  -0.954   0.3402  
## Treatment_FTLMix         -0.9108     1.2911  -0.705   0.4805  
## Light_orientationSouth   -0.6522     0.9465  -0.689   0.4908  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_FTLD T_FTLM
## Trtmnt_bsFl -0.232                                                 
## Trtmnt_bsSm -0.161  0.349                                          
## Trtmnt_bsM_ -0.259  0.414  0.411                                   
## SexMale     -0.084 -0.013  0.107  0.007                            
## ReginLxmbrg -0.287 -0.038 -0.139 -0.089 -0.091                     
## Trtmnt_FTLD -0.749 -0.039 -0.095  0.019 -0.068  0.170              
## Trtmnt_FTLM -0.557  0.112  0.045  0.078 -0.009  0.031  0.613       
## Lght_rnttnS -0.373 -0.012 -0.088 -0.137  0.048  0.109  0.063  0.128
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## unable to evaluate scaled gradient
## Model failed to converge: degenerate  Hessian with 1 negative eigenvalues
test1 <- data.frame(Reference_Treatment = "Dark", Reference_Timing = "Day", as.data.frame(( summary(glmer(Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data, family = binomial))$coeff)[,]))
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## Model failed to converge with max|grad| = 0.0048478 (tol = 0.002, component 1)
test2 <- data.frame(Reference_Treatment = "Smart", Reference_Timing = "Day", as.data.frame(( summary(glmer(Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data_ref_smart, family = binomial))$coeff)[,]))
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## Model failed to converge with max|grad| = 0.00344854 (tol = 0.002, component 1)
test3 <- data.frame(Reference_Treatment = "Full", Reference_Timing = "Day", as.data.frame(( summary(glmer(Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data_ref_full, family = binomial))$coeff)[,]))
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## Model failed to converge with max|grad| = 0.0707921 (tol = 0.002, component 1)
test4 <- data.frame(Reference_Treatment = "Mixt_smart", Reference_Timing = "Day", as.data.frame(( summary(glmer(Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data_ref_mixt_smart, family = binomial))$coeff)[,]))
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## Model failed to converge with max|grad| = 0.00443571 (tol = 0.002, component 1)
test5 <- data.frame(Reference_Treatment = "Dark", Reference_Timing = "Mixt", as.data.frame(( summary(glmer(Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data_refFTL_Mix, family = binomial))$coeff)[,]))
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## Model failed to converge with max|grad| = 0.0153663 (tol = 0.002, component 1)
test6 <- data.frame(Reference_Treatment = "Dark", Reference_Timing = "Night", as.data.frame(( summary(glmer(Did_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data_refFTL_Night, family = binomial))$coeff)[,]))
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## unable to evaluate scaled gradient
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## Model failed to converge: degenerate Hessian with 1 negative eigenvalues
Results_Did_move <- rbind(test1,test2,test3,test4,test5,test6)

colnames(Results_Did_move ) <- c("Reference_Treatment", "Reference_Timing" ,"Estimate", "Std. Error", "z value", "Pr(>|z|)")

write.csv2( Results_Did_move , file = "output/Results_Did_move.csv" )


kable(Results_Did_move , caption = " Probabilité de bouger ", padding = 1 )
Probabilité de bouger
Reference_Treatment Reference_Timing Estimate Std. Error z value Pr(>|z|)
(Intercept) Dark Day 2.3901238 1.2336420 1.9374534 0.0526899
Treatment_bisFull Dark Day 0.7011087 1.3140024 0.5335673 0.5936409
Treatment_bisSmart Dark Day 0.3475819 1.3507182 0.2573312 0.7969231
Treatment_bisMixt_smart Dark Day -0.3041434 1.1122814 -0.2734411 0.7845142
SexMale Dark Day 1.2964030 1.1539143 1.1234829 0.2612325
RegionLuxembourg Dark Day 0.3085259 1.1939095 0.2584165 0.7960855
Treatment_FTLMix Dark Day 0.4636972 1.4721090 0.3149883 0.7527705
Treatment_FTLNight Dark Day 1.3724161 1.5200623 0.9028683 0.3665958
Light_orientationSouth Dark Day -0.6529492 0.9700257 -0.6731257 0.5008673
(Intercept)1 Smart Day 2.7362811 1.4782375 1.8510429 0.0641634
Treatment_bisDark Smart Day -0.3477340 1.3507389 -0.2574398 0.7968393
Treatment_bisFull1 Smart Day 0.3546464 1.5193135 0.2334254 0.8154311
Treatment_bisMixt_smart1 Smart Day -0.6527769 1.3502463 -0.4834502 0.6287761
SexMale1 Smart Day 1.2968534 1.1540905 1.1237016 0.2611396
RegionLuxembourg1 Smart Day 0.3092047 1.1833336 0.2612997 0.7938614
Treatment_FTLMix1 Smart Day 0.4653352 1.4597812 0.3187705 0.7499006
Treatment_FTLNight1 Smart Day 1.3739814 1.5162392 0.9061772 0.3648421
Light_orientationSouth1 Smart Day -0.6521780 0.9688398 -0.6731536 0.5008496
(Intercept)2 Full Day 3.0908225 1.4170550 2.1811591 0.0291716
Treatment_bisDark1 Full Day -0.7080212 1.3125690 -0.5394163 0.5895996
Treatment_bisSmart1 Full Day -0.3730571 1.5082938 -0.2473371 0.8046473
Treatment_bisMixt_smart2 Full Day -1.0084502 1.3214600 -0.7631334 0.4453838
SexMale2 Full Day 1.2828972 1.1473734 1.1181166 0.2635172
RegionLuxembourg2 Full Day 0.2861447 1.1204720 0.2553787 0.7984306
Treatment_FTLMix2 Full Day 0.4680808 1.4047109 0.3332221 0.7389666
Treatment_FTLNight2 Full Day 1.3640888 1.5156706 0.8999902 0.3681254
Light_orientationSouth2 Full Day -0.6667241 0.9583846 -0.6956748 0.4866325
(Intercept)3 Mixt_smart Day 2.0874162 1.3300254 1.5694559 0.1165418
Treatment_bisDark2 Mixt_smart Day 0.3036088 1.1117003 0.2731032 0.7847739
Treatment_bisFull2 Mixt_smart Day 1.0084434 1.3236045 0.7618917 0.4461246
Treatment_bisSmart2 Mixt_smart Day 0.6503214 1.3493855 0.4819389 0.6298493
SexMale3 Mixt_smart Day 1.2954164 1.1534816 1.1230490 0.2614167
RegionLuxembourg3 Mixt_smart Day 0.3022548 1.1421008 0.2646481 0.7912806
Treatment_FTLMix3 Mixt_smart Day 0.4698313 1.4074051 0.3338281 0.7385093
Treatment_FTLNight3 Mixt_smart Day 1.3784983 1.4983519 0.9200097 0.3575677
Light_orientationSouth3 Mixt_smart Day -0.6549420 0.9642647 -0.6792139 0.4970024
(Intercept)4 Dark Mixt 2.8705459 1.7675156 1.6240569 0.1043637
Treatment_bisFull3 Dark Mixt 0.7036001 1.3136518 0.5356062 0.5922307
Treatment_bisSmart3 Dark Mixt 0.3510246 1.3489716 0.2602165 0.7946968
Treatment_bisMixt_smart3 Dark Mixt -0.3027501 1.1112692 -0.2724363 0.7852866
SexMale4 Dark Mixt 1.2957495 1.1533782 1.1234385 0.2612513
RegionLuxembourg4 Dark Mixt 0.2926305 1.1309426 0.2587492 0.7958287
Treatment_FTLDay Dark Mixt -0.4806651 1.3924834 -0.3451855 0.7299549
Treatment_FTLNight4 Dark Mixt 0.9029848 1.3218072 0.6831441 0.4945158
Light_orientationSouth4 Dark Mixt -0.6567263 0.9626599 -0.6821997 0.4951127
(Intercept)5 Dark Night 3.7597409 1.8450793 2.0377124 0.0415787
Treatment_bisFull4 Dark Night 0.7019112 1.3125280 0.5347781 0.5928033
Treatment_bisSmart4 Dark Night 0.3489525 1.3506667 0.2583557 0.7961324
Treatment_bisMixt_smart4 Dark Night -0.3047051 1.1102495 -0.2744474 0.7837409
SexMale5 Dark Night 1.2972109 1.1529738 1.1251001 0.2605466
RegionLuxembourg5 Dark Night 0.3121419 0.9685003 0.3222940 0.7472300
Treatment_FTLDay1 Dark Night -1.3714979 1.4380795 -0.9537010 0.3402350
Treatment_FTLMix4 Dark Night -0.9108337 1.2911473 -0.7054452 0.4805332
Light_orientationSouth5 Dark Night -0.6521568 0.9465170 -0.6890070 0.4908189
Info_Did_move <- "
Aucun effet significatif
"

5.2.5 Visualisation

ggplot(Data %>% filter(Did_move != "NA")) +
  aes(x = Did_move, fill = Treatment_FTL) +
  geom_bar(position = "dodge") +
  scale_fill_hue(direction = 1) +
  labs(title= "Probabilité de bouger", x = "A bougé", y = "Nombre d'individus", fill = "Timing") +
  theme_minimal()

5.3 Did_FTL

5.3.1 Test

GLM_Did_FTL <- glmer(Did_FTL ~ Treatment_bis + Sex  + Region + Treatment_FTL + Light_orientation + (1|Mother) + (1|Site) + (1|Room)  + Treatment_bis:Sex + Treatment_bis:Region + Treatment_FTL:Sex + Treatment_FTL:Region + Treatment_FTL:Treatment_bis + Light_orientation:Sex + Light_orientation:Region + Light_orientation:Treatment_bis, family = binomial, data = Data)
summary(GLM_Did_FTL)
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: 
## Did_FTL ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex +  
##     Treatment_bis:Region + Treatment_FTL:Sex + Treatment_FTL:Region +  
##     Treatment_FTL:Treatment_bis + Light_orientation:Sex + Light_orientation:Region +  
##     Light_orientation:Treatment_bis
##    Data: Data
## 
##      AIC      BIC   logLik deviance df.resid 
##    165.1    256.5    -49.5     99.1       85 
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -1.74352 -0.35258  0.00733  0.23899  2.18663 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev. 
##  Mother (Intercept) 4.260e-05 0.0065267
##  Site   (Intercept) 7.131e+00 2.6704276
##  Room   (Intercept) 1.976e-07 0.0004445
## Number of obs: 118, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                                Estimate Std. Error z value
## (Intercept)                                     -0.3018     1.9216  -0.157
## Treatment_bisFull                               -1.7400     1.7252  -1.009
## Treatment_bisSmart                               1.4081     2.2880   0.615
## Treatment_bisMixt_smart                         -5.3938     3.2691  -1.650
## SexMale                                         -2.2853     1.5708  -1.455
## RegionLuxembourg                                -1.7960     2.5350  -0.708
## Treatment_FTLMix                                 3.1362     2.1441   1.463
## Treatment_FTLNight                               2.9418     2.3338   1.260
## Light_orientationSouth                          -2.0254     1.3389  -1.513
## Treatment_bisFull:SexMale                        0.3259     1.7972   0.181
## Treatment_bisSmart:SexMale                       2.5960     2.6518   0.979
## Treatment_bisMixt_smart:SexMale                  2.7817     2.7297   1.019
## Treatment_bisFull:RegionLuxembourg               5.9814     2.6704   2.240
## Treatment_bisSmart:RegionLuxembourg             -0.6725     2.1744  -0.309
## Treatment_bisMixt_smart:RegionLuxembourg        -3.9033     3.5521  -1.099
## SexMale:Treatment_FTLMix                         0.2077     1.7634   0.118
## SexMale:Treatment_FTLNight                       1.6124     1.9388   0.832
## RegionLuxembourg:Treatment_FTLMix               -2.6025     2.4761  -1.051
## RegionLuxembourg:Treatment_FTLNight              3.7749     2.8212   1.338
## Treatment_bisFull:Treatment_FTLMix               0.7023     2.1248   0.331
## Treatment_bisSmart:Treatment_FTLMix              1.4699     2.0862   0.705
## Treatment_bisMixt_smart:Treatment_FTLMix         9.1656     4.6430   1.974
## Treatment_bisFull:Treatment_FTLNight             0.5079     2.1223   0.239
## Treatment_bisSmart:Treatment_FTLNight           -3.3713     2.7167  -1.241
## Treatment_bisMixt_smart:Treatment_FTLNight       2.2935     3.2844   0.698
## SexMale:Light_orientationSouth                   4.2483     1.6544   2.568
## RegionLuxembourg:Light_orientationSouth          1.0977     1.8499   0.593
## Treatment_bisFull:Light_orientationSouth        -0.3587     1.8708  -0.192
## Treatment_bisSmart:Light_orientationSouth       -1.3291     2.1743  -0.611
## Treatment_bisMixt_smart:Light_orientationSouth   5.3970     2.8328   1.905
##                                                Pr(>|z|)  
## (Intercept)                                      0.8752  
## Treatment_bisFull                                0.3132  
## Treatment_bisSmart                               0.5383  
## Treatment_bisMixt_smart                          0.0990 .
## SexMale                                          0.1457  
## RegionLuxembourg                                 0.4786  
## Treatment_FTLMix                                 0.1435  
## Treatment_FTLNight                               0.2075  
## Light_orientationSouth                           0.1303  
## Treatment_bisFull:SexMale                        0.8561  
## Treatment_bisSmart:SexMale                       0.3276  
## Treatment_bisMixt_smart:SexMale                  0.3082  
## Treatment_bisFull:RegionLuxembourg               0.0251 *
## Treatment_bisSmart:RegionLuxembourg              0.7571  
## Treatment_bisMixt_smart:RegionLuxembourg         0.2718  
## SexMale:Treatment_FTLMix                         0.9062  
## SexMale:Treatment_FTLNight                       0.4056  
## RegionLuxembourg:Treatment_FTLMix                0.2932  
## RegionLuxembourg:Treatment_FTLNight              0.1809  
## Treatment_bisFull:Treatment_FTLMix               0.7410  
## Treatment_bisSmart:Treatment_FTLMix              0.4811  
## Treatment_bisMixt_smart:Treatment_FTLMix         0.0484 *
## Treatment_bisFull:Treatment_FTLNight             0.8109  
## Treatment_bisSmart:Treatment_FTLNight            0.2146  
## Treatment_bisMixt_smart:Treatment_FTLNight       0.4850  
## SexMale:Light_orientationSouth                   0.0102 *
## RegionLuxembourg:Light_orientationSouth          0.5529  
## Treatment_bisFull:Light_orientationSouth         0.8479  
## Treatment_bisSmart:Light_orientationSouth        0.5410  
## Treatment_bisMixt_smart:Light_orientationSouth   0.0568 .
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## optimizer (Nelder_Mead) convergence code: 4 (failure to converge in 10000 evaluations)
## Model failed to converge with max|grad| = 0.0151932 (tol = 0.002, component 1)
## failure to converge in 10000 evaluations

5.3.2 Simplification du modèle

Simplification par AIC/BIC

drop1(GLM_Did_FTL)
## Single term deletions
## 
## Model:
## Did_FTL ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + 
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + 
##     Treatment_bis:Region + Treatment_FTL:Sex + Treatment_FTL:Region + 
##     Treatment_FTL:Treatment_bis + Light_orientation:Sex + Light_orientation:Region + 
##     Light_orientation:Treatment_bis
##                                 npar    AIC
## <none>                               165.09
## Treatment_bis:Sex                  3 160.96
## Treatment_bis:Region               3 172.07
## Sex:Treatment_FTL                  2 161.94
## Region:Treatment_FTL               2 169.99
## Treatment_bis:Treatment_FTL        6 163.04
## Sex:Light_orientation              1 171.54
## Region:Light_orientation           1 163.49
## Treatment_bis:Light_orientation    3 166.26
GLM_Did_FTL2 <- update(GLM_Did_FTL, . ~ . - Treatment_bis:Sex)
drop1(GLM_Did_FTL2)
## Single term deletions
## 
## Model:
## Did_FTL ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + 
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region + 
##     Sex:Treatment_FTL + Region:Treatment_FTL + Treatment_bis:Treatment_FTL + 
##     Sex:Light_orientation + Region:Light_orientation + Treatment_bis:Light_orientation
##                                 npar    AIC
## <none>                               160.96
## Treatment_bis:Region               3 166.62
## Sex:Treatment_FTL                  2 158.05
## Region:Treatment_FTL               2 166.70
## Treatment_bis:Treatment_FTL        6 159.33
## Sex:Light_orientation              1 167.90
## Region:Light_orientation           1 159.11
## Treatment_bis:Light_orientation    3 162.00
GLM_Did_FTL3 <- update(GLM_Did_FTL2, . ~ . - Sex:Treatment_FTL)
drop1(GLM_Did_FTL3)
## Single term deletions
## 
## Model:
## Did_FTL ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + 
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region + 
##     Region:Treatment_FTL + Treatment_bis:Treatment_FTL + Sex:Light_orientation + 
##     Region:Light_orientation + Treatment_bis:Light_orientation
##                                 npar    AIC
## <none>                               158.05
## Treatment_bis:Region               3 163.59
## Region:Treatment_FTL               2 162.96
## Treatment_bis:Treatment_FTL        6 156.53
## Sex:Light_orientation              1 165.73
## Region:Light_orientation           1 156.12
## Treatment_bis:Light_orientation    3 159.12
GLM_Did_FTL4 <- update(GLM_Did_FTL3, . ~ . - Treatment_bis:Treatment_FTL)
drop1(GLM_Did_FTL4)
## Single term deletions
## 
## Model:
## Did_FTL ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + 
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region + 
##     Region:Treatment_FTL + Sex:Light_orientation + Region:Light_orientation + 
##     Treatment_bis:Light_orientation
##                                 npar    AIC
## <none>                               156.53
## Treatment_bis:Region               3 158.19
## Region:Treatment_FTL               2 156.47
## Sex:Light_orientation              1 163.31
## Region:Light_orientation           1 154.63
## Treatment_bis:Light_orientation    3 154.77
GLM_Did_FTL5 <- update(GLM_Did_FTL4, . ~ . - Region:Light_orientation)
drop1(GLM_Did_FTL5)
## Single term deletions
## 
## Model:
## Did_FTL ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + 
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region + 
##     Region:Treatment_FTL + Sex:Light_orientation + Treatment_bis:Light_orientation
##                                 npar    AIC
## <none>                               154.63
## Treatment_bis:Region               3 156.27
## Region:Treatment_FTL               2 154.49
## Sex:Light_orientation              1 161.32
## Treatment_bis:Light_orientation    3 152.80
GLM_Did_FTL6 <- update(GLM_Did_FTL5, . ~ . - Treatment_bis:Light_orientation)
drop1(GLM_Did_FTL6)
## Single term deletions
## 
## Model:
## Did_FTL ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + 
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region + 
##     Region:Treatment_FTL + Sex:Light_orientation
##                       npar    AIC
## <none>                     152.80
## Treatment_bis:Region     3 155.06
## Region:Treatment_FTL     2 152.56
## Sex:Light_orientation    1 158.45
GLM_Did_FTL7 <- update(GLM_Did_FTL6, . ~ . - Region:Treatment_FTL)
drop1(GLM_Did_FTL7)
## Single term deletions
## 
## Model:
## Did_FTL ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + 
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region + 
##     Sex:Light_orientation
##                       npar    AIC
## <none>                     152.56
## Treatment_FTL            2 161.50
## Treatment_bis:Region     3 154.61
## Sex:Light_orientation    1 158.98

Est ce qu’il faut pas juste retirer toutes les interactions ?

BIC(glmer(Did_FTL ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data, family = binomial))
## [1] 193.4505
BIC(GLM_Did_FTL7)
## [1] 196.8872

Si

GLM_Did_FTL <- glmer(Did_FTL ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data, family = binomial)

5.3.3 Treatment VS Treatment_bis

AIC(glmer(Did_FTL ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data, family = binomial))
## [1] 160.2023
AIC(glmer(Did_FTL ~ Treatment + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data, family = binomial))
## [1] 158.3439
summary(glmer(Did_FTL ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data, family = binomial))
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: 
## Did_FTL ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  
##     (1 | Mother) + (1 | Site) + (1 | Room)
##    Data: Data
## 
##      AIC      BIC   logLik deviance df.resid 
##    160.2    193.5    -68.1    136.2      106 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.1596 -0.6899  0.2677  0.5302  2.0153 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev. 
##  Mother (Intercept) 4.849e-01 0.6963779
##  Site   (Intercept) 6.223e-01 0.7888452
##  Room   (Intercept) 4.255e-07 0.0006523
## Number of obs: 118, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                         Estimate Std. Error z value Pr(>|z|)   
## (Intercept)              -1.7096     0.7721  -2.214  0.02681 * 
## Treatment_bisFull         0.3596     0.5948   0.605  0.54546   
## Treatment_bisSmart        0.5708     0.6804   0.839  0.40152   
## Treatment_bisMixt_smart   0.2832     0.6529   0.434  0.66446   
## SexMale                   0.1707     0.4758   0.359  0.71984   
## RegionLuxembourg          0.7777     0.7826   0.994  0.32035   
## Treatment_FTLMix          1.2505     0.7526   1.662  0.09659 . 
## Treatment_FTLNight        2.2091     0.7516   2.939  0.00329 **
## Light_orientationSouth    0.2275     0.4851   0.469  0.63904   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_FTLM T_FTLN
## Trtmnt_bsFl -0.350                                                 
## Trtmnt_bsSm -0.287  0.370                                          
## Trtmnt_bsM_ -0.285  0.443  0.337                                   
## SexMale     -0.290 -0.056  0.053 -0.012                            
## ReginLxmbrg -0.450  0.015 -0.060 -0.001  0.042                     
## Trtmnt_FTLM -0.287  0.102  0.018 -0.002 -0.085 -0.277              
## Trtmnt_FTLN -0.299  0.043  0.013 -0.027  0.014 -0.199  0.686       
## Lght_rnttnS -0.315 -0.123 -0.039 -0.108  0.075  0.157 -0.099 -0.157
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## Model failed to converge with max|grad| = 0.0031881 (tol = 0.002, component 1)
summary(glmer(Did_FTL ~ Treatment + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data, family = binomial))
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: 
## Did_FTL ~ Treatment + Sex + Region + Treatment_FTL + Light_orientation +  
##     (1 | Mother) + (1 | Site) + (1 | Room)
##    Data: Data
## 
##      AIC      BIC   logLik deviance df.resid 
##    158.3    188.8    -68.2    136.3      107 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.3031 -0.6765  0.2807  0.5189  1.9056 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev. 
##  Mother (Intercept) 4.495e-01 0.6704824
##  Site   (Intercept) 6.214e-01 0.7882978
##  Room   (Intercept) 8.679e-07 0.0009316
## Number of obs: 118, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                        Estimate Std. Error z value Pr(>|z|)   
## (Intercept)             -1.7082     0.7679  -2.225   0.0261 * 
## TreatmentFull            0.3693     0.5925   0.623   0.5331   
## TreatmentSmart           0.4182     0.5431   0.770   0.4413   
## SexMale                  0.1606     0.4732   0.339   0.7343   
## RegionLuxembourg         0.7944     0.7766   1.023   0.3063   
## Treatment_FTLMix         1.2481     0.7592   1.644   0.1002   
## Treatment_FTLNight       2.2038     0.7592   2.903   0.0037 **
## Light_orientationSouth   0.2173     0.4846   0.448   0.6538   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TrtmnF TrtmnS SexMal RgnLxm T_FTLM T_FTLN
## TreatmntFll -0.352                                          
## TretmntSmrt -0.354  0.499                                   
## SexMale     -0.288 -0.055  0.023                            
## ReginLxmbrg -0.448  0.010 -0.033  0.044                     
## Trtmnt_FTLM -0.286  0.106  0.007 -0.088 -0.282              
## Trtmnt_FTLN -0.298  0.051 -0.012  0.011 -0.206  0.694       
## Lght_rnttnS -0.315 -0.123 -0.085  0.070  0.165 -0.106 -0.164
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## Model failed to converge with max|grad| = 0.0048435 (tol = 0.002, component 1)

Il faudrait muieux continuer avec Treatment

5.3.4 Résultats

Analyse des p-val

summary(glmer(Did_FTL ~ Treatment + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data, family = binomial))
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## Model failed to converge with max|grad| = 0.0048435 (tol = 0.002, component 1)
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: 
## Did_FTL ~ Treatment + Sex + Region + Treatment_FTL + Light_orientation +  
##     (1 | Mother) + (1 | Site) + (1 | Room)
##    Data: Data
## 
##      AIC      BIC   logLik deviance df.resid 
##    158.3    188.8    -68.2    136.3      107 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.3031 -0.6765  0.2807  0.5189  1.9056 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev. 
##  Mother (Intercept) 4.495e-01 0.6704824
##  Site   (Intercept) 6.214e-01 0.7882978
##  Room   (Intercept) 8.679e-07 0.0009316
## Number of obs: 118, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                        Estimate Std. Error z value Pr(>|z|)   
## (Intercept)             -1.7082     0.7679  -2.225   0.0261 * 
## TreatmentFull            0.3693     0.5925   0.623   0.5331   
## TreatmentSmart           0.4182     0.5431   0.770   0.4413   
## SexMale                  0.1606     0.4732   0.339   0.7343   
## RegionLuxembourg         0.7944     0.7766   1.023   0.3063   
## Treatment_FTLMix         1.2481     0.7592   1.644   0.1002   
## Treatment_FTLNight       2.2038     0.7592   2.903   0.0037 **
## Light_orientationSouth   0.2173     0.4846   0.448   0.6538   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TrtmnF TrtmnS SexMal RgnLxm T_FTLM T_FTLN
## TreatmntFll -0.352                                          
## TretmntSmrt -0.354  0.499                                   
## SexMale     -0.288 -0.055  0.023                            
## ReginLxmbrg -0.448  0.010 -0.033  0.044                     
## Trtmnt_FTLM -0.286  0.106  0.007 -0.088 -0.282              
## Trtmnt_FTLN -0.298  0.051 -0.012  0.011 -0.206  0.694       
## Lght_rnttnS -0.315 -0.123 -0.085  0.070  0.165 -0.106 -0.164
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## Model failed to converge with max|grad| = 0.0048435 (tol = 0.002, component 1)
summary(glmer(Did_FTL ~ Treatment + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data_ref_full, family = binomial))
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## Model failed to converge with max|grad| = 0.0370792 (tol = 0.002, component 1)
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: 
## Did_FTL ~ Treatment + Sex + Region + Treatment_FTL + Light_orientation +  
##     (1 | Mother) + (1 | Site) + (1 | Room)
##    Data: Data_ref_full
## 
##      AIC      BIC   logLik deviance df.resid 
##    158.3    188.8    -68.2    136.3      107 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.3040 -0.6777  0.2802  0.5191  1.9080 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev.
##  Mother (Intercept) 4.371e-01 0.661123
##  Site   (Intercept) 6.356e-01 0.797251
##  Room   (Intercept) 5.085e-05 0.007131
## Number of obs: 118, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                        Estimate Std. Error z value Pr(>|z|)   
## (Intercept)            -1.33401    0.78815  -1.693  0.09054 . 
## TreatmentDark          -0.37250    0.59236  -0.629  0.52946   
## TreatmentSmart          0.04595    0.57019   0.081  0.93576   
## SexMale                 0.16021    0.47307   0.339  0.73487   
## RegionLuxembourg        0.79106    0.77776   1.017  0.30910   
## Treatment_FTLMix        1.25125    0.75762   1.652  0.09862 . 
## Treatment_FTLNight      2.20844    0.75847   2.912  0.00359 **
## Light_orientationSouth  0.21517    0.48437   0.444  0.65688   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TrtmnD TrtmnS SexMal RgnLxm T_FTLM T_FTLN
## TreatmntDrk -0.408                                          
## TretmntSmrt -0.395  0.564                                   
## SexMale     -0.323  0.055  0.079                            
## ReginLxmbrg -0.430 -0.011 -0.043  0.044                     
## Trtmnt_FTLM -0.200 -0.106 -0.104 -0.088 -0.281              
## Trtmnt_FTLN -0.253 -0.051 -0.064  0.011 -0.205  0.694       
## Lght_rnttnS -0.399  0.123  0.047  0.070  0.164 -0.105 -0.163
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## Model failed to converge with max|grad| = 0.0370792 (tol = 0.002, component 1)
summary(glmer(Did_FTL ~ Treatment + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data_ref_smart, family = binomial))
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## Model failed to converge with max|grad| = 0.00826885 (tol = 0.002, component 1)
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: 
## Did_FTL ~ Treatment + Sex + Region + Treatment_FTL + Light_orientation +  
##     (1 | Mother) + (1 | Site) + (1 | Room)
##    Data: Data_ref_smart
## 
##      AIC      BIC   logLik deviance df.resid 
##    158.3    188.8    -68.2    136.3      107 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.3019 -0.6767  0.2807  0.5188  1.9059 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev.
##  Mother (Intercept) 4.489e-01 0.67001 
##  Site   (Intercept) 6.219e-01 0.78861 
##  Room   (Intercept) 2.530e-06 0.00159 
## Number of obs: 118, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                        Estimate Std. Error z value Pr(>|z|)   
## (Intercept)            -1.28982    0.76787  -1.680  0.09301 . 
## TreatmentDark          -0.41758    0.54309  -0.769  0.44196   
## TreatmentFull          -0.04827    0.57012  -0.085  0.93253   
## SexMale                 0.15992    0.47315   0.338  0.73537   
## RegionLuxembourg        0.79304    0.77669   1.021  0.30723   
## Treatment_FTLMix        1.24860    0.75916   1.645  0.10003   
## Treatment_FTLNight      2.20405    0.75919   2.903  0.00369 **
## Light_orientationSouth  0.21777    0.48463   0.449  0.65318   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TrtmnD TrtmnF SexMal RgnLxm T_FTLM T_FTLN
## TreatmntDrk -0.354                                          
## TreatmntFll -0.336  0.434                                   
## SexMale     -0.272 -0.023 -0.079                            
## ReginLxmbrg -0.471  0.033  0.042  0.044                     
## Trtmnt_FTLM -0.281 -0.007  0.104 -0.088 -0.283              
## Trtmnt_FTLN -0.306  0.012  0.064  0.011 -0.207  0.694       
## Lght_rnttnS -0.376  0.085 -0.047  0.070  0.165 -0.106 -0.164
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## Model failed to converge with max|grad| = 0.00826885 (tol = 0.002, component 1)
summary(glmer(Did_FTL ~ Treatment + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data_refFTL_Mix, family = binomial))
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## Model failed to converge with max|grad| = 0.0150819 (tol = 0.002, component 1)
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: 
## Did_FTL ~ Treatment + Sex + Region + Treatment_FTL + Light_orientation +  
##     (1 | Mother) + (1 | Site) + (1 | Room)
##    Data: Data_refFTL_Mix
## 
##      AIC      BIC   logLik deviance df.resid 
##    158.3    188.8    -68.2    136.3      107 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.3022 -0.6767  0.2804  0.5189  1.9073 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev.
##  Mother (Intercept) 4.457e-01 0.667623
##  Site   (Intercept) 6.255e-01 0.790899
##  Room   (Intercept) 8.415e-06 0.002901
## Number of obs: 118, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                        Estimate Std. Error z value Pr(>|z|)  
## (Intercept)             -0.4588     0.9125  -0.503   0.6152  
## TreatmentFull            0.3705     0.5925   0.625   0.5318  
## TreatmentSmart           0.4177     0.5431   0.769   0.4419  
## SexMale                  0.1604     0.4732   0.339   0.7346  
## RegionLuxembourg         0.7927     0.7770   1.020   0.3076  
## Treatment_FTLDay        -1.2499     0.7591  -1.647   0.0996 .
## Treatment_FTLNight       0.9569     0.5937   1.612   0.1070  
## Light_orientationSouth   0.2171     0.4846   0.448   0.6542  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TrtmnF TrtmnS SexMal RgnLxm T_FTLD T_FTLN
## TreatmntFll -0.208                                          
## TretmntSmrt -0.292  0.499                                   
## SexMale     -0.316 -0.055  0.023                            
## ReginLxmbrg -0.612  0.010 -0.033  0.044                     
## Trtmnt_FTLD -0.591 -0.106 -0.007  0.088  0.282              
## Trtmnt_FTLN -0.338 -0.071 -0.024  0.127  0.097  0.391       
## Lght_rnttnS -0.354 -0.123 -0.085  0.070  0.165  0.106 -0.074
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## Model failed to converge with max|grad| = 0.0150819 (tol = 0.002, component 1)
summary(glmer(Did_FTL ~ Treatment + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data_refFTL_Night, family = binomial))
## boundary (singular) fit: see help('isSingular')
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: 
## Did_FTL ~ Treatment + Sex + Region + Treatment_FTL + Light_orientation +  
##     (1 | Mother) + (1 | Site) + (1 | Room)
##    Data: Data_refFTL_Night
## 
##      AIC      BIC   logLik deviance df.resid 
##    158.3    188.8    -68.2    136.3      107 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.3030 -0.6765  0.2807  0.5189  1.9053 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev. 
##  Mother (Intercept) 4.506e-01 6.713e-01
##  Site   (Intercept) 6.203e-01 7.876e-01
##  Room   (Intercept) 7.767e-10 2.787e-05
## Number of obs: 118, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                        Estimate Std. Error z value Pr(>|z|)   
## (Intercept)              0.4953     0.9049   0.547   0.5841   
## TreatmentFull            0.3695     0.5925   0.624   0.5329   
## TreatmentSmart           0.4185     0.5431   0.771   0.4410   
## SexMale                  0.1605     0.4732   0.339   0.7345   
## RegionLuxembourg         0.7945     0.7765   1.023   0.3063   
## Treatment_FTLDay        -2.2036     0.7592  -2.902   0.0037 **
## Treatment_FTLMix        -0.9559     0.5938  -1.610   0.1074   
## Light_orientationSouth   0.2175     0.4846   0.449   0.6536   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TrtmnF TrtmnS SexMal RgnLxm T_FTLD T_FTLM
## TreatmntFll -0.256                                          
## TretmntSmrt -0.310  0.499                                   
## SexMale     -0.235 -0.055  0.023                            
## ReginLxmbrg -0.553  0.010 -0.033  0.044                     
## Trtmnt_FTLD -0.586 -0.051  0.012 -0.011  0.207              
## Trtmnt_FTLM -0.315  0.071  0.024 -0.127 -0.097  0.391       
## Lght_rnttnS -0.405 -0.123 -0.085  0.070  0.165  0.164  0.074
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
test1 <- data.frame(Reference_Treatment = "Dark", Reference_Timing = "Day", as.data.frame(( summary(glmer(Did_FTL ~ Treatment + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data, family = binomial))$coeff)[,]))
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## Model failed to converge with max|grad| = 0.0048435 (tol = 0.002, component 1)
test2 <- data.frame(Reference_Treatment = "Smart", Reference_Timing = "Day", as.data.frame(( summary(glmer(Did_FTL ~ Treatment + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data_ref_smart, family = binomial))$coeff)[,]))
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## Model failed to converge with max|grad| = 0.00826885 (tol = 0.002, component 1)
test3 <- data.frame(Reference_Treatment = "Full", Reference_Timing = "Day", as.data.frame(( summary(glmer(Did_FTL ~ Treatment + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data_ref_full, family = binomial))$coeff)[,]))
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## Model failed to converge with max|grad| = 0.0370792 (tol = 0.002, component 1)
test4 <- data.frame(Reference_Treatment = "Dark", Reference_Timing = "Mixt", as.data.frame(( summary(glmer(Did_FTL ~ Treatment + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data_refFTL_Mix, family = binomial))$coeff)[,]))
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## Model failed to converge with max|grad| = 0.0150819 (tol = 0.002, component 1)
test5 <- data.frame(Reference_Treatment = "Dark", Reference_Timing = "Night", as.data.frame(( summary(glmer(Did_FTL ~ Treatment + Sex + Region + Treatment_FTL + Light_orientation +  (1 | Mother) + (1 | Site) + (1 | Room), data = Data_refFTL_Night, family = binomial))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
Results_Did_FTL <- rbind(test1,test2,test3,test4,test5)

colnames(Results_Did_FTL ) <- c("Reference_Treatment", "Reference_Timing" ,"Estimate", "Std. Error", "z value", "Pr(>|z|)")

write.csv2( Results_Did_FTL , file = "output/Results_Did_FTL.csv" )

kable(Results_Did_FTL , caption = " Probabilité de voler à la lumière ", padding = 1 )
Probabilité de voler à la lumière
Reference_Treatment Reference_Timing Estimate Std. Error z value Pr(>|z|)
(Intercept) Dark Day -1.7081688 0.7678707 -2.2245527 0.0261113
TreatmentFull Dark Day 0.3692970 0.5924814 0.6233057 0.5330837
TreatmentSmart Dark Day 0.4181749 0.5431189 0.7699509 0.4413290
SexMale Dark Day 0.1606063 0.4731734 0.3394237 0.7342906
RegionLuxembourg Dark Day 0.7943784 0.7765694 1.0229330 0.3063395
Treatment_FTLMix Dark Day 1.2481417 0.7591940 1.6440352 0.1001689
Treatment_FTLNight Dark Day 2.2038279 0.7591823 2.9028968 0.0036973
Light_orientationSouth Dark Day 0.2173402 0.4846258 0.4484702 0.6538139
(Intercept)1 Smart Day -1.2898222 0.7678653 -1.6797507 0.0930058
TreatmentDark Smart Day -0.4175789 0.5430945 -0.7688881 0.4419597
TreatmentFull1 Smart Day -0.0482672 0.5701190 -0.0846617 0.9325304
SexMale1 Smart Day 0.1599194 0.4731498 0.3379890 0.7353715
RegionLuxembourg1 Smart Day 0.7930412 0.7766902 1.0210523 0.3072297
Treatment_FTLMix1 Smart Day 1.2486025 0.7591617 1.6447122 0.1000292
Treatment_FTLNight1 Smart Day 2.2040502 0.7591942 2.9031441 0.0036944
Light_orientationSouth1 Smart Day 0.2177711 0.4846307 0.4493548 0.6531758
(Intercept)2 Full Day -1.3340058 0.7881515 -1.6925753 0.0905363
TreatmentDark1 Full Day -0.3725007 0.5923637 -0.6288378 0.5294553
TreatmentSmart1 Full Day 0.0459538 0.5701884 0.0805941 0.9357648
SexMale2 Full Day 0.1602076 0.4730727 0.3386532 0.7348710
RegionLuxembourg2 Full Day 0.7910603 0.7777554 1.0171069 0.3091026
Treatment_FTLMix2 Full Day 1.2512528 0.7576178 1.6515621 0.0986239
Treatment_FTLNight2 Full Day 2.2084372 0.7584730 2.9116888 0.0035948
Light_orientationSouth2 Full Day 0.2151654 0.4843673 0.4442195 0.6568839
(Intercept)3 Dark Mixt -0.4587509 0.9125183 -0.5027306 0.6151537
TreatmentFull2 Dark Mixt 0.3704720 0.5924966 0.6252727 0.5317921
TreatmentSmart2 Dark Mixt 0.4176852 0.5431032 0.7690716 0.4418508
SexMale3 Dark Mixt 0.1603856 0.4731678 0.3389613 0.7346389
RegionLuxembourg3 Dark Mixt 0.7927231 0.7770149 1.0202160 0.3076260
Treatment_FTLDay Dark Mixt -1.2498978 0.7590747 -1.6466070 0.0996388
Treatment_FTLNight3 Dark Mixt 0.9569163 0.5936644 1.6118808 0.1069879
Light_orientationSouth3 Dark Mixt 0.2170862 0.4846294 0.4479427 0.6541946
(Intercept)4 Dark Night 0.4953280 0.9048637 0.5474062 0.5840997
TreatmentFull3 Dark Night 0.3694517 0.5924917 0.6235560 0.5329192
TreatmentSmart3 Dark Night 0.4185338 0.5431387 0.7705837 0.4409537
SexMale4 Dark Night 0.1604751 0.4731869 0.3391367 0.7345067
RegionLuxembourg4 Dark Night 0.7944654 0.7765149 1.0231168 0.3062526
Treatment_FTLDay1 Dark Night -2.2036136 0.7592487 -2.9023607 0.0037036
Treatment_FTLMix3 Dark Night -0.9558769 0.5937535 -1.6098885 0.1074222
Light_orientationSouth4 Dark Night 0.2174625 0.4846481 0.4487019 0.6536467
Info_Did_FTL <- "
Les individus expérimentés durant la nuit volent significativement plus que ceux expérimentés durant le jour. Les individus expérimentés avec la méthode (timing de l'expérience) Mixte ne sont pas significativement différent ni de ceux expérimentés pendant la nuit ni de ceux expérimentés pendant le jour.
"

5.3.5 Visualisation

ggplot(Data %>% filter(Did_FTL != "NA")) +
  aes(x = Did_FTL, fill = Treatment_FTL) +
  geom_bar(position = "dodge") +
  scale_fill_hue(direction = 1) +
  labs(title= "Probabilité de voler à la lumière", x = "A volé à la lumière", y = "Nombre d'individus", fill = "Timing") +
  theme_minimal()

5.4 First_move

5.4.1 Test

LM_First_move <- lmer(First_move ~ Treatment_bis + Sex  + Region + Treatment_FTL + Light_orientation + (1|Mother) + (1|Site) + (1|Room)  + Treatment_bis:Sex + Treatment_bis:Region + Treatment_FTL:Sex + Treatment_FTL:Region + Treatment_FTL:Treatment_bis + Light_orientation:Sex + Light_orientation:Region + Light_orientation:Treatment_bis, data = Data)
## boundary (singular) fit: see help('isSingular')
summary(LM_First_move)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: 
## First_move ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation +  
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex +  
##     Treatment_bis:Region + Treatment_FTL:Sex + Treatment_FTL:Region +  
##     Treatment_FTL:Treatment_bis + Light_orientation:Sex + Light_orientation:Region +  
##     Light_orientation:Treatment_bis
##    Data: Data
## 
## REML criterion at convergence: 1214.1
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.9244 -0.4845 -0.1087  0.3113  2.6388 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept)      0     0.0   
##  Site     (Intercept)  16861   129.9   
##  Room     (Intercept)      0     0.0   
##  Residual             104999   324.0   
## Number of obs: 110, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                                Estimate Std. Error      df
## (Intercept)                                      829.80     190.23   58.20
## Treatment_bisFull                               -266.23     184.92   76.98
## Treatment_bisSmart                              -216.32     235.83   75.70
## Treatment_bisMixt_smart                         -148.29     240.58   77.49
## SexMale                                         -380.44     166.40   77.74
## RegionLuxembourg                                -345.13     202.27   47.24
## Treatment_FTLMix                                -198.87     206.79   70.43
## Treatment_FTLNight                              -528.78     208.10   76.96
## Light_orientationSouth                          -275.81     147.84   74.84
## Treatment_bisFull:SexMale                        265.36     176.56   76.58
## Treatment_bisSmart:SexMale                       158.63     212.13   77.62
## Treatment_bisMixt_smart:SexMale                  124.15     206.95   79.98
## Treatment_bisFull:RegionLuxembourg                43.09     181.96   78.94
## Treatment_bisSmart:RegionLuxembourg              116.45     206.25   77.08
## Treatment_bisMixt_smart:RegionLuxembourg        -475.67     261.97   78.80
## SexMale:Treatment_FTLMix                         395.55     174.60   79.37
## SexMale:Treatment_FTLNight                       261.46     172.80   79.32
## RegionLuxembourg:Treatment_FTLMix                -80.44     210.22   73.79
## RegionLuxembourg:Treatment_FTLNight              383.92     201.32   79.42
## Treatment_bisFull:Treatment_FTLMix              -254.14     227.40   78.12
## Treatment_bisSmart:Treatment_FTLMix              111.69     248.13   75.56
## Treatment_bisMixt_smart:Treatment_FTLMix         373.01     321.18   77.57
## Treatment_bisFull:Treatment_FTLNight            -116.86     208.71   75.57
## Treatment_bisSmart:Treatment_FTLNight           -117.89     245.11   75.44
## Treatment_bisMixt_smart:Treatment_FTLNight        47.29     264.99   79.93
## SexMale:Light_orientationSouth                   -10.58     150.85   76.45
## RegionLuxembourg:Light_orientationSouth          170.86     144.60   76.34
## Treatment_bisFull:Light_orientationSouth         249.55     177.39   78.48
## Treatment_bisSmart:Light_orientationSouth         -8.84     208.22   78.96
## Treatment_bisMixt_smart:Light_orientationSouth   324.77     219.53   79.91
##                                                t value Pr(>|t|)    
## (Intercept)                                      4.362 5.33e-05 ***
## Treatment_bisFull                               -1.440   0.1540    
## Treatment_bisSmart                              -0.917   0.3619    
## Treatment_bisMixt_smart                         -0.616   0.5394    
## SexMale                                         -2.286   0.0250 *  
## RegionLuxembourg                                -1.706   0.0945 .  
## Treatment_FTLMix                                -0.962   0.3395    
## Treatment_FTLNight                              -2.541   0.0131 *  
## Light_orientationSouth                          -1.866   0.0660 .  
## Treatment_bisFull:SexMale                        1.503   0.1370    
## Treatment_bisSmart:SexMale                       0.748   0.4568    
## Treatment_bisMixt_smart:SexMale                  0.600   0.5503    
## Treatment_bisFull:RegionLuxembourg               0.237   0.8134    
## Treatment_bisSmart:RegionLuxembourg              0.565   0.5740    
## Treatment_bisMixt_smart:RegionLuxembourg        -1.816   0.0732 .  
## SexMale:Treatment_FTLMix                         2.265   0.0262 *  
## SexMale:Treatment_FTLNight                       1.513   0.1342    
## RegionLuxembourg:Treatment_FTLMix               -0.383   0.7031    
## RegionLuxembourg:Treatment_FTLNight              1.907   0.0601 .  
## Treatment_bisFull:Treatment_FTLMix              -1.118   0.2672    
## Treatment_bisSmart:Treatment_FTLMix              0.450   0.6539    
## Treatment_bisMixt_smart:Treatment_FTLMix         1.161   0.2490    
## Treatment_bisFull:Treatment_FTLNight            -0.560   0.5772    
## Treatment_bisSmart:Treatment_FTLNight           -0.481   0.6319    
## Treatment_bisMixt_smart:Treatment_FTLNight       0.178   0.8588    
## SexMale:Light_orientationSouth                  -0.070   0.9443    
## RegionLuxembourg:Light_orientationSouth          1.182   0.2410    
## Treatment_bisFull:Light_orientationSouth         1.407   0.1634    
## Treatment_bisSmart:Light_orientationSouth       -0.042   0.9662    
## Treatment_bisMixt_smart:Light_orientationSouth   1.479   0.1430    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 30 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Vérification des hypothèses

Normalité

qqnorm(resid(LM_First_move))
qqline(resid(LM_First_move))

Il faudrait modifier les données

LM_First_move <- lmer(log(First_move+0.1) ~ Treatment_bis + Sex  + Region + Treatment_FTL + Light_orientation + (1|Mother) + (1|Site) + (1|Room)  + Treatment_bis:Sex + Treatment_bis:Region + Treatment_FTL:Sex + Treatment_FTL:Region + Treatment_FTL:Treatment_bis + Light_orientation:Sex + Light_orientation:Region + Light_orientation:Treatment_bis, data = Data )
## boundary (singular) fit: see help('isSingular')
summary(LM_First_move)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: 
## log(First_move + 0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL +  
##     Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) +  
##     Treatment_bis:Sex + Treatment_bis:Region + Treatment_FTL:Sex +  
##     Treatment_FTL:Region + Treatment_FTL:Treatment_bis + Light_orientation:Sex +  
##     Light_orientation:Region + Light_orientation:Treatment_bis
##    Data: Data
## 
## REML criterion at convergence: 412.8
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.4888 -0.3715  0.1588  0.5251  1.6406 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 4.339e-01 6.587e-01
##  Site     (Intercept) 5.221e-01 7.226e-01
##  Room     (Intercept) 1.182e-09 3.438e-05
##  Residual             4.506e+00 2.123e+00
## Number of obs: 110, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                                Estimate Std. Error      df
## (Intercept)                                      7.0093     1.2658 58.2166
## Treatment_bisFull                               -0.8821     1.2254 71.2361
## Treatment_bisSmart                              -0.8169     1.5713 73.9684
## Treatment_bisMixt_smart                         -1.2066     1.5980 73.0403
## SexMale                                         -2.5582     1.1050 73.9849
## RegionLuxembourg                                -0.4689     1.3430 46.9051
## Treatment_FTLMix                                -2.6393     1.3760 65.5602
## Treatment_FTLNight                              -4.1603     1.4028 73.8812
## Light_orientationSouth                           0.1262     0.9779 67.8600
## Treatment_bisFull:SexMale                        2.1444     1.1716 72.3734
## Treatment_bisSmart:SexMale                       0.6633     1.4241 77.9840
## Treatment_bisMixt_smart:SexMale                  2.6338     1.3761 77.7271
## Treatment_bisFull:RegionLuxembourg              -2.1795     1.2055 73.9313
## Treatment_bisSmart:RegionLuxembourg             -0.2561     1.3775 76.4981
## Treatment_bisMixt_smart:RegionLuxembourg        -4.5323     1.7410 75.6100
## SexMale:Treatment_FTLMix                         2.5951     1.1606 76.6476
## SexMale:Treatment_FTLNight                       1.1313     1.1640 78.8548
## RegionLuxembourg:Treatment_FTLMix                0.2617     1.4057 72.0367
## RegionLuxembourg:Treatment_FTLNight              0.1334     1.3392 77.6288
## Treatment_bisFull:Treatment_FTLMix              -1.4817     1.5160 76.8144
## Treatment_bisSmart:Treatment_FTLMix              1.4552     1.6502 72.5063
## Treatment_bisMixt_smart:Treatment_FTLMix         2.0905     2.1532 77.5942
## Treatment_bisFull:Treatment_FTLNight             0.6639     1.4012 76.3098
## Treatment_bisSmart:Treatment_FTLNight            2.1800     1.6319 73.9299
## Treatment_bisMixt_smart:Treatment_FTLNight       2.5614     1.7628 77.6015
## SexMale:Light_orientationSouth                   0.0626     1.0080 75.9717
## RegionLuxembourg:Light_orientationSouth          1.7505     0.9583 70.6591
## Treatment_bisFull:Light_orientationSouth        -0.2312     1.1797 74.6924
## Treatment_bisSmart:Light_orientationSouth       -1.2774     1.3818 76.1052
## Treatment_bisMixt_smart:Light_orientationSouth  -0.1748     1.4546 75.4273
##                                                t value Pr(>|t|)    
## (Intercept)                                      5.537 7.71e-07 ***
## Treatment_bisFull                               -0.720  0.47397    
## Treatment_bisSmart                              -0.520  0.60469    
## Treatment_bisMixt_smart                         -0.755  0.45264    
## SexMale                                         -2.315  0.02339 *  
## RegionLuxembourg                                -0.349  0.72852    
## Treatment_FTLMix                                -1.918  0.05945 .  
## Treatment_FTLNight                              -2.966  0.00406 ** 
## Light_orientationSouth                           0.129  0.89772    
## Treatment_bisFull:SexMale                        1.830  0.07133 .  
## Treatment_bisSmart:SexMale                       0.466  0.64268    
## Treatment_bisMixt_smart:SexMale                  1.914  0.05931 .  
## Treatment_bisFull:RegionLuxembourg              -1.808  0.07469 .  
## Treatment_bisSmart:RegionLuxembourg             -0.186  0.85298    
## Treatment_bisMixt_smart:RegionLuxembourg        -2.603  0.01111 *  
## SexMale:Treatment_FTLMix                         2.236  0.02826 *  
## SexMale:Treatment_FTLNight                       0.972  0.33408    
## RegionLuxembourg:Treatment_FTLMix                0.186  0.85282    
## RegionLuxembourg:Treatment_FTLNight              0.100  0.92094    
## Treatment_bisFull:Treatment_FTLMix              -0.977  0.33144    
## Treatment_bisSmart:Treatment_FTLMix              0.882  0.38080    
## Treatment_bisMixt_smart:Treatment_FTLMix         0.971  0.33462    
## Treatment_bisFull:Treatment_FTLNight             0.474  0.63698    
## Treatment_bisSmart:Treatment_FTLNight            1.336  0.18569    
## Treatment_bisMixt_smart:Treatment_FTLNight       1.453  0.15025    
## SexMale:Light_orientationSouth                   0.062  0.95064    
## RegionLuxembourg:Light_orientationSouth          1.827  0.07196 .  
## Treatment_bisFull:Light_orientationSouth        -0.196  0.84514    
## Treatment_bisSmart:Light_orientationSouth       -0.924  0.35819    
## Treatment_bisMixt_smart:Light_orientationSouth  -0.120  0.90468    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 30 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
qqnorm(resid(LM_First_move))
qqline(resid(LM_First_move))

Homogénité des variances

plot(LM_First_move)

Distance de cook

plot(cooks.distance(LM_First_move))

5.4.2 Simplification du modèle

drop1(LM_First_move)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(First_move + 0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + Treatment_FTL:Sex + Treatment_FTL:Region + Treatment_FTL:Treatment_bis + Light_orientation:Sex + Light_orientation:Region + Light_orientation:Treatment_bis
##                                 Sum Sq Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Sex               22.660  7.5535     3 76.888  1.6764 0.17906  
## Treatment_bis:Region            37.137 12.3790     3 75.715  2.7473 0.04868 *
## Sex:Treatment_FTL               22.572 11.2859     2 71.505  2.5047 0.08884 .
## Region:Treatment_FTL             0.159  0.0796     2 74.993  0.0177 0.98249  
## Treatment_bis:Treatment_FTL     29.184  4.8639     6 75.409  1.0795 0.38243  
## Sex:Light_orientation            0.017  0.0174     1 75.972  0.0039 0.95064  
## Region:Light_orientation        15.037 15.0366     1 70.659  3.3371 0.07196 .
## Treatment_bis:Light_orientation  4.068  1.3561     3 75.275  0.3010 0.82460  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_First_move1 <- update(LM_First_move, . ~ . - Region:Treatment_FTL)
## boundary (singular) fit: see help('isSingular')
drop1(LM_First_move1)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(First_move + 0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + Sex:Treatment_FTL + Treatment_bis:Treatment_FTL + Sex:Light_orientation + Region:Light_orientation + Treatment_bis:Light_orientation
##                                 Sum Sq Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Sex               23.224  7.7413     3 78.707  1.7698 0.15974  
## Treatment_bis:Region            38.601 12.8670     3 77.447  2.9417 0.03824 *
## Sex:Treatment_FTL               22.889 11.4444     2 76.052  2.6165 0.07963 .
## Treatment_bis:Treatment_FTL     29.183  4.8638     6 76.491  1.1120 0.36330  
## Sex:Light_orientation            0.011  0.0106     1 77.518  0.0024 0.96090  
## Region:Light_orientation        15.062 15.0621     1 72.914  3.4436 0.06754 .
## Treatment_bis:Light_orientation  4.224  1.4081     3 76.754  0.3219 0.80948  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_First_move2 <- update(LM_First_move1, . ~ . - Sex:Light_orientation)
## boundary (singular) fit: see help('isSingular')
drop1(LM_First_move2)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(First_move + 0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + Sex:Treatment_FTL + Treatment_bis:Treatment_FTL + Region:Light_orientation + Treatment_bis:Light_orientation
##                                 Sum Sq Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Sex               23.959  7.9864     3 79.415  1.8520 0.14451  
## Treatment_bis:Region            41.926 13.9753     3 78.400  3.2408 0.02647 *
## Sex:Treatment_FTL               22.933 11.4665     2 76.613  2.6590 0.07647 .
## Treatment_bis:Treatment_FTL     29.073  4.8455     6 77.078  1.1237 0.35659  
## Region:Light_orientation        15.332 15.3324     1 73.526  3.5555 0.06330 .
## Treatment_bis:Light_orientation  4.251  1.4169     3 77.792  0.3286 0.80469  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_First_move3 <- update(LM_First_move2, . ~ . - Treatment_bis:Light_orientation)
## boundary (singular) fit: see help('isSingular')
drop1(LM_First_move3)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(First_move + 0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + Sex:Treatment_FTL + Treatment_bis:Treatment_FTL + Region:Light_orientation
##                             Sum Sq Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Sex           23.805  7.9351     3 81.374  1.9038 0.13548  
## Treatment_bis:Region        45.456 15.1519     3 80.047  3.6352 0.01628 *
## Sex:Treatment_FTL           23.558 11.7789     2 79.331  2.8259 0.06523 .
## Treatment_bis:Treatment_FTL 28.802  4.8004     6 79.747  1.1517 0.34064  
## Region:Light_orientation    13.051 13.0506     1 78.725  3.1310 0.08069 .
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_First_move4 <- update(LM_First_move3, . ~ . - Treatment_bis:Treatment_FTL)
## boundary (singular) fit: see help('isSingular')
drop1(LM_First_move4)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(First_move + 0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + Sex:Treatment_FTL + Region:Light_orientation
##                          Sum Sq Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Sex        15.606  5.2019     3 85.993  1.2522 0.29596  
## Treatment_bis:Region     47.956 15.9853     3 83.084  3.8480 0.01243 *
## Sex:Treatment_FTL        18.350  9.1748     2 84.366  2.2086 0.11617  
## Region:Light_orientation 12.109 12.1086     1 81.931  2.9148 0.09156 .
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_First_move5 <- update(LM_First_move4, . ~ . - Treatment_bis:Sex)
## boundary (singular) fit: see help('isSingular')
drop1(LM_First_move5)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(First_move + 0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region + Sex:Treatment_FTL + Region:Light_orientation
##                          Sum Sq Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Region     50.735 16.9117     3 86.466  3.9706 0.01058 *
## Sex:Treatment_FTL        16.393  8.1964     2 81.997  1.9244 0.15250  
## Region:Light_orientation  7.255  7.2547     1 84.995  1.7033 0.19538  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_First_move6 <- update(LM_First_move5, . ~ . - Region:Light_orientation)
## boundary (singular) fit: see help('isSingular')
drop1(LM_First_move6)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(First_move + 0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region + Sex:Treatment_FTL
##                      Sum Sq Mean Sq NumDF  DenDF F value Pr(>F)  
## Light_orientation     9.249  9.2491     1 87.893  2.1637 0.1449  
## Treatment_bis:Region 46.640 15.5467     3 87.199  3.6369 0.0159 *
## Sex:Treatment_FTL    14.555  7.2776     2 83.571  1.7025 0.1885  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_First_move7 <- update(LM_First_move6, . ~ . - Sex:Treatment_FTL)
## boundary (singular) fit: see help('isSingular')
drop1(LM_First_move7)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(First_move + 0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region
##                      Sum Sq Mean Sq NumDF  DenDF F value    Pr(>F)    
## Sex                   0.387   0.387     1 87.951  0.0882 0.7672263    
## Treatment_FTL        76.880  38.440     2 91.904  8.7512 0.0003319 ***
## Light_orientation     8.768   8.768     1 87.578  1.9960 0.1612546    
## Treatment_bis:Region 46.540  15.513     3 89.420  3.5318 0.0179941 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Le modèle ne sait pas être plus simplifié. Au vu de la complexité du modèle initial (nombre de paramètres), nous choisissons d’utiliser le BIC et non le AIC.

BIC(LM_First_move7)
## [1] 543.0197
BIC(LM_First_move)
## [1] 572.6645

La simplification fu utile

LM_First_move <- LM_First_move7

5.4.3 Treatment VS Teatment_bis

AIC(lmer(log(First_move+0.1) ~ Treatment_bis + Region + Treatment_FTL + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region  , data = Data))
## boundary (singular) fit: see help('isSingular')
## [1] 507.9532
AIC(lmer(log(First_move+0.1) ~ Treatment + Region + Treatment_FTL + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment:Region + Treatment:Treatment_FTL, data = Data))
## boundary (singular) fit: see help('isSingular')
## [1] 509.7186
summary(lmer(log(First_move+0.1) ~ Treatment_bis + Region + Treatment_FTL + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region  , data = Data))$coeff
## boundary (singular) fit: see help('isSingular')
##                                            Estimate Std. Error        df
## (Intercept)                               5.2089785  0.7070051  35.25734
## Treatment_bisFull                         0.2318253  0.7397706  98.96286
## Treatment_bisSmart                        0.2418912  0.9949686  98.11955
## Treatment_bisMixt_smart                   1.1429676  0.8171949  96.35274
## RegionLuxembourg                          0.3409024  0.9237476  36.19606
## Treatment_FTLMix                         -0.7839194  0.6269590  91.45414
## Treatment_FTLNight                       -2.2068127  0.5749287  98.40990
## Treatment_bisFull:RegionLuxembourg       -2.1083257  1.1350375 100.28573
## Treatment_bisSmart:RegionLuxembourg      -0.1494290  1.3088747  97.84767
## Treatment_bisMixt_smart:RegionLuxembourg -3.2354127  1.2835300  99.19832
##                                             t value     Pr(>|t|)
## (Intercept)                               7.3676671 1.233474e-08
## Treatment_bisFull                         0.3133746 7.546556e-01
## Treatment_bisSmart                        0.2431144 8.084243e-01
## Treatment_bisMixt_smart                   1.3986475 1.651293e-01
## RegionLuxembourg                          0.3690428 7.142459e-01
## Treatment_FTLMix                         -1.2503519 2.143608e-01
## Treatment_FTLNight                       -3.8384113 2.189820e-04
## Treatment_bisFull:RegionLuxembourg       -1.8574943 6.617505e-02
## Treatment_bisSmart:RegionLuxembourg      -0.1141660 9.093401e-01
## Treatment_bisMixt_smart:RegionLuxembourg -2.5207145 1.330579e-02
summary(lmer(log(First_move+0.1) ~ Treatment + Region + Treatment_FTL + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment:Region + Treatment:Treatment_FTL, data = Data))$coeff
## boundary (singular) fit: see help('isSingular')
##                                     Estimate Std. Error       df     t value
## (Intercept)                        5.4386296  0.8232656 49.76561  6.60616609
## TreatmentFull                      0.3972479  1.0178796 97.86447  0.39027006
## TreatmentSmart                     0.2396492  1.0072096 94.92062  0.23793381
## RegionLuxembourg                   0.3700720  0.9097715 35.59608  0.40677465
## Treatment_FTLMix                  -0.8235021  1.0107187 93.97098 -0.81476877
## Treatment_FTLNight                -2.9587374  1.0395292 98.96126 -2.84622836
## TreatmentFull:RegionLuxembourg    -1.8543897  1.2050088 98.76695 -1.53890139
## TreatmentSmart:RegionLuxembourg   -1.8460948  1.1344830 95.55353 -1.62725652
## TreatmentFull:Treatment_FTLMix    -0.9284983  1.4436577 98.16350 -0.64315684
## TreatmentSmart:Treatment_FTLMix    0.3459947  1.3760586 94.88229  0.25143893
## TreatmentFull:Treatment_FTLNight   0.1089596  1.3981629 94.34781  0.07793054
## TreatmentSmart:Treatment_FTLNight  1.7810445  1.3614548 96.56456  1.30819221
##                                       Pr(>|t|)
## (Intercept)                       2.530559e-08
## TreatmentFull                     6.971850e-01
## TreatmentSmart                    8.124453e-01
## RegionLuxembourg                  6.866091e-01
## Treatment_FTLMix                  4.172648e-01
## Treatment_FTLNight                5.378669e-03
## TreatmentFull:RegionLuxembourg    1.270261e-01
## TreatmentSmart:RegionLuxembourg   1.069759e-01
## TreatmentFull:Treatment_FTLMix    5.216219e-01
## TreatmentSmart:Treatment_FTLMix   8.020185e-01
## TreatmentFull:Treatment_FTLNight  9.380483e-01
## TreatmentSmart:Treatment_FTLNight 1.939136e-01

Le modèle avec treatment_bis est mieux

5.4.4 Résultats

Analyse des pval

summary(lmer(log(First_move+0.1) ~ Treatment_bis + Region + Treatment_FTL + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region  , data = Data))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(First_move + 0.1) ~ Treatment_bis + Region + Treatment_FTL +  
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data
## 
## REML criterion at convergence: 480
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.8092 -0.3300  0.1791  0.5134  2.1774 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.0000   0.0000  
##  Site     (Intercept) 0.5351   0.7315  
##  Room     (Intercept) 0.0000   0.0000  
##  Residual             4.9097   2.2158  
## Number of obs: 111, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                          Estimate Std. Error       df t value
## (Intercept)                                5.2090     0.7070  35.2573   7.368
## Treatment_bisFull                          0.2318     0.7398  98.9629   0.313
## Treatment_bisSmart                         0.2419     0.9950  98.1195   0.243
## Treatment_bisMixt_smart                    1.1430     0.8172  96.3527   1.399
## RegionLuxembourg                           0.3409     0.9237  36.1961   0.369
## Treatment_FTLMix                          -0.7839     0.6270  91.4541  -1.250
## Treatment_FTLNight                        -2.2068     0.5749  98.4099  -3.838
## Treatment_bisFull:RegionLuxembourg        -2.1083     1.1350 100.2857  -1.857
## Treatment_bisSmart:RegionLuxembourg       -0.1494     1.3089  97.8477  -0.114
## Treatment_bisMixt_smart:RegionLuxembourg  -3.2354     1.2835  99.1983  -2.521
##                                          Pr(>|t|)    
## (Intercept)                              1.23e-08 ***
## Treatment_bisFull                        0.754656    
## Treatment_bisSmart                       0.808424    
## Treatment_bisMixt_smart                  0.165129    
## RegionLuxembourg                         0.714246    
## Treatment_FTLMix                         0.214361    
## Treatment_FTLNight                       0.000219 ***
## Treatment_bisFull:RegionLuxembourg       0.066175 .  
## Treatment_bisSmart:RegionLuxembourg      0.909340    
## Treatment_bisMixt_smart:RegionLuxembourg 0.013306 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ RgnLxm T_FTLM T_FTLN T_F:RL T_S:RL
## Trtmnt_bsFl -0.594                                                        
## Trtmnt_bsSm -0.384  0.368                                                 
## Trtmnt_bsM_ -0.535  0.471  0.324                                          
## ReginLxmbrg -0.581  0.415  0.294  0.359                                   
## Trtmnt_FTLM -0.416  0.125  0.013  0.170 -0.055                            
## Trtmnt_FTLN -0.380  0.038 -0.013  0.043 -0.072  0.592                     
## Trtmnt_F:RL  0.409 -0.659 -0.241 -0.316 -0.627 -0.136 -0.056              
## Trtmnt_S:RL  0.304 -0.280 -0.760 -0.246 -0.525 -0.026 -0.025  0.438       
## Trtmn_M_:RL  0.403 -0.321 -0.209 -0.665 -0.526 -0.266 -0.106  0.478  0.370
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(First_move+0.1) ~ Treatment_bis + Region + Treatment_FTL + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region  , data = Data_ref_full))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(First_move + 0.1) ~ Treatment_bis + Region + Treatment_FTL +  
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_ref_full
## 
## REML criterion at convergence: 480
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.8092 -0.3300  0.1791  0.5134  2.1774 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.0000   0.0000  
##  Site     (Intercept) 0.5351   0.7315  
##  Room     (Intercept) 0.0000   0.0000  
##  Residual             4.9097   2.2158  
## Number of obs: 111, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                           Estimate Std. Error        df t value
## (Intercept)                                5.44080    0.65277  36.54084   8.335
## Treatment_bisDark                         -0.23183    0.73977  98.96286  -0.313
## Treatment_bisSmart                         0.01007    0.99762  98.26004   0.010
## Treatment_bisMixt_smart                    0.91114    0.80336  95.52516   1.134
## RegionLuxembourg                          -1.76742    0.90895  39.74323  -1.944
## Treatment_FTLMix                          -0.78392    0.62696  91.45414  -1.250
## Treatment_FTLNight                        -2.20681    0.57493  98.40990  -3.838
## Treatment_bisDark:RegionLuxembourg         2.10833    1.13504 100.28573   1.857
## Treatment_bisSmart:RegionLuxembourg        1.95890    1.30343  97.87396   1.503
## Treatment_bisMixt_smart:RegionLuxembourg  -1.12709    1.24215  99.02967  -0.907
##                                          Pr(>|t|)    
## (Intercept)                              5.65e-10 ***
## Treatment_bisDark                        0.754656    
## Treatment_bisSmart                       0.991970    
## Treatment_bisMixt_smart                  0.259562    
## RegionLuxembourg                         0.058941 .  
## Treatment_FTLMix                         0.214361    
## Treatment_FTLNight                       0.000219 ***
## Treatment_bisDark:RegionLuxembourg       0.066175 .  
## Treatment_bisSmart:RegionLuxembourg      0.136090    
## Treatment_bisMixt_smart:RegionLuxembourg 0.366416    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S Trt_M_ RgnLxm T_FTLM T_FTLN T_D:RL T_S:RL
## Trtmnt_bsDr -0.490                                                        
## Trtmnt_bsSm -0.363  0.374                                                 
## Trtmnt_bsM_ -0.498  0.442  0.318                                          
## ReginLxmbrg -0.539  0.400  0.295  0.337                                   
## Trtmnt_FTLM -0.309 -0.125 -0.080  0.058 -0.225                            
## Trtmnt_FTLN -0.368 -0.038 -0.041  0.009 -0.143  0.592                     
## Trtmnt_D:RL  0.303 -0.659 -0.248 -0.285 -0.611  0.136  0.056              
## Trtmnt_S:RL  0.275 -0.292 -0.768 -0.240 -0.518  0.092  0.024  0.431       
## Trtmn_M_:RL  0.353 -0.271 -0.196 -0.654 -0.494 -0.151 -0.058  0.420  0.347
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(First_move+0.1) ~ Treatment_bis + Region + Treatment_FTL + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region  , data = Data_ref_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(First_move + 0.1) ~ Treatment_bis + Region + Treatment_FTL +  
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_ref_smart
## 
## REML criterion at convergence: 480
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.8092 -0.3300  0.1791  0.5134  2.1774 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 0.000e+00 0.000e+00
##  Site     (Intercept) 5.351e-01 7.315e-01
##  Room     (Intercept) 1.373e-09 3.705e-05
##  Residual             4.910e+00 2.216e+00
## Number of obs: 111, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                           Estimate Std. Error        df t value
## (Intercept)                                5.45087    0.97418  72.13485   5.595
## Treatment_bisDark                         -0.24189    0.99497  98.11955  -0.243
## Treatment_bisFull                         -0.01007    0.99762  98.26005  -0.010
## Treatment_bisMixt_smart                    0.90108    1.06369  99.13439   0.847
## RegionLuxembourg                           0.19147    1.13875  65.94407   0.168
## Treatment_FTLMix                          -0.78392    0.62696  91.45416  -1.250
## Treatment_FTLNight                        -2.20681    0.57493  98.40991  -3.838
## Treatment_bisDark:RegionLuxembourg         0.14943    1.30887  97.84767   0.114
## Treatment_bisFull:RegionLuxembourg        -1.95890    1.30343  97.87397  -1.503
## Treatment_bisMixt_smart:RegionLuxembourg  -3.08598    1.45517 100.53028  -2.121
##                                          Pr(>|t|)    
## (Intercept)                              3.73e-07 ***
## Treatment_bisDark                        0.808424    
## Treatment_bisFull                        0.991970    
## Treatment_bisMixt_smart                  0.398968    
## RegionLuxembourg                         0.866984    
## Treatment_FTLMix                         0.214361    
## Treatment_FTLNight                       0.000219 ***
## Treatment_bisDark:RegionLuxembourg       0.909340    
## Treatment_bisFull:RegionLuxembourg       0.136090    
## Treatment_bisMixt_smart:RegionLuxembourg 0.036407 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trt_M_ RgnLxm T_FTLM T_FTLN T_D:RL T_F:RL
## Trtmnt_bsDr -0.742                                                        
## Trtmnt_bsFl -0.781  0.724                                                 
## Trtmnt_bsM_ -0.739  0.687  0.698                                          
## ReginLxmbrg -0.737  0.635  0.644  0.600                                   
## Trtmnt_FTLM -0.288 -0.013  0.080  0.118 -0.075                            
## Trtmnt_FTLN -0.289  0.013  0.041  0.046 -0.087  0.592                     
## Trtmnt_D:RL  0.555 -0.760 -0.550 -0.521 -0.723  0.026  0.025              
## Trtmnt_F:RL  0.602 -0.553 -0.768 -0.539 -0.731 -0.092 -0.024  0.622       
## Trtmn_M_:RL  0.570 -0.499 -0.520 -0.747 -0.652 -0.211 -0.071  0.573  0.599
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(First_move+0.1) ~ Treatment_bis + Region + Treatment_FTL + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region  , data = Data_ref_mixt_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(First_move + 0.1) ~ Treatment_bis + Region + Treatment_FTL +  
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_ref_mixt_smart
## 
## REML criterion at convergence: 480
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.8092 -0.3300  0.1791  0.5134  2.1774 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 1.293e-14 1.137e-07
##  Site     (Intercept) 5.351e-01 7.315e-01
##  Room     (Intercept) 0.000e+00 0.000e+00
##  Residual             4.910e+00 2.216e+00
## Number of obs: 111, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                     Estimate Std. Error       df t value
## (Intercept)                           6.3519     0.7409  50.0093   8.573
## Treatment_bisDark                    -1.1430     0.8172  96.3527  -1.399
## Treatment_bisFull                    -0.9111     0.8034  95.5252  -1.134
## Treatment_bisSmart                   -0.9011     1.0637  99.1344  -0.847
## RegionLuxembourg                     -2.8945     1.1194  54.9316  -2.586
## Treatment_FTLMix                     -0.7839     0.6270  91.4541  -1.250
## Treatment_FTLNight                   -2.2068     0.5749  98.4099  -3.838
## Treatment_bisDark:RegionLuxembourg    3.2354     1.2835  99.1983   2.521
## Treatment_bisFull:RegionLuxembourg    1.1271     1.2422  99.0297   0.907
## Treatment_bisSmart:RegionLuxembourg   3.0860     1.4552 100.5303   2.121
##                                     Pr(>|t|)    
## (Intercept)                         2.18e-11 ***
## Treatment_bisDark                   0.165129    
## Treatment_bisFull                   0.259562    
## Treatment_bisSmart                  0.398968    
## RegionLuxembourg                    0.012398 *  
## Treatment_FTLMix                    0.214361    
## Treatment_FTLNight                  0.000219 ***
## Treatment_bisDark:RegionLuxembourg  0.013306 *  
## Treatment_bisFull:RegionLuxembourg  0.366416    
## Treatment_bisSmart:RegionLuxembourg 0.036407 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trtm_S RgnLxm T_FTLM T_FTLN T_D:RL T_F:RL
## Trtmnt_bsDr -0.592                                                        
## Trtmnt_bsFl -0.645  0.583                                                 
## Trtmnt_bsSm -0.464  0.466  0.457                                          
## ReginLxmbrg -0.530  0.466  0.452  0.361                                   
## Trtmnt_FTLM -0.209 -0.170 -0.058 -0.118 -0.350                            
## Trtmnt_FTLN -0.315 -0.043 -0.009 -0.046 -0.181  0.592                     
## Trtmnt_D:RL  0.348 -0.665 -0.381 -0.316 -0.712  0.266  0.106              
## Trtmnt_F:RL  0.398 -0.398 -0.654 -0.310 -0.708  0.151  0.058  0.597       
## Trtmnt_S:RL  0.324 -0.365 -0.343 -0.747 -0.637  0.211  0.071  0.549  0.543
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(First_move+0.1) ~ Treatment_bis + Region + Treatment_FTL + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region  , data = Data_refFTL_Night))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(First_move + 0.1) ~ Treatment_bis + Region + Treatment_FTL +  
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_refFTL_Night
## 
## REML criterion at convergence: 480
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.8092 -0.3300  0.1791  0.5134  2.1774 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.0000   0.0000  
##  Site     (Intercept) 0.5352   0.7315  
##  Room     (Intercept) 0.0000   0.0000  
##  Residual             4.9097   2.2158  
## Number of obs: 111, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                          Estimate Std. Error       df t value
## (Intercept)                                3.0022     0.7223  37.8438   4.156
## Treatment_bisFull                          0.2318     0.7398  98.9629   0.313
## Treatment_bisSmart                         0.2419     0.9950  98.1196   0.243
## Treatment_bisMixt_smart                    1.1430     0.8172  96.3528   1.399
## RegionLuxembourg                           0.3409     0.9238  36.1954   0.369
## Treatment_FTLDay                           2.2068     0.5749  98.4100   3.838
## Treatment_FTLMix                           1.4229     0.5450 100.0072   2.611
## Treatment_bisFull:RegionLuxembourg        -2.1083     1.1350 100.2858  -1.857
## Treatment_bisSmart:RegionLuxembourg       -0.1494     1.3089  97.8477  -0.114
## Treatment_bisMixt_smart:RegionLuxembourg  -3.2354     1.2835  99.1984  -2.521
##                                          Pr(>|t|)    
## (Intercept)                              0.000178 ***
## Treatment_bisFull                        0.754657    
## Treatment_bisSmart                       0.808426    
## Treatment_bisMixt_smart                  0.165130    
## RegionLuxembourg                         0.714244    
## Treatment_FTLDay                         0.000219 ***
## Treatment_FTLMix                         0.010426 *  
## Treatment_bisFull:RegionLuxembourg       0.066175 .  
## Treatment_bisSmart:RegionLuxembourg      0.909342    
## Treatment_bisMixt_smart:RegionLuxembourg 0.013306 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ RgnLxm T_FTLD T_FTLM T_F:RL T_S:RL
## Trtmnt_bsFl -0.551                                                        
## Trtmnt_bsSm -0.387  0.368                                                 
## Trtmnt_bsM_ -0.490  0.471  0.324                                          
## ReginLxmbrg -0.626  0.415  0.294  0.359                                   
## Trtmnt_FTLD -0.424 -0.038  0.013 -0.043  0.072                            
## Trtmnt_FTLM -0.375  0.104  0.029  0.150  0.012  0.374                     
## Trtmnt_F:RL  0.356 -0.659 -0.241 -0.316 -0.627  0.056 -0.097              
## Trtmnt_S:RL  0.278 -0.280 -0.760 -0.246 -0.525  0.025 -0.004  0.438       
## Trtmn_M_:RL  0.311 -0.321 -0.209 -0.665 -0.526  0.106 -0.194  0.478  0.370
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(First_move+0.1) ~ Treatment_bis + Region + Treatment_FTL + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region  , data = Data_refFTL_Mix))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(First_move + 0.1) ~ Treatment_bis + Region + Treatment_FTL +  
##     (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_refFTL_Mix
## 
## REML criterion at convergence: 480
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.8094 -0.3299  0.1791  0.5134  2.1771 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 1.775e-08 0.0001332
##  Site     (Intercept) 5.346e-01 0.7311879
##  Room     (Intercept) 3.925e-07 0.0006265
##  Residual             4.910e+00 2.2158406
## Number of obs: 111, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                          Estimate Std. Error       df t value
## (Intercept)                                4.4251     0.7237  33.8659   6.115
## Treatment_bisFull                          0.2319     0.7398  98.9610   0.313
## Treatment_bisSmart                         0.2420     0.9950  98.1165   0.243
## Treatment_bisMixt_smart                    1.1430     0.8172  96.3498   1.399
## RegionLuxembourg                           0.3408     0.9237  36.2166   0.369
## Treatment_FTLDay                           0.7838     0.6269  91.4462   1.250
## Treatment_FTLNight                        -1.4229     0.5450 100.0065  -2.611
## Treatment_bisFull:RegionLuxembourg        -2.1083     1.1350 100.2848  -1.857
## Treatment_bisSmart:RegionLuxembourg       -0.1495     1.3089  97.8454  -0.114
## Treatment_bisMixt_smart:RegionLuxembourg  -3.2354     1.2835  99.1970  -2.521
##                                          Pr(>|t|)    
## (Intercept)                              6.21e-07 ***
## Treatment_bisFull                          0.7546    
## Treatment_bisSmart                         0.8084    
## Treatment_bisMixt_smart                    0.1651    
## RegionLuxembourg                           0.7143    
## Treatment_FTLDay                           0.2144    
## Treatment_FTLNight                         0.0104 *  
## Treatment_bisFull:RegionLuxembourg         0.0662 .  
## Treatment_bisSmart:RegionLuxembourg        0.9093    
## Treatment_bisMixt_smart:RegionLuxembourg   0.0133 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ RgnLxm T_FTLD T_FTLN T_F:RL T_S:RL
## Trtmnt_bsFl -0.471                                                        
## Trtmnt_bsSm -0.364  0.368                                                 
## Trtmnt_bsM_ -0.375  0.471  0.324                                          
## ReginLxmbrg -0.615  0.415  0.294  0.359                                   
## Trtmnt_FTLD -0.460 -0.125 -0.013 -0.170  0.055                            
## Trtmnt_FTLN -0.379 -0.104 -0.029 -0.150 -0.012  0.526                     
## Trtmnt_F:RL  0.282 -0.659 -0.241 -0.316 -0.627  0.136  0.097              
## Trtmnt_S:RL  0.274 -0.280 -0.760 -0.246 -0.525  0.026  0.004  0.438       
## Trtmn_M_:RL  0.164 -0.321 -0.209 -0.665 -0.526  0.266  0.194  0.478  0.370
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
test1 <- data.frame(Reference_Treatment = "Dark", Reference_Timing = "Day", as.data.frame(( summary(lmer(log(First_move+0.1) ~ Treatment_bis + Region + Treatment_FTL + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region  , data = Data))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test2 <- data.frame(Reference_Treatment = "Smart", Reference_Timing = "Day", as.data.frame(( summary(lmer(log(First_move+0.1) ~ Treatment_bis + Region + Treatment_FTL + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region  , data = Data_ref_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test3 <- data.frame(Reference_Treatment = "Full", Reference_Timing = "Day", as.data.frame(( summary(lmer(log(First_move+0.1) ~ Treatment_bis + Region + Treatment_FTL + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region  , data = Data_ref_full))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test4 <- data.frame(Reference_Treatment = "Mixt_smart", Reference_Timing = "Day", as.data.frame(( summary(lmer(log(First_move+0.1) ~ Treatment_bis + Region + Treatment_FTL + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region  , data = Data_ref_mixt_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test5 <- data.frame(Reference_Treatment = "Dark", Reference_Timing = "Mixt", as.data.frame(( summary(lmer(log(First_move+0.1) ~ Treatment_bis + Region + Treatment_FTL + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region  , data = Data_refFTL_Mix))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test6 <- data.frame(Reference_Treatment = "Dark", Reference_Timing = "Night", as.data.frame(( summary(lmer(log(First_move+0.1) ~ Treatment_bis + Region + Treatment_FTL + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region  , data = Data_refFTL_Night))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
Results_First_move <- rbind(test1,test2,test3,test4,test5,test6)

colnames(Results_First_move ) <- c("Reference_Treatment", "Reference_Timing" ,"Estimate", "Std. Error", "df", "t.value", "Pr(>|z|)")

write.csv2( Results_First_move , file = "output/Results_First_move.csv" )

kable(Results_First_move , caption = " Temps mis pour faire le premier mouvement ", padding = 1 )
Temps mis pour faire le premier mouvement
Reference_Treatment Reference_Timing Estimate Std. Error df t.value Pr(>|z|)
(Intercept) Dark Day 5.2089785 0.7070051 35.25734 7.3676671 0.0000000
Treatment_bisFull Dark Day 0.2318253 0.7397706 98.96286 0.3133746 0.7546556
Treatment_bisSmart Dark Day 0.2418912 0.9949686 98.11955 0.2431144 0.8084243
Treatment_bisMixt_smart Dark Day 1.1429676 0.8171949 96.35274 1.3986475 0.1651293
RegionLuxembourg Dark Day 0.3409024 0.9237476 36.19606 0.3690428 0.7142459
Treatment_FTLMix Dark Day -0.7839194 0.6269590 91.45414 -1.2503519 0.2143608
Treatment_FTLNight Dark Day -2.2068127 0.5749287 98.40990 -3.8384113 0.0002190
Treatment_bisFull:RegionLuxembourg Dark Day -2.1083257 1.1350375 100.28573 -1.8574943 0.0661750
Treatment_bisSmart:RegionLuxembourg Dark Day -0.1494290 1.3088747 97.84767 -0.1141660 0.9093401
Treatment_bisMixt_smart:RegionLuxembourg Dark Day -3.2354127 1.2835300 99.19832 -2.5207145 0.0133058
(Intercept)1 Smart Day 5.4508696 0.9741807 72.13485 5.5953372 0.0000004
Treatment_bisDark Smart Day -0.2418909 0.9949685 98.11955 -0.2431141 0.8084245
Treatment_bisFull1 Smart Day -0.0100658 0.9976191 98.26005 -0.0100898 0.9919701
Treatment_bisMixt_smart1 Smart Day 0.9010765 1.0636926 99.13439 0.8471212 0.3989680
RegionLuxembourg1 Smart Day 0.1914740 1.1387462 65.94407 0.1681445 0.8669842
Treatment_FTLMix1 Smart Day -0.7839198 0.6269590 91.45416 -1.2503526 0.2143606
Treatment_FTLNight1 Smart Day -2.2068130 0.5749287 98.40991 -3.8384117 0.0002190
Treatment_bisDark:RegionLuxembourg Smart Day 0.1494288 1.3088746 97.84767 0.1141659 0.9093402
Treatment_bisFull:RegionLuxembourg1 Smart Day -1.9588970 1.3034300 97.87397 -1.5028785 0.1360902
Treatment_bisMixt_smart:RegionLuxembourg1 Smart Day -3.0859841 1.4551718 100.53028 -2.1207009 0.0364072
(Intercept)2 Full Day 5.4408039 0.6527680 36.54084 8.3349737 0.0000000
Treatment_bisDark1 Full Day -0.2318253 0.7397706 98.96286 -0.3133746 0.7546556
Treatment_bisSmart1 Full Day 0.0100658 0.9976191 98.26004 0.0100899 0.9919701
Treatment_bisMixt_smart2 Full Day 0.9111423 0.8033576 95.52516 1.1341677 0.2595624
RegionLuxembourg2 Full Day -1.7674233 0.9089518 39.74323 -1.9444632 0.0589410
Treatment_FTLMix2 Full Day -0.7839194 0.6269590 91.45414 -1.2503519 0.2143608
Treatment_FTLNight2 Full Day -2.2068127 0.5749287 98.40990 -3.8384113 0.0002190
Treatment_bisDark:RegionLuxembourg1 Full Day 2.1083257 1.1350375 100.28573 1.8574943 0.0661750
Treatment_bisSmart:RegionLuxembourg1 Full Day 1.9588967 1.3034301 97.87396 1.5028782 0.1360903
Treatment_bisMixt_smart:RegionLuxembourg2 Full Day -1.1270870 1.2421520 99.02967 -0.9073664 0.3664157
(Intercept)3 Mixt_smart Day 6.3519461 0.7409082 50.00933 8.5731890 0.0000000
Treatment_bisDark2 Mixt_smart Day -1.1429676 0.8171949 96.35274 -1.3986475 0.1651293
Treatment_bisFull2 Mixt_smart Day -0.9111423 0.8033576 95.52516 -1.1341677 0.2595624
Treatment_bisSmart2 Mixt_smart Day -0.9010764 1.0636926 99.13440 -0.8471211 0.3989681
RegionLuxembourg3 Mixt_smart Day -2.8945103 1.1193934 54.93158 -2.5857847 0.0123982
Treatment_FTLMix3 Mixt_smart Day -0.7839194 0.6269590 91.45414 -1.2503520 0.2143608
Treatment_FTLNight3 Mixt_smart Day -2.2068127 0.5749287 98.40990 -3.8384113 0.0002190
Treatment_bisDark:RegionLuxembourg2 Mixt_smart Day 3.2354127 1.2835300 99.19832 2.5207145 0.0133058
Treatment_bisFull:RegionLuxembourg2 Mixt_smart Day 1.1270870 1.2421520 99.02967 0.9073664 0.3664157
Treatment_bisSmart:RegionLuxembourg2 Mixt_smart Day 3.0859837 1.4551718 100.53028 2.1207006 0.0364072
(Intercept)4 Dark Mixt 4.4251476 0.7237020 33.86586 6.1145994 0.0000006
Treatment_bisFull3 Dark Mixt 0.2318759 0.7397786 98.96096 0.3134396 0.7546064
Treatment_bisSmart3 Dark Mixt 0.2419635 0.9949815 98.11650 0.2431840 0.8083706
Treatment_bisMixt_smart3 Dark Mixt 1.1430066 0.8172084 96.34984 1.3986721 0.1651220
RegionLuxembourg4 Dark Mixt 0.3407876 0.9236550 36.21661 0.3689555 0.7143092
Treatment_FTLDay Dark Mixt 0.7837835 0.6269438 91.44620 1.2501654 0.2144289
Treatment_FTLNight4 Dark Mixt -1.4229351 0.5450349 100.00655 -2.6107231 0.0104241
Treatment_bisFull:RegionLuxembourg3 Dark Mixt -2.1082937 1.1350447 100.28483 -1.8574543 0.0661808
Treatment_bisSmart:RegionLuxembourg3 Dark Mixt -0.1495026 1.3088923 97.84540 -0.1142207 0.9092969
Treatment_bisMixt_smart:RegionLuxembourg3 Dark Mixt -3.2353629 1.2835430 99.19703 -2.5206502 0.0133081
(Intercept)5 Dark Night 3.0021643 0.7223312 37.84380 4.1562156 0.0001781
Treatment_bisFull4 Dark Night 0.2318236 0.7397703 98.96292 0.3133724 0.7546572
Treatment_bisSmart4 Dark Night 0.2418887 0.9949681 98.11963 0.2431120 0.8084261
Treatment_bisMixt_smart4 Dark Night 1.1429663 0.8171944 96.35283 1.3986467 0.1651295
RegionLuxembourg5 Dark Night 0.3409062 0.9237507 36.19537 0.3690457 0.7142438
Treatment_FTLDay1 Dark Night 2.2068158 0.5749289 98.41001 3.8384152 0.0002190
Treatment_FTLMix4 Dark Night 1.4228919 0.5450307 100.00724 2.6106639 0.0104258
Treatment_bisFull:RegionLuxembourg4 Dark Night -2.1083268 1.1350373 100.28576 -1.8574956 0.0661749
Treatment_bisSmart:RegionLuxembourg4 Dark Night -0.1494266 1.3088741 97.84774 -0.1141642 0.9093415
Treatment_bisMixt_smart:RegionLuxembourg4 Dark Night -3.2354144 1.2835296 99.19836 -2.5207167 0.0133057
Info_First_move <- "
Le traitement Night diminue le temps mis avant le premier mouvement. Day et Mix ne sont pas significativement différent.
L'impacte du traitement Mixt_smart est différent (plus rapide dans le luxembourg) en fonction de la région d'ou provient la mère de la chenille qui passe le test. (Il est toujours significatif sauf quand comparé avec Full mais là la p val est de 0.06634)
"
Info_First_move
## [1] "\nLe traitement Night diminue le temps mis avant le premier mouvement. Day et Mix ne sont pas significativement différent.\nL'impacte du traitement Mixt_smart est différent (plus rapide dans le luxembourg) en fonction de la région d'ou provient la mère de la chenille qui passe le test. (Il est toujours significatif sauf quand comparé avec Full mais là la p val est de 0.06634)\n"

5.4.5 Visualisation

Summary_First_move <- Data %>% 
  filter(Treatment_FTL != "NA") %>% 
  group_by(Region, Treatment_FTL, Treatment_bis) %>% 
  summarise(Mean=mean(log(First_move+0.1)),
            Var=var(log(First_move+0.1)),
            N=n()) %>% 
  mutate(CI_S=Mean+qt(0.975, N-1)*sqrt(Var/N),
         CI_I=Mean-qt(0.975, N-1)*sqrt(Var/N))
## Warning: There were 4 warnings in `mutate()`.
## The first warning was:
## ℹ In argument: `CI_S = Mean + qt(0.975, N - 1) * sqrt(Var/N)`.
## ℹ In group 2: `Region = Brabant`, `Treatment_FTL = Mix`.
## Caused by warning in `qt()`:
## ! Production de NaN
## ℹ Run ]8;;ide:run:dplyr::last_dplyr_warnings()dplyr::last_dplyr_warnings()]8;; to see the 3 remaining warnings.
ggplot(Summary_First_move, aes(x=Treatment_bis, y=Mean, color = Treatment_FTL))+
  geom_errorbar(aes(ymin=CI_I, ymax=CI_S),width=0.2,size = 1.2, alpha = 0.5, position = "dodge") +
  geom_point(alpha = 1) +
  facet_wrap(~Region) +
  labs(title = "First move", x = "Treatment", y = "log(Time to have the first move)") +
  theme_bw()
## Warning: Removed 8 rows containing missing values (`geom_point()`).

ggplot(data = Data %>% filter(Treatment_FTL != "NA"), aes(x = Treatment_bis, y = log(First_move+0.1), color = Treatment_FTL)) +
  geom_boxplot() +
  geom_point(position = position_dodge(width = 1), alpha = 0.75, data = Data %>% filter(Treatment_FTL == "Day" | Treatment_FTL == "Night")) +
  geom_point(alpha = 0.75, data = Data %>% filter(Treatment_FTL == "Mix")) +
  labs(title = "Temps pour faire le premier mouvement", x = "Tratiement", y = "log(Temps pour faire le premier mouvement (s))", color = "Timing" ) +
  theme_bw()
## Warning: Removed 9 rows containing non-finite values (`stat_boxplot()`).
## Warning: Removed 6 rows containing missing values (`geom_point()`).
## Warning: Removed 3 rows containing missing values (`geom_point()`).

5.5 Flight_to_light

5.5.1 Test

LM_Flight_to_light <- lmer(Flight_to_light ~ Treatment_bis + Sex  + Region + Treatment_FTL + Light_orientation + (1|Mother) + (1|Site) + (1|Room)  + Treatment_bis:Sex + Treatment_bis:Region + Treatment_FTL:Sex + Treatment_FTL:Region + Treatment_FTL:Treatment_bis + Light_orientation:Sex + Light_orientation:Region + Light_orientation:Treatment_bis, data = Data)
## boundary (singular) fit: see help('isSingular')
summary(LM_Flight_to_light)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Flight_to_light ~ Treatment_bis + Sex + Region + Treatment_FTL +  
##     Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) +  
##     Treatment_bis:Sex + Treatment_bis:Region + Treatment_FTL:Sex +  
##     Treatment_FTL:Region + Treatment_FTL:Treatment_bis + Light_orientation:Sex +  
##     Light_orientation:Region + Light_orientation:Treatment_bis
##    Data: Data
## 
## REML criterion at convergence: 486.7
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.4162 -0.4591 -0.0566  0.4457  1.7175 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 0.000e+00   0.00000
##  Site     (Intercept) 3.745e+04 193.51786
##  Room     (Intercept) 1.555e-04   0.01247
##  Residual             2.097e+05 457.89263
## Number of obs: 60, groups:  Mother, 21; Site, 13; Room, 2
## 
## Fixed effects:
##                                                Estimate Std. Error       df
## (Intercept)                                      933.11     453.86    22.66
## Treatment_bisFull                                109.90     480.16    23.32
## Treatment_bisSmart                              1109.56     782.78    26.35
## Treatment_bisMixt_smart                         -585.49     896.25    29.97
## SexMale                                         -280.25     531.70    29.92
## RegionLuxembourg                                -343.88     514.54    24.61
## Treatment_FTLMix                                 574.90     569.23    25.34
## Treatment_FTLNight                               163.53     606.05    29.75
## Light_orientationSouth                          -956.89     426.65    23.65
## Treatment_bisFull:SexMale                       -146.48     495.83    29.03
## Treatment_bisSmart:SexMale                        46.93     546.88    28.32
## Treatment_bisMixt_smart:SexMale                  764.34     537.98    29.90
## Treatment_bisFull:RegionLuxembourg               484.93     498.36    23.82
## Treatment_bisSmart:RegionLuxembourg              420.91     619.22    27.37
## Treatment_bisMixt_smart:RegionLuxembourg        -619.04     540.08    23.28
## SexMale:Treatment_FTLMix                         196.37     565.71    29.68
## SexMale:Treatment_FTLNight                       260.03     529.73    29.96
## RegionLuxembourg:Treatment_FTLMix               -762.66     554.75    27.16
## RegionLuxembourg:Treatment_FTLNight             -438.99     522.17    29.86
## Treatment_bisFull:Treatment_FTLMix              -630.28     561.74    27.61
## Treatment_bisSmart:Treatment_FTLMix            -1382.99    1058.20    26.10
## Treatment_bisMixt_smart:Treatment_FTLMix         427.78     922.39    29.88
## Treatment_bisFull:Treatment_FTLNight            -639.18     478.33    26.71
## Treatment_bisSmart:Treatment_FTLNight          -1659.99    1048.85    27.91
## Treatment_bisMixt_smart:Treatment_FTLNight       268.56     793.97    29.66
## SexMale:Light_orientationSouth                   -48.11     378.69    24.05
## RegionLuxembourg:Light_orientationSouth         1030.20     400.28    28.25
## Treatment_bisFull:Light_orientationSouth         383.78     466.87    26.77
## Treatment_bisSmart:Light_orientationSouth        -97.14     560.02    29.06
## Treatment_bisMixt_smart:Light_orientationSouth   539.27     476.18    27.90
##                                                t value Pr(>|t|)  
## (Intercept)                                      2.056   0.0515 .
## Treatment_bisFull                                0.229   0.8210  
## Treatment_bisSmart                               1.417   0.1681  
## Treatment_bisMixt_smart                         -0.653   0.5186  
## SexMale                                         -0.527   0.6020  
## RegionLuxembourg                                -0.668   0.5101  
## Treatment_FTLMix                                 1.010   0.3221  
## Treatment_FTLNight                               0.270   0.7892  
## Light_orientationSouth                          -2.243   0.0346 *
## Treatment_bisFull:SexMale                       -0.295   0.7698  
## Treatment_bisSmart:SexMale                       0.086   0.9322  
## Treatment_bisMixt_smart:SexMale                  1.421   0.1657  
## Treatment_bisFull:RegionLuxembourg               0.973   0.3403  
## Treatment_bisSmart:RegionLuxembourg              0.680   0.5024  
## Treatment_bisMixt_smart:RegionLuxembourg        -1.146   0.2634  
## SexMale:Treatment_FTLMix                         0.347   0.7309  
## SexMale:Treatment_FTLNight                       0.491   0.6271  
## RegionLuxembourg:Treatment_FTLMix               -1.375   0.1804  
## RegionLuxembourg:Treatment_FTLNight             -0.841   0.4072  
## Treatment_bisFull:Treatment_FTLMix              -1.122   0.2715  
## Treatment_bisSmart:Treatment_FTLMix             -1.307   0.2026  
## Treatment_bisMixt_smart:Treatment_FTLMix         0.464   0.6462  
## Treatment_bisFull:Treatment_FTLNight            -1.336   0.1927  
## Treatment_bisSmart:Treatment_FTLNight           -1.583   0.1248  
## Treatment_bisMixt_smart:Treatment_FTLNight       0.338   0.7376  
## SexMale:Light_orientationSouth                  -0.127   0.9000  
## RegionLuxembourg:Light_orientationSouth          2.574   0.0156 *
## Treatment_bisFull:Light_orientationSouth         0.822   0.4183  
## Treatment_bisSmart:Light_orientationSouth       -0.173   0.8635  
## Treatment_bisMixt_smart:Light_orientationSouth   1.132   0.2671  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 30 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Normalité des résidus

qqnorm(resid(LM_Flight_to_light))
qqline(resid(LM_Flight_to_light))

Homogénité des variances

plot(LM_Flight_to_light)

légère forme d’entonnoir mais c’est passable

Distance de cook

plot(cooks.distance(LM_Flight_to_light))

(cooks.distance(LM_Flight_to_light))
##          204          207          214          215          226          227 
## 4.420913e-03 1.554063e-02 1.791769e-01 2.822961e-01 6.240720e-02 1.939528e-01 
##          242          247          248          249          252          258 
## 1.973436e-01 1.236786e-02 2.989103e-02 2.749752e-02 8.168596e+00 2.385110e-03 
##          262          266          271          272          274          275 
## 2.303683e-03 1.244502e-03 3.049857e-04 8.899909e-02 2.865108e-03 7.886870e-03 
##          276          278          299          300          302          303 
## 2.349206e-01 3.001285e-02 7.657401e-02 5.148891e-02 1.494078e-02 1.147430e-01 
##          305          310          315          316          319          327 
## 1.554063e-02 9.959095e-03 2.973313e-02 8.530616e-02 3.779978e-02 3.584821e-02 
##          332          342          356          358          359          360 
## 5.157073e-04 7.482208e-03 2.663550e-03 5.616472e-02 2.504243e-02 1.169165e-01 
##          366          367          369          372          383          384 
## 7.109003e-03 2.351681e-03 5.139800e-02 2.351681e-03 1.587105e-04 2.793514e-05 
##          389          393          395          398          399          400 
## 1.274773e-01 1.067810e-01 1.274773e-01 5.058466e-04 5.139800e-02 6.415542e-03 
##          407          408          412          414          415          421 
## 1.067810e-01 2.301799e-04 1.606555e-01 2.951929e-04 1.212960e-01 5.972077e-03 
##          426          439          440          441          442          445 
## 2.605002e-02 2.410862e-06 1.030623e-02 2.109382e-02 4.921083e-06 6.183630e-03

Nous avons un problème avec le point de la ligne 252 sans trop savoir pourquoi honnètement. On va juste le retirer

LM_Flight_to_light <- lmer(Flight_to_light ~ Treatment_bis + Sex  + Region + Treatment_FTL + Light_orientation + (1|Mother) + (1|Site) + (1|Room)  + Treatment_bis:Sex + Treatment_bis:Region + Treatment_FTL:Sex + Treatment_FTL:Region + Treatment_FTL:Treatment_bis + Light_orientation:Sex + Light_orientation:Region + Light_orientation:Treatment_bis, data = Data[-252,])
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## boundary (singular) fit: see help('isSingular')
summary(LM_Flight_to_light)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Flight_to_light ~ Treatment_bis + Sex + Region + Treatment_FTL +  
##     Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) +  
##     Treatment_bis:Sex + Treatment_bis:Region + Treatment_FTL:Sex +  
##     Treatment_FTL:Region + Treatment_FTL:Treatment_bis + Light_orientation:Sex +  
##     Light_orientation:Region + Light_orientation:Treatment_bis
##    Data: Data[-252, ]
## 
## REML criterion at convergence: 486.7
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -1.41618 -0.46115 -0.07309  0.45227  1.71754 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept)      0     0.0   
##  Site     (Intercept)  37448   193.5   
##  Room     (Intercept)      0     0.0   
##  Residual             209666   457.9   
## Number of obs: 59, groups:  Mother, 20; Site, 12; Room, 2
## 
## Fixed effects:
##                                                Estimate Std. Error       df
## (Intercept)                                      933.11     453.86    22.66
## Treatment_bisFull                                109.90     480.16    23.32
## Treatment_bisSmart                              1109.56     782.78    26.35
## Treatment_bisMixt_smart                         -316.93     589.81    29.72
## SexMale                                         -280.24     531.70    29.92
## RegionLuxembourg                                -343.88     514.54    24.61
## Treatment_FTLMix                                 574.90     569.23    25.34
## Treatment_FTLNight                               163.53     606.05    29.75
## Light_orientationSouth                          -956.89     426.65    23.65
## Treatment_bisFull:SexMale                       -146.48     495.83    29.03
## Treatment_bisSmart:SexMale                        46.93     546.88    28.32
## Treatment_bisMixt_smart:SexMale                  764.34     537.98    29.90
## Treatment_bisFull:RegionLuxembourg               484.93     498.36    23.82
## Treatment_bisSmart:RegionLuxembourg              420.91     619.22    27.37
## Treatment_bisMixt_smart:RegionLuxembourg        -619.04     540.08    23.28
## SexMale:Treatment_FTLMix                         196.37     565.71    29.68
## SexMale:Treatment_FTLNight                       260.03     529.73    29.96
## RegionLuxembourg:Treatment_FTLMix               -762.66     554.75    27.16
## RegionLuxembourg:Treatment_FTLNight             -438.99     522.17    29.86
## Treatment_bisFull:Treatment_FTLMix              -630.27     561.74    27.61
## Treatment_bisSmart:Treatment_FTLMix            -1382.98    1058.20    26.10
## Treatment_bisMixt_smart:Treatment_FTLMix         159.22     577.10    29.43
## Treatment_bisFull:Treatment_FTLNight            -639.18     478.33    26.71
## Treatment_bisSmart:Treatment_FTLNight          -1659.98    1048.85    27.91
## SexMale:Light_orientationSouth                   -48.11     378.69    24.05
## RegionLuxembourg:Light_orientationSouth         1030.19     400.28    28.25
## Treatment_bisFull:Light_orientationSouth         383.78     466.87    26.77
## Treatment_bisSmart:Light_orientationSouth        -97.13     560.02    29.06
## Treatment_bisMixt_smart:Light_orientationSouth   539.27     476.18    27.90
##                                                t value Pr(>|t|)  
## (Intercept)                                      2.056   0.0515 .
## Treatment_bisFull                                0.229   0.8210  
## Treatment_bisSmart                               1.417   0.1681  
## Treatment_bisMixt_smart                         -0.537   0.5950  
## SexMale                                         -0.527   0.6020  
## RegionLuxembourg                                -0.668   0.5101  
## Treatment_FTLMix                                 1.010   0.3221  
## Treatment_FTLNight                               0.270   0.7892  
## Light_orientationSouth                          -2.243   0.0346 *
## Treatment_bisFull:SexMale                       -0.295   0.7698  
## Treatment_bisSmart:SexMale                       0.086   0.9322  
## Treatment_bisMixt_smart:SexMale                  1.421   0.1657  
## Treatment_bisFull:RegionLuxembourg               0.973   0.3403  
## Treatment_bisSmart:RegionLuxembourg              0.680   0.5024  
## Treatment_bisMixt_smart:RegionLuxembourg        -1.146   0.2634  
## SexMale:Treatment_FTLMix                         0.347   0.7309  
## SexMale:Treatment_FTLNight                       0.491   0.6271  
## RegionLuxembourg:Treatment_FTLMix               -1.375   0.1804  
## RegionLuxembourg:Treatment_FTLNight             -0.841   0.4072  
## Treatment_bisFull:Treatment_FTLMix              -1.122   0.2715  
## Treatment_bisSmart:Treatment_FTLMix             -1.307   0.2026  
## Treatment_bisMixt_smart:Treatment_FTLMix         0.276   0.7846  
## Treatment_bisFull:Treatment_FTLNight            -1.336   0.1927  
## Treatment_bisSmart:Treatment_FTLNight           -1.583   0.1248  
## SexMale:Light_orientationSouth                  -0.127   0.9000  
## RegionLuxembourg:Light_orientationSouth          2.574   0.0156 *
## Treatment_bisFull:Light_orientationSouth         0.822   0.4183  
## Treatment_bisSmart:Light_orientationSouth       -0.173   0.8635  
## Treatment_bisMixt_smart:Light_orientationSouth   1.132   0.2671  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 29 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 1 column / coefficient
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Normalité des résidus

qqnorm(resid(LM_Flight_to_light))
qqline(resid(LM_Flight_to_light))

Homogénité des variances

plot(LM_Flight_to_light)

légère forme d’entonnoir mais c’est passable

Distance de cook

plot(cooks.distance(LM_Flight_to_light))

5.5.2 Simplification du modèle

drop1(LM_Flight_to_light)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Flight_to_light ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + Treatment_FTL:Sex + Treatment_FTL:Region + Treatment_FTL:Treatment_bis + Light_orientation:Sex + Light_orientation:Region + Light_orientation:Treatment_bis
##                                  Sum Sq Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Sex               1032054  344018     3 26.889  1.6408 0.20339  
## Treatment_bis:Region            1436744  478915     3 26.647  2.2842 0.10188  
## Sex:Treatment_FTL                 50802   25401     2 28.940  0.1211 0.88635  
## Region:Treatment_FTL             442881  221441     2 27.172  1.0562 0.36164  
## Treatment_bis:Treatment_FTL      756215  151243     5 27.410  0.7214 0.61310  
## Sex:Light_orientation              3384    3384     1 24.049  0.0161 0.89997  
## Region:Light_orientation        1388805 1388805     1 28.245  6.6239 0.01559 *
## Treatment_bis:Light_orientation  467224  155741     3 27.949  0.7428 0.53558  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Flight_to_light1 <- update(LM_Flight_to_light, . ~ . - Treatment_bis:Treatment_FTL)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Flight_to_light1)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Flight_to_light ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + Sex:Treatment_FTL + Region:Treatment_FTL + Sex:Light_orientation + Region:Light_orientation + Treatment_bis:Light_orientation
##                                  Sum Sq Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Sex               1167873  389291     3 34.518  1.7969 0.16604  
## Treatment_bis:Region            1333349  444450     3 32.977  2.0515 0.12571  
## Sex:Treatment_FTL                268172  134086     2 31.559  0.6189 0.54493  
## Region:Treatment_FTL             289666  144833     2 31.752  0.6685 0.51953  
## Sex:Light_orientation             34236   34236     1 33.071  0.1580 0.69353  
## Region:Light_orientation         942283  942283     1 33.450  4.3495 0.04472 *
## Treatment_bis:Light_orientation  337123  112374     3 34.536  0.5187 0.67220  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Flight_to_light2 <- update(LM_Flight_to_light1, . ~ . - Sex:Light_orientation)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Flight_to_light2)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Flight_to_light ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + Sex:Treatment_FTL + Region:Treatment_FTL + Region:Light_orientation + Treatment_bis:Light_orientation
##                                  Sum Sq Mean Sq NumDF  DenDF F value Pr(>F)  
## Treatment_bis:Sex               1139070  379690     3 35.708  1.7833 0.1679  
## Treatment_bis:Region            1308846  436282     3 34.088  2.0491 0.1254  
## Sex:Treatment_FTL                249143  124572     2 32.104  0.5851 0.5629  
## Region:Treatment_FTL             263422  131711     2 33.034  0.6186 0.5448  
## Region:Light_orientation         905198  905198     1 34.135  4.2514 0.0469 *
## Treatment_bis:Light_orientation  314518  104839     3 35.637  0.4924 0.6898  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Flight_to_light3 <- update(LM_Flight_to_light2, . ~ . - Treatment_bis:Light_orientation)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Flight_to_light3)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Flight_to_light ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + Sex:Treatment_FTL + Region:Treatment_FTL + Region:Light_orientation
##                           Sum Sq Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Sex        1024957  341652     3 38.798  1.6833 0.18647  
## Treatment_bis:Region     1234816  411605     3 36.639  2.0280 0.12695  
## Sex:Treatment_FTL         255420  127710     2 34.161  0.6292 0.53906  
## Region:Treatment_FTL      241094  120547     2 32.685  0.5939 0.55800  
## Region:Light_orientation  916542  916542     1 36.237  4.5159 0.04047 *
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Flight_to_light4 <- update(LM_Flight_to_light3, . ~ . - Region:Treatment_FTL)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Flight_to_light4)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Flight_to_light ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + Sex:Treatment_FTL + Region:Light_orientation
##                           Sum Sq Mean Sq NumDF DenDF F value  Pr(>F)  
## Treatment_bis:Sex        1055211  351737     3    41  1.7315 0.17554  
## Treatment_bis:Region     1301461  433820     3    41  2.1356 0.11045  
## Sex:Treatment_FTL         223075  111537     2    41  0.5491 0.58167  
## Region:Light_orientation  843518  843518     1    41  4.1525 0.04806 *
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Flight_to_light5 <- update(LM_Flight_to_light4, . ~ . - Sex:Treatment_FTL)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Flight_to_light5)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Flight_to_light ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + Region:Light_orientation
##                           Sum Sq Mean Sq NumDF DenDF F value  Pr(>F)  
## Treatment_FTL             897179  448589     2    43  2.2556 0.11707  
## Treatment_bis:Sex        1212300  404100     3    43  2.0319 0.12359  
## Treatment_bis:Region     1456693  485564     3    43  2.4416 0.07716 .
## Region:Light_orientation  812870  812870     1    43  4.0873 0.04946 *
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Flight_to_light6 <- update(LM_Flight_to_light5, . ~ . - Treatment_bis:Sex)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Flight_to_light6)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Flight_to_light ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region + Region:Light_orientation
##                           Sum Sq Mean Sq NumDF  DenDF F value  Pr(>F)  
## Sex                        62844   62844     1 45.725  0.2961 0.58896  
## Treatment_FTL             980069  490034     2 44.229  2.3092 0.11120  
## Treatment_bis:Region     2085105  695035     3 43.542  3.2752 0.02984 *
## Region:Light_orientation  910704  910704     1 43.839  4.2915 0.04422 *
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Les seules interactions qui restent sont significatives donc on les laisse.

LM_Flight_to_light <- LM_Flight_to_light6

5.5.3 Treatment VS Teatment_bis

AIC(lmer(log(Flight_to_light+0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Region:Light_orientation , data = Data))
## boundary (singular) fit: see help('isSingular')
## [1] 222.9282
AIC(lmer(log(Flight_to_light+0.1) ~ Treatment + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment:Region +  Region:Light_orientation , data = Data))
## boundary (singular) fit: see help('isSingular')
## [1] 228.2195
summary(lmer(log(Flight_to_light+0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Region:Light_orientation , data = Data))$coeff
## boundary (singular) fit: see help('isSingular')
##                                            Estimate Std. Error       df
## (Intercept)                               7.5371419  0.7578269 43.39270
## Treatment_bisFull                        -0.8894182  0.8175556 43.65873
## Treatment_bisSmart                        0.9772394  0.8960778 42.04335
## Treatment_bisMixt_smart                   0.8872505  0.8369004 42.39478
## SexMale                                   0.1549360  0.3816299 45.07619
## RegionLuxembourg                         -1.7455601  0.8448226 43.99869
## Treatment_FTLMix                         -1.4984334  0.5997217 44.82190
## Treatment_FTLNight                       -1.4710087  0.5557108 46.55908
## Light_orientationSouth                   -1.7221106  0.6291575 39.96183
## Treatment_bisFull:RegionLuxembourg        1.0369952  1.0220248 40.37219
## Treatment_bisSmart:RegionLuxembourg      -0.1789724  1.1503728 40.75477
## Treatment_bisMixt_smart:RegionLuxembourg -2.0686921  1.0923982 39.74051
## RegionLuxembourg:Light_orientationSouth   2.8082442  0.7981288 43.48096
##                                             t value     Pr(>|t|)
## (Intercept)                               9.9457300 9.208866e-13
## Treatment_bisFull                        -1.0878993 2.826090e-01
## Treatment_bisSmart                        1.0905743 2.816712e-01
## Treatment_bisMixt_smart                   1.0601626 2.950734e-01
## SexMale                                   0.4059849 6.866746e-01
## RegionLuxembourg                         -2.0661854 4.472916e-02
## Treatment_FTLMix                         -2.4985479 1.620539e-02
## Treatment_FTLNight                       -2.6470760 1.104281e-02
## Light_orientationSouth                   -2.7371695 9.204666e-03
## Treatment_bisFull:RegionLuxembourg        1.0146478 3.163162e-01
## Treatment_bisSmart:RegionLuxembourg      -0.1555777 8.771339e-01
## Treatment_bisMixt_smart:RegionLuxembourg -1.8937162 6.555869e-02
## RegionLuxembourg:Light_orientationSouth   3.5185351 1.030487e-03
summary(lmer(log(Flight_to_light+0.1) ~ Treatment + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment:Region +  Region:Light_orientation , data = Data))$coeff
## boundary (singular) fit: see help('isSingular')
##                                           Estimate Std. Error       df
## (Intercept)                              7.5448061  0.8233584 21.90040
## TreatmentFull                           -0.9857974  0.8537022 45.70729
## TreatmentSmart                           0.8441239  0.7746380 43.25969
## SexMale                                  0.2860856  0.3946037 47.73426
## RegionLuxembourg                        -1.6398141  0.8797691 46.68934
## Treatment_FTLMix                        -1.5432569  0.6167422 45.41727
## Treatment_FTLNight                      -1.4067140  0.5640784 47.17294
## Light_orientationSouth                  -1.6643066  0.6554100 42.65889
## TreatmentFull:RegionLuxembourg           1.1285450  1.0767938 43.48971
## TreatmentSmart:RegionLuxembourg         -0.9269634  1.0133546 42.54166
## RegionLuxembourg:Light_orientationSouth  2.3001945  0.8027440 44.45446
##                                            t value     Pr(>|t|)
## (Intercept)                              9.1634527 6.012290e-09
## TreatmentFull                           -1.1547321 2.542017e-01
## TreatmentSmart                           1.0897011 2.818779e-01
## SexMale                                  0.7249947 4.719944e-01
## RegionLuxembourg                        -1.8639142 6.862879e-02
## Treatment_FTLMix                        -2.5022723 1.600603e-02
## Treatment_FTLNight                      -2.4938273 1.619967e-02
## Light_orientationSouth                  -2.5393365 1.483567e-02
## TreatmentFull:RegionLuxembourg           1.0480605 3.004006e-01
## TreatmentSmart:RegionLuxembourg         -0.9147473 3.654803e-01
## RegionLuxembourg:Light_orientationSouth  2.8654148 6.338759e-03

On garde Treatment_bis

5.5.4 Résultats

Analyse des p-val

summary(lmer(log(Flight_to_light+0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Region:Light_orientation , data = Data))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: 
## log(Flight_to_light + 0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL +  
##     Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) +  
##     Treatment_bis:Region + Region:Light_orientation
##    Data: Data
## 
## REML criterion at convergence: 188.9
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -1.77230 -0.55949  0.05376  0.62568  1.74354 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 3.331e-01 5.771e-01
##  Site     (Intercept) 0.000e+00 0.000e+00
##  Room     (Intercept) 1.431e-09 3.783e-05
##  Residual             1.613e+00 1.270e+00
## Number of obs: 60, groups:  Mother, 21; Site, 13; Room, 2
## 
## Fixed effects:
##                                          Estimate Std. Error      df t value
## (Intercept)                                7.5371     0.7578 43.3927   9.946
## Treatment_bisFull                         -0.8894     0.8176 43.6587  -1.088
## Treatment_bisSmart                         0.9772     0.8961 42.0433   1.091
## Treatment_bisMixt_smart                    0.8873     0.8369 42.3948   1.060
## SexMale                                    0.1549     0.3816 45.0762   0.406
## RegionLuxembourg                          -1.7456     0.8448 43.9987  -2.066
## Treatment_FTLMix                          -1.4984     0.5997 44.8219  -2.499
## Treatment_FTLNight                        -1.4710     0.5557 46.5591  -2.647
## Light_orientationSouth                    -1.7221     0.6292 39.9618  -2.737
## Treatment_bisFull:RegionLuxembourg         1.0370     1.0220 40.3722   1.015
## Treatment_bisSmart:RegionLuxembourg       -0.1790     1.1504 40.7548  -0.156
## Treatment_bisMixt_smart:RegionLuxembourg  -2.0687     1.0924 39.7405  -1.894
## RegionLuxembourg:Light_orientationSouth    2.8082     0.7981 43.4810   3.519
##                                          Pr(>|t|)    
## (Intercept)                              9.21e-13 ***
## Treatment_bisFull                         0.28261    
## Treatment_bisSmart                        0.28167    
## Treatment_bisMixt_smart                   0.29507    
## SexMale                                   0.68667    
## RegionLuxembourg                          0.04473 *  
## Treatment_FTLMix                          0.01621 *  
## Treatment_FTLNight                        0.01104 *  
## Light_orientationSouth                    0.00920 ** 
## Treatment_bisFull:RegionLuxembourg        0.31632    
## Treatment_bisSmart:RegionLuxembourg       0.87713    
## Treatment_bisMixt_smart:RegionLuxembourg  0.06556 .  
## RegionLuxembourg:Light_orientationSouth   0.00103 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 13 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Flight_to_light+0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Region:Light_orientation , data = Data_ref_full))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: 
## log(Flight_to_light + 0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL +  
##     Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) +  
##     Treatment_bis:Region + Region:Light_orientation
##    Data: Data_ref_full
## 
## REML criterion at convergence: 188.9
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -1.77230 -0.55949  0.05376  0.62568  1.74354 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 3.331e-01 5.771e-01
##  Site     (Intercept) 0.000e+00 0.000e+00
##  Room     (Intercept) 1.431e-09 3.783e-05
##  Residual             1.613e+00 1.270e+00
## Number of obs: 60, groups:  Mother, 21; Site, 13; Room, 2
## 
## Fixed effects:
##                                          Estimate Std. Error      df t value
## (Intercept)                                6.6477     0.8297 46.5214   8.013
## Treatment_bisDark                          0.8894     0.8176 43.6587   1.088
## Treatment_bisSmart                         1.8667     0.8614 43.1593   2.167
## Treatment_bisMixt_smart                    1.7767     0.7614 45.9641   2.334
## SexMale                                    0.1549     0.3816 45.0762   0.406
## RegionLuxembourg                          -0.7086     0.8425 45.1167  -0.841
## Treatment_FTLMix                          -1.4984     0.5997 44.8219  -2.499
## Treatment_FTLNight                        -1.4710     0.5557 46.5591  -2.647
## Light_orientationSouth                    -1.7221     0.6292 39.9618  -2.737
## Treatment_bisDark:RegionLuxembourg        -1.0370     1.0220 40.3722  -1.015
## Treatment_bisSmart:RegionLuxembourg       -1.2160     1.0595 42.2494  -1.148
## Treatment_bisMixt_smart:RegionLuxembourg  -3.1057     0.9869 44.0551  -3.147
## RegionLuxembourg:Light_orientationSouth    2.8082     0.7981 43.4810   3.519
##                                          Pr(>|t|)    
## (Intercept)                              2.62e-10 ***
## Treatment_bisDark                         0.28261    
## Treatment_bisSmart                        0.03580 *  
## Treatment_bisMixt_smart                   0.02405 *  
## SexMale                                   0.68667    
## RegionLuxembourg                          0.40479    
## Treatment_FTLMix                          0.01621 *  
## Treatment_FTLNight                        0.01104 *  
## Light_orientationSouth                    0.00920 ** 
## Treatment_bisDark:RegionLuxembourg        0.31632    
## Treatment_bisSmart:RegionLuxembourg       0.25757    
## Treatment_bisMixt_smart:RegionLuxembourg  0.00296 ** 
## RegionLuxembourg:Light_orientationSouth   0.00103 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 13 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Flight_to_light+0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Region:Light_orientation , data = Data_ref_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: 
## log(Flight_to_light + 0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL +  
##     Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) +  
##     Treatment_bis:Region + Region:Light_orientation
##    Data: Data_ref_smart
## 
## REML criterion at convergence: 188.9
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -1.77230 -0.55949  0.05376  0.62568  1.74354 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 3.331e-01 5.771e-01
##  Site     (Intercept) 0.000e+00 0.000e+00
##  Room     (Intercept) 1.431e-09 3.783e-05
##  Residual             1.613e+00 1.270e+00
## Number of obs: 60, groups:  Mother, 21; Site, 13; Room, 2
## 
## Fixed effects:
##                                          Estimate Std. Error       df t value
## (Intercept)                               8.51438    0.83974 42.75772  10.139
## Treatment_bisDark                        -0.97724    0.89608 42.04335  -1.091
## Treatment_bisFull                        -1.86666    0.86139 43.15933  -2.167
## Treatment_bisMixt_smart                  -0.08999    0.89928 45.15476  -0.100
## SexMale                                   0.15494    0.38163 45.07619   0.406
## RegionLuxembourg                         -1.92453    0.91578 46.91737  -2.102
## Treatment_FTLMix                         -1.49843    0.59972 44.82190  -2.499
## Treatment_FTLNight                       -1.47101    0.55571 46.55908  -2.647
## Light_orientationSouth                   -1.72211    0.62916 39.96183  -2.737
## Treatment_bisDark:RegionLuxembourg        0.17897    1.15037 40.75477   0.156
## Treatment_bisFull:RegionLuxembourg        1.21597    1.05952 42.24940   1.148
## Treatment_bisMixt_smart:RegionLuxembourg -1.88972    1.16430 43.84133  -1.623
## RegionLuxembourg:Light_orientationSouth   2.80824    0.79813 43.48096   3.519
##                                          Pr(>|t|)    
## (Intercept)                              6.04e-13 ***
## Treatment_bisDark                         0.28167    
## Treatment_bisFull                         0.03580 *  
## Treatment_bisMixt_smart                   0.92073    
## SexMale                                   0.68667    
## RegionLuxembourg                          0.04099 *  
## Treatment_FTLMix                          0.01621 *  
## Treatment_FTLNight                        0.01104 *  
## Light_orientationSouth                    0.00920 ** 
## Treatment_bisDark:RegionLuxembourg        0.87713    
## Treatment_bisFull:RegionLuxembourg        0.25757    
## Treatment_bisMixt_smart:RegionLuxembourg  0.11175    
## RegionLuxembourg:Light_orientationSouth   0.00103 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 13 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Flight_to_light+0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Region:Light_orientation , data = Data_ref_mixt_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: 
## log(Flight_to_light + 0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL +  
##     Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) +  
##     Treatment_bis:Region + Region:Light_orientation
##    Data: Data_ref_mixt_smart
## 
## REML criterion at convergence: 188.9
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -1.77230 -0.55949  0.05376  0.62568  1.74354 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 3.331e-01 5.771e-01
##  Site     (Intercept) 0.000e+00 0.000e+00
##  Room     (Intercept) 1.431e-09 3.783e-05
##  Residual             1.613e+00 1.270e+00
## Number of obs: 60, groups:  Mother, 21; Site, 13; Room, 2
## 
## Fixed effects:
##                                         Estimate Std. Error       df t value
## (Intercept)                              8.42439    0.87690 45.45552   9.607
## Treatment_bisDark                       -0.88725    0.83690 42.39478  -1.060
## Treatment_bisFull                       -1.77667    0.76135 45.96407  -2.334
## Treatment_bisSmart                       0.08999    0.89928 45.15476   0.100
## SexMale                                  0.15494    0.38163 45.07619   0.406
## RegionLuxembourg                        -3.81425    0.96809 46.40804  -3.940
## Treatment_FTLMix                        -1.49843    0.59972 44.82190  -2.499
## Treatment_FTLNight                      -1.47101    0.55571 46.55908  -2.647
## Light_orientationSouth                  -1.72211    0.62916 39.96183  -2.737
## Treatment_bisDark:RegionLuxembourg       2.06869    1.09240 39.74051   1.894
## Treatment_bisFull:RegionLuxembourg       3.10569    0.98691 44.05509   3.147
## Treatment_bisSmart:RegionLuxembourg      1.88972    1.16430 43.84133   1.623
## RegionLuxembourg:Light_orientationSouth  2.80824    0.79813 43.48096   3.519
##                                         Pr(>|t|)    
## (Intercept)                             1.62e-12 ***
## Treatment_bisDark                       0.295073    
## Treatment_bisFull                       0.024047 *  
## Treatment_bisSmart                      0.920733    
## SexMale                                 0.686675    
## RegionLuxembourg                        0.000272 ***
## Treatment_FTLMix                        0.016205 *  
## Treatment_FTLNight                      0.011043 *  
## Light_orientationSouth                  0.009205 ** 
## Treatment_bisDark:RegionLuxembourg      0.065559 .  
## Treatment_bisFull:RegionLuxembourg      0.002957 ** 
## Treatment_bisSmart:RegionLuxembourg     0.111749    
## RegionLuxembourg:Light_orientationSouth 0.001030 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 13 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Flight_to_light+0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Region:Light_orientation , data = Data_refFTL_Night))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: 
## log(Flight_to_light + 0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL +  
##     Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) +  
##     Treatment_bis:Region + Region:Light_orientation
##    Data: Data_refFTL_Night
## 
## REML criterion at convergence: 188.9
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -1.77230 -0.55949  0.05376  0.62568  1.74354 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 3.331e-01 5.771e-01
##  Site     (Intercept) 0.000e+00 0.000e+00
##  Room     (Intercept) 1.431e-09 3.783e-05
##  Residual             1.613e+00 1.270e+00
## Number of obs: 60, groups:  Mother, 21; Site, 13; Room, 2
## 
## Fixed effects:
##                                          Estimate Std. Error       df t value
## (Intercept)                               6.06613    0.64973 46.00047   9.336
## Treatment_bisFull                        -0.88942    0.81756 43.65873  -1.088
## Treatment_bisSmart                        0.97724    0.89608 42.04335   1.091
## Treatment_bisMixt_smart                   0.88725    0.83690 42.39478   1.060
## SexMale                                   0.15494    0.38163 45.07619   0.406
## RegionLuxembourg                         -1.74556    0.84482 43.99869  -2.066
## Treatment_FTLDay                          1.47101    0.55571 46.55908   2.647
## Treatment_FTLMix                         -0.02742    0.41244 46.56432  -0.066
## Light_orientationSouth                   -1.72211    0.62916 39.96183  -2.737
## Treatment_bisFull:RegionLuxembourg        1.03700    1.02202 40.37219   1.015
## Treatment_bisSmart:RegionLuxembourg      -0.17897    1.15037 40.75477  -0.156
## Treatment_bisMixt_smart:RegionLuxembourg -2.06869    1.09240 39.74051  -1.894
## RegionLuxembourg:Light_orientationSouth   2.80824    0.79813 43.48096   3.519
##                                          Pr(>|t|)    
## (Intercept)                              3.45e-12 ***
## Treatment_bisFull                         0.28261    
## Treatment_bisSmart                        0.28167    
## Treatment_bisMixt_smart                   0.29507    
## SexMale                                   0.68667    
## RegionLuxembourg                          0.04473 *  
## Treatment_FTLDay                          0.01104 *  
## Treatment_FTLMix                          0.94727    
## Light_orientationSouth                    0.00920 ** 
## Treatment_bisFull:RegionLuxembourg        0.31632    
## Treatment_bisSmart:RegionLuxembourg       0.87713    
## Treatment_bisMixt_smart:RegionLuxembourg  0.06556 .  
## RegionLuxembourg:Light_orientationSouth   0.00103 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 13 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Flight_to_light+0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Region:Light_orientation , data = Data_refFTL_Mix))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: 
## log(Flight_to_light + 0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL +  
##     Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) +  
##     Treatment_bis:Region + Region:Light_orientation
##    Data: Data_refFTL_Mix
## 
## REML criterion at convergence: 188.9
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -1.77230 -0.55949  0.05376  0.62568  1.74354 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 3.331e-01 5.771e-01
##  Site     (Intercept) 0.000e+00 0.000e+00
##  Room     (Intercept) 1.431e-09 3.783e-05
##  Residual             1.613e+00 1.270e+00
## Number of obs: 60, groups:  Mother, 21; Site, 13; Room, 2
## 
## Fixed effects:
##                                          Estimate Std. Error       df t value
## (Intercept)                               6.03871    0.65494 43.62492   9.220
## Treatment_bisFull                        -0.88942    0.81756 43.65873  -1.088
## Treatment_bisSmart                        0.97724    0.89608 42.04335   1.091
## Treatment_bisMixt_smart                   0.88725    0.83690 42.39478   1.060
## SexMale                                   0.15494    0.38163 45.07619   0.406
## RegionLuxembourg                         -1.74556    0.84482 43.99869  -2.066
## Treatment_FTLDay                          1.49843    0.59972 44.82190   2.499
## Treatment_FTLNight                        0.02742    0.41244 46.56432   0.066
## Light_orientationSouth                   -1.72211    0.62916 39.96183  -2.737
## Treatment_bisFull:RegionLuxembourg        1.03700    1.02202 40.37219   1.015
## Treatment_bisSmart:RegionLuxembourg      -0.17897    1.15037 40.75477  -0.156
## Treatment_bisMixt_smart:RegionLuxembourg -2.06869    1.09240 39.74051  -1.894
## RegionLuxembourg:Light_orientationSouth   2.80824    0.79813 43.48096   3.519
##                                          Pr(>|t|)    
## (Intercept)                              8.34e-12 ***
## Treatment_bisFull                         0.28261    
## Treatment_bisSmart                        0.28167    
## Treatment_bisMixt_smart                   0.29507    
## SexMale                                   0.68667    
## RegionLuxembourg                          0.04473 *  
## Treatment_FTLDay                          0.01621 *  
## Treatment_FTLNight                        0.94727    
## Light_orientationSouth                    0.00920 ** 
## Treatment_bisFull:RegionLuxembourg        0.31632    
## Treatment_bisSmart:RegionLuxembourg       0.87713    
## Treatment_bisMixt_smart:RegionLuxembourg  0.06556 .  
## RegionLuxembourg:Light_orientationSouth   0.00103 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 13 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
test1 <- data.frame(Reference_Treatment = "Dark", Reference_Timing = "Day", as.data.frame(( summary(lmer(log(Flight_to_light+0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Region:Light_orientation , data = Data))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test2 <- data.frame(Reference_Treatment = "Smart", Reference_Timing = "Day", as.data.frame(( summary(lmer(log(Flight_to_light+0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Region:Light_orientation , data = Data_ref_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test3 <- data.frame(Reference_Treatment = "Full", Reference_Timing = "Day", as.data.frame(( summary(lmer(log(Flight_to_light+0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Region:Light_orientation , data = Data_ref_full))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test4 <- data.frame(Reference_Treatment = "Mixt_smart", Reference_Timing = "Day", as.data.frame(( summary(lmer(log(Flight_to_light+0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Region:Light_orientation , data = Data_ref_mixt_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test5 <- data.frame(Reference_Treatment = "Dark", Reference_Timing = "Mixt", as.data.frame(( summary(lmer(log(Flight_to_light+0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Region:Light_orientation , data = Data_refFTL_Mix))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test6 <- data.frame(Reference_Treatment = "Dark", Reference_Timing = "Night", as.data.frame(( summary(lmer(log(Flight_to_light+0.1) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Region:Light_orientation , data = Data_refFTL_Night))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
Results_FTL <- rbind(test1,test2,test3,test4,test5,test6)

colnames(Results_FTL ) <- c("Reference_Treatment", "Reference_Timing" ,"Estimate", "Std. Error", "df", "t.value", "Pr(>|z|)")

write.csv2( Results_FTL , file = "output/Results_FTL.csv" )

kable(Results_FTL , caption = " Temps mis pour voler à la lumière ", padding = 1 )
Temps mis pour voler à la lumière
Reference_Treatment Reference_Timing Estimate Std. Error df t.value Pr(>|z|)
(Intercept) Dark Day 7.5371419 0.7578269 43.39270 9.9457300 0.0000000
Treatment_bisFull Dark Day -0.8894182 0.8175556 43.65873 -1.0878993 0.2826090
Treatment_bisSmart Dark Day 0.9772394 0.8960778 42.04335 1.0905743 0.2816712
Treatment_bisMixt_smart Dark Day 0.8872505 0.8369004 42.39478 1.0601626 0.2950734
SexMale Dark Day 0.1549360 0.3816299 45.07619 0.4059849 0.6866746
RegionLuxembourg Dark Day -1.7455601 0.8448226 43.99869 -2.0661854 0.0447292
Treatment_FTLMix Dark Day -1.4984334 0.5997217 44.82190 -2.4985479 0.0162054
Treatment_FTLNight Dark Day -1.4710087 0.5557108 46.55908 -2.6470760 0.0110428
Light_orientationSouth Dark Day -1.7221106 0.6291575 39.96183 -2.7371695 0.0092047
Treatment_bisFull:RegionLuxembourg Dark Day 1.0369952 1.0220248 40.37219 1.0146478 0.3163162
Treatment_bisSmart:RegionLuxembourg Dark Day -0.1789724 1.1503728 40.75477 -0.1555777 0.8771339
Treatment_bisMixt_smart:RegionLuxembourg Dark Day -2.0686921 1.0923982 39.74051 -1.8937162 0.0655587
RegionLuxembourg:Light_orientationSouth Dark Day 2.8082442 0.7981288 43.48096 3.5185351 0.0010305
(Intercept)1 Smart Day 8.5143813 0.8397396 42.75772 10.1393115 0.0000000
Treatment_bisDark Smart Day -0.9772394 0.8960778 42.04335 -1.0905743 0.2816712
Treatment_bisFull1 Smart Day -1.8666576 0.8613917 43.15933 -2.1670254 0.0357966
Treatment_bisMixt_smart1 Smart Day -0.0899889 0.8992770 45.15476 -0.1000680 0.9207333
SexMale1 Smart Day 0.1549360 0.3816299 45.07619 0.4059849 0.6866746
RegionLuxembourg1 Smart Day -1.9245325 0.9157843 46.91737 -2.1015130 0.0409934
Treatment_FTLMix1 Smart Day -1.4984334 0.5997217 44.82190 -2.4985479 0.0162054
Treatment_FTLNight1 Smart Day -1.4710087 0.5557108 46.55908 -2.6470760 0.0110428
Light_orientationSouth1 Smart Day -1.7221106 0.6291575 39.96183 -2.7371695 0.0092047
Treatment_bisDark:RegionLuxembourg Smart Day 0.1789724 1.1503728 40.75477 0.1555777 0.8771339
Treatment_bisFull:RegionLuxembourg1 Smart Day 1.2159675 1.0595188 42.24940 1.1476602 0.2575661
Treatment_bisMixt_smart:RegionLuxembourg1 Smart Day -1.8897198 1.1643045 43.84133 -1.6230460 0.1117495
RegionLuxembourg:Light_orientationSouth1 Smart Day 2.8082442 0.7981288 43.48096 3.5185351 0.0010305
(Intercept)2 Full Day 6.6477237 0.8296690 46.52137 8.0125011 0.0000000
Treatment_bisDark1 Full Day 0.8894182 0.8175556 43.65873 1.0878993 0.2826090
Treatment_bisSmart1 Full Day 1.8666576 0.8613917 43.15933 2.1670254 0.0357966
Treatment_bisMixt_smart2 Full Day 1.7766688 0.7613513 45.96407 2.3335728 0.0240470
SexMale2 Full Day 0.1549360 0.3816299 45.07619 0.4059849 0.6866746
RegionLuxembourg2 Full Day -0.7085650 0.8425465 45.11672 -0.8409803 0.4047942
Treatment_FTLMix2 Full Day -1.4984334 0.5997217 44.82190 -2.4985479 0.0162054
Treatment_FTLNight2 Full Day -1.4710087 0.5557108 46.55908 -2.6470760 0.0110428
Light_orientationSouth2 Full Day -1.7221106 0.6291575 39.96183 -2.7371695 0.0092047
Treatment_bisDark:RegionLuxembourg1 Full Day -1.0369952 1.0220248 40.37219 -1.0146478 0.3163162
Treatment_bisSmart:RegionLuxembourg1 Full Day -1.2159675 1.0595188 42.24940 -1.1476602 0.2575661
Treatment_bisMixt_smart:RegionLuxembourg2 Full Day -3.1056873 0.9869123 44.05509 -3.1468725 0.0029572
RegionLuxembourg:Light_orientationSouth2 Full Day 2.8082442 0.7981288 43.48096 3.5185351 0.0010305
(Intercept)3 Mixt_smart Day 8.4243925 0.8769003 45.45552 9.6070130 0.0000000
Treatment_bisDark2 Mixt_smart Day -0.8872505 0.8369004 42.39478 -1.0601626 0.2950734
Treatment_bisFull2 Mixt_smart Day -1.7766688 0.7613513 45.96407 -2.3335728 0.0240470
Treatment_bisSmart2 Mixt_smart Day 0.0899889 0.8992770 45.15476 0.1000680 0.9207333
SexMale3 Mixt_smart Day 0.1549360 0.3816299 45.07619 0.4059849 0.6866746
RegionLuxembourg3 Mixt_smart Day -3.8142523 0.9680899 46.40804 -3.9399773 0.0002724
Treatment_FTLMix3 Mixt_smart Day -1.4984334 0.5997217 44.82190 -2.4985479 0.0162054
Treatment_FTLNight3 Mixt_smart Day -1.4710087 0.5557108 46.55908 -2.6470760 0.0110428
Light_orientationSouth3 Mixt_smart Day -1.7221106 0.6291575 39.96183 -2.7371695 0.0092047
Treatment_bisDark:RegionLuxembourg2 Mixt_smart Day 2.0686921 1.0923982 39.74051 1.8937162 0.0655587
Treatment_bisFull:RegionLuxembourg2 Mixt_smart Day 3.1056873 0.9869123 44.05509 3.1468725 0.0029572
Treatment_bisSmart:RegionLuxembourg2 Mixt_smart Day 1.8897198 1.1643045 43.84133 1.6230460 0.1117495
RegionLuxembourg:Light_orientationSouth3 Mixt_smart Day 2.8082442 0.7981288 43.48096 3.5185351 0.0010305
(Intercept)4 Dark Mixt 6.0387085 0.6549434 43.62492 9.2201994 0.0000000
Treatment_bisFull3 Dark Mixt -0.8894182 0.8175556 43.65873 -1.0878993 0.2826090
Treatment_bisSmart3 Dark Mixt 0.9772394 0.8960778 42.04335 1.0905743 0.2816712
Treatment_bisMixt_smart3 Dark Mixt 0.8872505 0.8369004 42.39478 1.0601626 0.2950734
SexMale4 Dark Mixt 0.1549360 0.3816299 45.07619 0.4059849 0.6866746
RegionLuxembourg4 Dark Mixt -1.7455601 0.8448226 43.99869 -2.0661854 0.0447292
Treatment_FTLDay Dark Mixt 1.4984334 0.5997217 44.82190 2.4985479 0.0162054
Treatment_FTLNight4 Dark Mixt 0.0274247 0.4124351 46.56432 0.0664946 0.9472688
Light_orientationSouth4 Dark Mixt -1.7221106 0.6291575 39.96183 -2.7371695 0.0092047
Treatment_bisFull:RegionLuxembourg3 Dark Mixt 1.0369952 1.0220248 40.37219 1.0146478 0.3163162
Treatment_bisSmart:RegionLuxembourg3 Dark Mixt -0.1789724 1.1503728 40.75477 -0.1555777 0.8771339
Treatment_bisMixt_smart:RegionLuxembourg3 Dark Mixt -2.0686921 1.0923982 39.74051 -1.8937162 0.0655587
RegionLuxembourg:Light_orientationSouth4 Dark Mixt 2.8082442 0.7981288 43.48096 3.5185351 0.0010305
(Intercept)5 Dark Night 6.0661332 0.6497262 46.00047 9.3364448 0.0000000
Treatment_bisFull4 Dark Night -0.8894182 0.8175556 43.65873 -1.0878993 0.2826090
Treatment_bisSmart4 Dark Night 0.9772394 0.8960778 42.04335 1.0905743 0.2816712
Treatment_bisMixt_smart4 Dark Night 0.8872505 0.8369004 42.39478 1.0601626 0.2950734
SexMale5 Dark Night 0.1549360 0.3816299 45.07619 0.4059849 0.6866746
RegionLuxembourg5 Dark Night -1.7455601 0.8448226 43.99869 -2.0661854 0.0447292
Treatment_FTLDay1 Dark Night 1.4710087 0.5557108 46.55908 2.6470760 0.0110428
Treatment_FTLMix4 Dark Night -0.0274247 0.4124351 46.56432 -0.0664946 0.9472688
Light_orientationSouth5 Dark Night -1.7221106 0.6291575 39.96183 -2.7371695 0.0092047
Treatment_bisFull:RegionLuxembourg4 Dark Night 1.0369952 1.0220248 40.37219 1.0146478 0.3163162
Treatment_bisSmart:RegionLuxembourg4 Dark Night -0.1789724 1.1503728 40.75477 -0.1555777 0.8771339
Treatment_bisMixt_smart:RegionLuxembourg4 Dark Night -2.0686921 1.0923982 39.74051 -1.8937162 0.0655587
RegionLuxembourg:Light_orientationSouth5 Dark Night 2.8082442 0.7981288 43.48096 3.5185351 0.0010305
Info_Flight_to_light <- "
Les individus du expérimentés la nuit mettent significativement plus de temps que le traitement jour.
Le fait que la lampe  soit orientée au Sud a impacte différent en fonction du sex expérimenté (les mâle sont plus lent)
"
Info_Flight_to_light
## [1] "\nLes individus du expérimentés la nuit mettent significativement plus de temps que le traitement jour.\nLe fait que la lampe  soit orientée au Sud a impacte différent en fonction du sex expérimenté (les mâle sont plus lent)\n"

5.5.5 Visualisation

Summary_Flight_to_light <- Data %>% 
  filter(Treatment_FTL != "NA") %>% 
  group_by(Treatment_FTL, Treatment_bis) %>% 
  summarise(Mean=mean(log(Flight_to_light)),
            Var=var(log(Flight_to_light)),
            N=n()) %>% 
  mutate(CI_S=Mean+qt(0.975, N-1)*sqrt(Var/N),
         CI_I=Mean-qt(0.975, N-1)*sqrt(Var/N))
ggplot(Summary_Flight_to_light, aes(x=Treatment_bis, y=Mean, color = Treatment_FTL))+
  geom_errorbar(aes(ymin=CI_I, ymax=CI_S),width=0.2,size = 1.2, alpha = 0.5, position = "dodge") +
  geom_point(alpha = 1) +
  labs(title = "Fly to light", x = "Treatment", y = "log(Time to have the first move)") +
  theme_bw()
## Warning: Removed 12 rows containing missing values (`geom_point()`).

ggplot(data = Data, aes(x = Treatment_bis, y = Flight_to_light, color = Treatment_FTL)) +
  geom_boxplot() +
  geom_point(position = position_dodge(width = 1), alpha = 0.75, data = Data %>% filter(Treatment_FTL == "Day" | Treatment_FTL == "Night")) +
  geom_point(alpha = 0.75, data = Data %>% filter(Treatment_FTL == "Mix")) +
  labs(title = "Temps pour voler à la lumière", x = "Tratiement", y = "Temps pour voler à la lumière (s)", color = "Timing" ) +
  theme_bw()
## Warning: Removed 390 rows containing non-finite values (`stat_boxplot()`).
## Warning: Removed 42 rows containing missing values (`geom_point()`).
## Warning: Removed 18 rows containing missing values (`geom_point()`).

5.6 Speed to light

5.6.1 Test

LM_Speed_to_light <- lmer(Speed_to_light ~ Treatment_bis + Sex  + Region + Treatment_FTL + Light_orientation + (1|Mother) + (1|Site) + (1|Room)  + Treatment_bis:Sex + Treatment_bis:Region + Treatment_FTL:Sex + Treatment_FTL:Region + Treatment_FTL:Treatment_bis + Light_orientation:Sex + Light_orientation:Region + Light_orientation:Treatment_bis, data = Data)
## boundary (singular) fit: see help('isSingular')
summary(LM_Speed_to_light)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Speed_to_light ~ Treatment_bis + Sex + Region + Treatment_FTL +  
##     Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) +  
##     Treatment_bis:Sex + Treatment_bis:Region + Treatment_FTL:Sex +  
##     Treatment_FTL:Region + Treatment_FTL:Treatment_bis + Light_orientation:Sex +  
##     Light_orientation:Region + Light_orientation:Treatment_bis
##    Data: Data
## 
## REML criterion at convergence: 691.6
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.8376 -0.2980 -0.1061  0.1279  4.7052 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 0.000e+00 0.0000000
##  Site     (Intercept) 3.317e-01 0.5758942
##  Room     (Intercept) 1.076e-08 0.0001037
##  Residual             7.190e+01 8.4794774
## Number of obs: 119, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                                Estimate Std. Error      df
## (Intercept)                                     -0.6684     3.8476 61.7266
## Treatment_bisFull                               -0.6908     4.4362 86.7149
## Treatment_bisSmart                              -1.7895     5.7997 87.0917
## Treatment_bisMixt_smart                         -4.3715     5.7253 87.8189
## SexMale                                         -0.8618     4.0410 88.5751
## RegionLuxembourg                                 1.3797     4.3133 54.4803
## Treatment_FTLMix                                 2.7056     4.2753 25.2134
## Treatment_FTLNight                              -0.2497     4.5397 53.0555
## Light_orientationSouth                           3.1452     3.5320 86.6599
## Treatment_bisFull:SexMale                        4.3769     4.3226 87.6676
## Treatment_bisSmart:SexMale                       0.1742     5.3295 88.9601
## Treatment_bisMixt_smart:SexMale                  2.9481     4.8289 77.6151
## Treatment_bisFull:RegionLuxembourg               1.8814     4.3474 88.9703
## Treatment_bisSmart:RegionLuxembourg              0.8324     5.1736 86.8273
## Treatment_bisMixt_smart:RegionLuxembourg         3.2665     5.7707 87.8793
## SexMale:Treatment_FTLMix                         1.5762     4.2372 88.8126
## SexMale:Treatment_FTLNight                      -0.3888     4.2092 88.9353
## RegionLuxembourg:Treatment_FTLMix               -2.7629     4.5199 46.0199
## RegionLuxembourg:Treatment_FTLNight              4.6347     4.4332 74.1899
## Treatment_bisFull:Treatment_FTLMix               0.7858     5.4630 88.8322
## Treatment_bisSmart:Treatment_FTLMix              0.2737     6.2240 87.2224
## Treatment_bisMixt_smart:Treatment_FTLMix        12.4439     7.2575 88.8583
## Treatment_bisFull:Treatment_FTLNight             3.2611     5.1365 86.2318
## Treatment_bisSmart:Treatment_FTLNight            0.1599     6.1174 87.7029
## Treatment_bisMixt_smart:Treatment_FTLNight      -1.0548     5.8983 86.3624
## SexMale:Light_orientationSouth                  -0.7659     3.6449 85.9739
## RegionLuxembourg:Light_orientationSouth         -4.8097     3.5028 87.5783
## Treatment_bisFull:Light_orientationSouth        -2.5172     4.2665 88.8827
## Treatment_bisSmart:Light_orientationSouth       -0.2800     5.0975 88.5928
## Treatment_bisMixt_smart:Light_orientationSouth   3.6937     5.1515 81.9001
##                                                t value Pr(>|t|)  
## (Intercept)                                     -0.174   0.8627  
## Treatment_bisFull                               -0.156   0.8766  
## Treatment_bisSmart                              -0.309   0.7584  
## Treatment_bisMixt_smart                         -0.764   0.4472  
## SexMale                                         -0.213   0.8316  
## RegionLuxembourg                                 0.320   0.7503  
## Treatment_FTLMix                                 0.633   0.5325  
## Treatment_FTLNight                              -0.055   0.9564  
## Light_orientationSouth                           0.891   0.3757  
## Treatment_bisFull:SexMale                        1.013   0.3141  
## Treatment_bisSmart:SexMale                       0.033   0.9740  
## Treatment_bisMixt_smart:SexMale                  0.611   0.5433  
## Treatment_bisFull:RegionLuxembourg               0.433   0.6662  
## Treatment_bisSmart:RegionLuxembourg              0.161   0.8726  
## Treatment_bisMixt_smart:RegionLuxembourg         0.566   0.5728  
## SexMale:Treatment_FTLMix                         0.372   0.7108  
## SexMale:Treatment_FTLNight                      -0.092   0.9266  
## RegionLuxembourg:Treatment_FTLMix               -0.611   0.5440  
## RegionLuxembourg:Treatment_FTLNight              1.045   0.2992  
## Treatment_bisFull:Treatment_FTLMix               0.144   0.8860  
## Treatment_bisSmart:Treatment_FTLMix              0.044   0.9650  
## Treatment_bisMixt_smart:Treatment_FTLMix         1.715   0.0899 .
## Treatment_bisFull:Treatment_FTLNight             0.635   0.5272  
## Treatment_bisSmart:Treatment_FTLNight            0.026   0.9792  
## Treatment_bisMixt_smart:Treatment_FTLNight      -0.179   0.8585  
## SexMale:Light_orientationSouth                  -0.210   0.8341  
## RegionLuxembourg:Light_orientationSouth         -1.373   0.1732  
## Treatment_bisFull:Light_orientationSouth        -0.590   0.5567  
## Treatment_bisSmart:Light_orientationSouth       -0.055   0.9563  
## Treatment_bisMixt_smart:Light_orientationSouth   0.717   0.4754  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 30 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Normalité des résidus

qqnorm(resid(LM_Speed_to_light))
qqline(resid(LM_Speed_to_light))

LM_Speed_to_light <- lmer(log(Speed_to_light+0.000001) ~ Treatment_bis + Sex  + Region + Treatment_FTL + Light_orientation + (1|Mother) + (1|Site) + (1|Room)  + Treatment_bis:Sex + Treatment_bis:Region + Treatment_FTL:Sex + Treatment_FTL:Region + Treatment_FTL:Treatment_bis + Light_orientation:Sex + Light_orientation:Region + Light_orientation:Treatment_bis, data = Data)
## boundary (singular) fit: see help('isSingular')

Normalité des résidus

qqnorm(resid(LM_Speed_to_light))
qqline(resid(LM_Speed_to_light))

Homogénité des variances

plot(LM_Speed_to_light)

La forme est due au grand nombre de 0

Distance de cook

plot(cooks.distance(LM_Speed_to_light))

On a un léger outlier mais je pense que cela passe sans trop de problème vu les valeurs de cook lui étant associées

5.6.2 Simplification du modèle

drop1(LM_Speed_to_light)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Speed_to_light + 1e-06) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + Treatment_FTL:Sex + Treatment_FTL:Region + Treatment_FTL:Treatment_bis + Light_orientation:Sex + Light_orientation:Region + Light_orientation:Treatment_bis
##                                  Sum Sq Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Sex                24.990   8.330     3 85.645  0.2505 0.86080  
## Treatment_bis:Region            232.055  77.352     3 83.642  2.3259 0.08061 .
## Sex:Treatment_FTL                 0.182   0.091     2 84.099  0.0027 0.99726  
## Region:Treatment_FTL            235.794 117.897     2 86.332  3.5450 0.03314 *
## Treatment_bis:Treatment_FTL     227.207  37.868     6 83.783  1.1386 0.34731  
## Sex:Light_orientation           174.945 174.945     1 81.792  5.2604 0.02438 *
## Region:Light_orientation          0.009   0.009     1 82.446  0.0003 0.98681  
## Treatment_bis:Light_orientation 175.382  58.461     3 84.925  1.7578 0.16141  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Speed_to_light1 <- update(LM_Speed_to_light, . ~ . - Sex:Treatment_FTL)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Speed_to_light1)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Speed_to_light + 1e-06) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + Region:Treatment_FTL + Treatment_bis:Treatment_FTL + Sex:Light_orientation + Region:Light_orientation + Treatment_bis:Light_orientation
##                                  Sum Sq Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Sex                26.206   8.735     3 87.249  0.2691 0.84749  
## Treatment_bis:Region            235.989  78.663     3 85.411  2.4237 0.07131 .
## Region:Treatment_FTL            239.080 119.540     2 88.049  3.6831 0.02910 *
## Treatment_bis:Treatment_FTL     240.590  40.098     6 85.587  1.2355 0.29635  
## Sex:Light_orientation           191.717 191.717     1 83.647  5.9069 0.01722 *
## Region:Light_orientation          0.010   0.010     1 84.599  0.0003 0.98637  
## Treatment_bis:Light_orientation 181.777  60.592     3 86.805  1.8669 0.14115  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Speed_to_light2 <- update(LM_Speed_to_light1, . ~ . - Region:Light_orientation)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Speed_to_light2)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Speed_to_light + 1e-06) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + Region:Treatment_FTL + Treatment_bis:Treatment_FTL + Sex:Light_orientation + Treatment_bis:Light_orientation
##                                  Sum Sq Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Sex                26.735   8.912     3 88.220  0.2779 0.84121  
## Treatment_bis:Region            236.797  78.932     3 86.500  2.4614 0.06798 .
## Region:Treatment_FTL            241.662 120.831     2 89.046  3.7679 0.02687 *
## Treatment_bis:Treatment_FTL     245.312  40.885     6 86.461  1.2749 0.27732  
## Sex:Light_orientation           192.772 192.772     1 84.424  6.0112 0.01628 *
## Treatment_bis:Light_orientation 182.210  60.737     3 87.887  1.8940 0.13646  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Speed_to_light3 <- update(LM_Speed_to_light2, . ~ . - Treatment_bis:Sex)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Speed_to_light3)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Speed_to_light + 1e-06) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region + Region:Treatment_FTL + Treatment_bis:Treatment_FTL + Sex:Light_orientation + Treatment_bis:Light_orientation
##                                 Sum Sq Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Region            233.40  77.799     3 89.447  2.4677 0.06721 .
## Region:Treatment_FTL            254.59 127.295     2 92.257  4.0377 0.02084 *
## Treatment_bis:Treatment_FTL     275.05  45.841     6 89.643  1.4541 0.20317  
## Sex:Light_orientation           200.17 200.170     1 87.235  6.3492 0.01356 *
## Treatment_bis:Light_orientation 189.49  63.163     3 91.090  2.0035 0.11903  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Speed_to_light4 <- update(LM_Speed_to_light3, . ~ . - Treatment_bis:Treatment_FTL)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Speed_to_light4)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Speed_to_light + 1e-06) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region + Region:Treatment_FTL + Sex:Light_orientation + Treatment_bis:Light_orientation
##                                  Sum Sq Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Region             92.998  30.999     3 90.928  0.9585 0.41590  
## Region:Treatment_FTL            124.083  62.042     2 94.724  1.9184 0.15250  
## Sex:Light_orientation           177.221 177.221     1 93.829  5.4799 0.02135 *
## Treatment_bis:Light_orientation  97.252  32.417     3 96.969  1.0024 0.39524  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Speed_to_light5 <- update(LM_Speed_to_light4, . ~ . - Treatment_bis:Region)
drop1(LM_Speed_to_light5)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Speed_to_light + 1e-06) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Region:Treatment_FTL + Sex:Light_orientation + Treatment_bis:Light_orientation
##                                 Sum Sq Mean Sq NumDF   DenDF F value  Pr(>F)  
## Region:Treatment_FTL            118.75  59.378     2 100.428  1.8688 0.15964  
## Sex:Light_orientation           171.09 171.093     1  96.461  5.3848 0.02242 *
## Treatment_bis:Light_orientation 103.02  34.339     3  97.183  1.0807 0.36099  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Speed_to_light6 <- update(LM_Speed_to_light5, . ~ . - Treatment_bis:Light_orientation)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Speed_to_light6)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Speed_to_light + 1e-06) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Region:Treatment_FTL + Sex:Light_orientation
##                       Sum Sq Mean Sq NumDF   DenDF F value Pr(>F)  
## Treatment_bis         167.06  55.685     3  95.654  1.7265 0.1667  
## Region:Treatment_FTL  134.37  67.186     2 101.944  2.0831 0.1298  
## Sex:Light_orientation 159.35 159.351     1  99.407  4.9406 0.0285 *
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Speed_to_light7 <- update(LM_Speed_to_light6, . ~ . - Region:Treatment_FTL)
drop1(LM_Speed_to_light7)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Speed_to_light + 1e-06) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Sex:Light_orientation
##                       Sum Sq Mean Sq NumDF   DenDF F value    Pr(>F)    
## Treatment_bis          94.61  31.538     3  16.084  0.9827 0.4255149    
## Region                 70.04  70.042     1   6.549  2.1824 0.1859947    
## Treatment_FTL         547.45 273.726     2  95.774  8.5289 0.0003901 ***
## Sex:Light_orientation 178.48 178.480     1 101.529  5.5612 0.0202789 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Simplification utile ? A nouveau, vu la complexité du modèle de base on tetse en utilisant le BIC

BIC(LM_Speed_to_light)
## [1] 796.4812
BIC(LM_Speed_to_light1)
## [1] 794.7019
BIC(LM_Speed_to_light2)
## [1] 793.5115
BIC(LM_Speed_to_light3)
## [1] 792.3056
BIC(LM_Speed_to_light4)
## [1] 798.1384
BIC(LM_Speed_to_light5)
## [1] 798.4924
BIC(LM_Speed_to_light6)
## [1] 799.237
BIC(LM_Speed_to_light7)
## [1] 801.0452
LM_Speed_to_light <- LM_Speed_to_light3

5.6.3 Treatment VS Teatment_bis

BIC(lmer(Speed_to_light ~ Treatment_bis + Sex + Region + Treatment_FTL +  Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region + Region:Treatment_FTL +  Treatment_bis:Treatment_FTL + Sex:Light_orientation + Treatment_bis:Light_orientation, data = Data))
## boundary (singular) fit: see help('isSingular')
## [1] 857.2907
BIC(lmer(Speed_to_light ~ Treatment + Sex + Region + Treatment_FTL +  Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment:Region + Region:Treatment_FTL +  Treatment:Treatment_FTL + Sex:Light_orientation + Treatment:Light_orientation, data = Data))
## boundary (singular) fit: see help('isSingular')
## [1] 867.9605
summary(lmer(Speed_to_light ~ Treatment_bis + Sex + Region + Treatment_FTL +  Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region + Region:Treatment_FTL +  Treatment_bis:Treatment_FTL + Sex:Light_orientation + Treatment_bis:Light_orientation, data = Data))$coeff
## boundary (singular) fit: see help('isSingular')
##                                                  Estimate Std. Error       df
## (Intercept)                                    -0.5623216   3.303113 58.72162
## Treatment_bisFull                               0.9399401   4.040219 94.08781
## Treatment_bisSmart                              0.7791469   5.463922 94.23074
## Treatment_bisMixt_smart                        -2.5874488   4.808528 88.48338
## SexMale                                         1.1390076   2.300725 92.62686
## RegionLuxembourg                               -0.6691391   4.036261 55.54039
## Treatment_FTLMix                                3.1826883   3.840637 28.24138
## Treatment_FTLNight                             -0.3892073   4.072936 61.24076
## Light_orientationSouth                          1.1403175   3.167537 93.48623
## Treatment_bisFull:RegionLuxembourg              0.8003086   4.231638 94.82045
## Treatment_bisSmart:RegionLuxembourg             0.1828504   4.970358 92.50078
## Treatment_bisMixt_smart:RegionLuxembourg        2.3822536   5.456243 92.46709
## RegionLuxembourg:Treatment_FTLMix              -2.3098937   4.468951 56.69889
## RegionLuxembourg:Treatment_FTLNight             4.3828561   4.367706 84.72517
## Treatment_bisFull:Treatment_FTLMix              2.2709666   5.191562 94.25902
## Treatment_bisSmart:Treatment_FTLMix            -1.3211757   5.852684 92.75102
## Treatment_bisMixt_smart:Treatment_FTLMix       12.3996733   6.825662 93.91148
## Treatment_bisFull:Treatment_FTLNight            3.7774415   4.995103 92.38591
## Treatment_bisSmart:Treatment_FTLNight          -1.1464974   5.932516 94.32723
## Treatment_bisMixt_smart:Treatment_FTLNight     -0.6730816   5.743953 94.27765
## SexMale:Light_orientationSouth                 -0.8334761   3.401932 90.86562
## Treatment_bisFull:Light_orientationSouth       -1.8298961   4.080678 94.92247
## Treatment_bisSmart:Light_orientationSouth      -1.4208932   4.899039 94.93379
## Treatment_bisMixt_smart:Light_orientationSouth  3.0309144   4.935343 90.16797
##                                                    t value   Pr(>|t|)
## (Intercept)                                    -0.17023989 0.86540667
## Treatment_bisFull                               0.23264582 0.81654177
## Treatment_bisSmart                              0.14259846 0.88691178
## Treatment_bisMixt_smart                        -0.53809580 0.59186189
## SexMale                                         0.49506471 0.62172679
## RegionLuxembourg                               -0.16578191 0.86893058
## Treatment_FTLMix                                0.82868764 0.41423025
## Treatment_FTLNight                             -0.09555939 0.92418253
## Light_orientationSouth                          0.36000128 0.71965820
## Treatment_bisFull:RegionLuxembourg              0.18912500 0.85039907
## Treatment_bisSmart:RegionLuxembourg             0.03678817 0.97073318
## Treatment_bisMixt_smart:RegionLuxembourg        0.43661057 0.66341162
## RegionLuxembourg:Treatment_FTLMix              -0.51687602 0.60725314
## RegionLuxembourg:Treatment_FTLNight             1.00346856 0.31849218
## Treatment_bisFull:Treatment_FTLMix              0.43743417 0.66279714
## Treatment_bisSmart:Treatment_FTLMix            -0.22573843 0.82190154
## Treatment_bisMixt_smart:Treatment_FTLMix        1.81662569 0.07246446
## Treatment_bisFull:Treatment_FTLNight            0.75622887 0.45143603
## Treatment_bisSmart:Treatment_FTLNight          -0.19325654 0.84717359
## Treatment_bisMixt_smart:Treatment_FTLNight     -0.11718090 0.90696598
## SexMale:Light_orientationSouth                 -0.24500083 0.80700824
## Treatment_bisFull:Light_orientationSouth       -0.44842941 0.65486527
## Treatment_bisSmart:Light_orientationSouth      -0.29003509 0.77242196
## Treatment_bisMixt_smart:Light_orientationSouth  0.61412431 0.54067960
summary(lmer(Speed_to_light ~ Treatment + Sex + Region + Treatment_FTL +  Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment:Region + Region:Treatment_FTL +  Treatment:Treatment_FTL + Sex:Light_orientation + Treatment:Light_orientation, data = Data))$coeff
## boundary (singular) fit: see help('isSingular')
##                                          Estimate Std. Error       df
## (Intercept)                           -0.74645972   3.670413 21.53659
## TreatmentFull                          1.60912028   4.090328 97.14306
## TreatmentSmart                        -1.09760525   4.038514 94.52913
## SexMale                                0.74458870   2.298441 96.36699
## RegionLuxembourg                      -0.36300969   4.094070 57.09026
## Treatment_FTLMix                       3.31630826   4.025021 47.97469
## Treatment_FTLNight                    -0.17919563   4.159790 78.61690
## Light_orientationSouth                 1.90659728   3.212126 98.02320
## TreatmentFull:RegionLuxembourg         0.24261371   4.286264 98.25319
## TreatmentSmart:RegionLuxembourg        2.56126675   4.034510 93.10151
## RegionLuxembourg:Treatment_FTLMix     -1.35538964   4.507088 74.73790
## RegionLuxembourg:Treatment_FTLNight    3.94316660   4.228819 93.53565
## TreatmentFull:Treatment_FTLMix         2.23583733   5.239333 96.88374
## TreatmentSmart:Treatment_FTLMix        4.75976090   4.962365 95.27687
## TreatmentFull:Treatment_FTLNight       3.43564109   5.038358 95.41540
## TreatmentSmart:Treatment_FTLNight     -0.53722043   4.822679 98.70254
## SexMale:Light_orientationSouth        -1.17604269   3.408897 94.06381
## TreatmentFull:Light_orientationSouth  -2.33010004   4.139674 99.03175
## TreatmentSmart:Light_orientationSouth -0.08337596   3.880339 99.99425
##                                           t value  Pr(>|t|)
## (Intercept)                           -0.20337214 0.8407535
## TreatmentFull                          0.39339638 0.6948888
## TreatmentSmart                        -0.27178442 0.7863805
## SexMale                                0.32395387 0.7466750
## RegionLuxembourg                      -0.08866718 0.9296567
## Treatment_FTLMix                       0.82392319 0.4140606
## Treatment_FTLNight                    -0.04307804 0.9657485
## Light_orientationSouth                 0.59356238 0.5541721
## TreatmentFull:RegionLuxembourg         0.05660260 0.9549767
## TreatmentSmart:RegionLuxembourg        0.63483964 0.5270901
## RegionLuxembourg:Treatment_FTLMix     -0.30072401 0.7644599
## RegionLuxembourg:Treatment_FTLNight    0.93245113 0.3535041
## TreatmentFull:Treatment_FTLMix         0.42674079 0.6705149
## TreatmentSmart:Treatment_FTLMix        0.95917187 0.3398999
## TreatmentFull:Treatment_FTLNight       0.68189702 0.4969560
## TreatmentSmart:Treatment_FTLNight     -0.11139461 0.9115296
## SexMale:Light_orientationSouth        -0.34499213 0.7308705
## TreatmentFull:Light_orientationSouth  -0.56287043 0.5747952
## TreatmentSmart:Light_orientationSouth -0.02148677 0.9829002

Le meilleur est treatment_bis

Au final, au vu du nombre d’échantillons présent dans chaque termes d’interactions et les p-val associées à ces mêmes interactions, nous décidons de partir sur le modèle le plus simplifié.

5.6.4 Résultats

Analyse des p-val

summary(lmer(log(Speed_to_light+0.000001) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room), data = Data))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Speed_to_light + 1e-06) ~ Treatment_bis + Sex + Region +  
##     Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  
##     (1 | Room)
##    Data: Data
## 
## REML criterion at convergence: 742.9
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.08392 -0.66911 -0.06035  0.64322  2.21103 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept)  3.23538 1.7987  
##  Site     (Intercept)  4.42014 2.1024  
##  Room     (Intercept)  0.08175 0.2859  
##  Residual             34.04042 5.8344  
## Number of obs: 119, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                          Estimate Std. Error        df t value Pr(>|t|)    
## (Intercept)             -12.84959    1.88770  15.56386  -6.807 4.88e-06 ***
## Treatment_bisFull         2.57721    1.42897  96.99756   1.804   0.0744 .  
## Treatment_bisSmart        1.60590    1.63584  36.48376   0.982   0.3327    
## Treatment_bisMixt_smart   2.18386    1.57164   9.43522   1.390   0.1966    
## SexMale                   0.23867    1.14970  95.18672   0.208   0.8360    
## RegionLuxembourg          2.70646    1.92365   6.62081   1.407   0.2046    
## Treatment_FTLMix          4.17538    1.59939 105.95477   2.611   0.0103 *  
## Treatment_FTLNight        6.39674    1.49943 108.75968   4.266 4.26e-05 ***
## Light_orientationSouth   -0.06976    1.12242  98.32173  -0.062   0.9506    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_FTLM T_FTLN
## Trtmnt_bsFl -0.356                                                 
## Trtmnt_bsSm -0.307  0.408                                          
## Trtmnt_bsM_ -0.298  0.447  0.351                                   
## SexMale     -0.262 -0.061  0.081  0.012                            
## ReginLxmbrg -0.440  0.026 -0.086 -0.016  0.016                     
## Trtmnt_FTLM -0.313  0.056  0.037  0.007 -0.105 -0.224              
## Trtmnt_FTLN -0.320  0.023  0.001  0.023 -0.019 -0.173  0.594       
## Lght_rnttnS -0.279 -0.101  0.000 -0.127  0.028  0.060  0.024 -0.086
summary(lmer(log(Speed_to_light+0.000001) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) , data = Data_ref_full))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Speed_to_light + 1e-06) ~ Treatment_bis + Sex + Region +  
##     Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  
##     (1 | Room)
##    Data: Data_ref_full
## 
## REML criterion at convergence: 742.9
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.08392 -0.66911 -0.06035  0.64322  2.21103 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept)  3.23538 1.7987  
##  Site     (Intercept)  4.42014 2.1024  
##  Room     (Intercept)  0.08175 0.2859  
##  Residual             34.04042 5.8344  
## Number of obs: 119, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                          Estimate Std. Error        df t value Pr(>|t|)    
## (Intercept)             -10.27238    1.91961  17.48049  -5.351 4.82e-05 ***
## Treatment_bisDark        -2.57721    1.42897  96.99756  -1.804   0.0744 .  
## Treatment_bisSmart       -0.97131    1.67629  44.48007  -0.579   0.5652    
## Treatment_bisMixt_smart  -0.39335    1.58216   8.81767  -0.249   0.8094    
## SexMale                   0.23867    1.14970  95.18672   0.208   0.8360    
## RegionLuxembourg          2.70646    1.92365   6.62081   1.407   0.2046    
## Treatment_FTLMix          4.17538    1.59939 105.95477   2.611   0.0103 *  
## Treatment_FTLNight        6.39674    1.49943 108.75968   4.266 4.26e-05 ***
## Light_orientationSouth   -0.06976    1.12242  98.32173  -0.062   0.9506    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S Trt_M_ SexMal RgnLxm T_FTLM T_FTLN
## Trtmnt_bsDr -0.394                                                 
## Trtmnt_bsSm -0.334  0.454                                          
## Trtmnt_bsM_ -0.316  0.459  0.371                                   
## SexMale     -0.303  0.061  0.131  0.067                            
## ReginLxmbrg -0.413 -0.026 -0.106 -0.039  0.016                     
## Trtmnt_FTLM -0.266 -0.056 -0.012 -0.044 -0.105 -0.224              
## Trtmnt_FTLN -0.297 -0.023 -0.018  0.002 -0.019 -0.173  0.594       
## Lght_rnttnS -0.350  0.101  0.086 -0.035  0.028  0.060  0.024 -0.086
summary(lmer(log(Speed_to_light+0.000001) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) , data = Data_ref_smart))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Speed_to_light + 1e-06) ~ Treatment_bis + Sex + Region +  
##     Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  
##     (1 | Room)
##    Data: Data_ref_smart
## 
## REML criterion at convergence: 742.9
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.08392 -0.66911 -0.06035  0.64322  2.21103 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept)  3.23538 1.7987  
##  Site     (Intercept)  4.42014 2.1024  
##  Room     (Intercept)  0.08175 0.2859  
##  Residual             34.04042 5.8344  
## Number of obs: 119, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                          Estimate Std. Error        df t value Pr(>|t|)    
## (Intercept)             -11.24369    2.08452  17.01021  -5.394 4.84e-05 ***
## Treatment_bisDark        -1.60590    1.63584  36.48376  -0.982   0.3327    
## Treatment_bisFull         0.97131    1.67629  44.48007   0.579   0.5652    
## Treatment_bisMixt_smart   0.57796    1.82838   2.11320   0.316   0.7804    
## SexMale                   0.23867    1.14970  95.18672   0.208   0.8360    
## RegionLuxembourg          2.70646    1.92365   6.62081   1.407   0.2046    
## Treatment_FTLMix          4.17538    1.59939 105.95477   2.611   0.0103 *  
## Treatment_FTLNight        6.39674    1.49943 108.75968   4.266 4.26e-05 ***
## Light_orientationSouth   -0.06976    1.12242  98.32173  -0.062   0.9506    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trt_M_ SexMal RgnLxm T_FTLM T_FTLN
## Trtmnt_bsDr -0.507                                                 
## Trtmnt_bsFl -0.497  0.628                                          
## Trtmnt_bsM_ -0.449  0.593  0.595                                   
## SexMale     -0.174 -0.081 -0.131 -0.062                            
## ReginLxmbrg -0.466  0.086  0.106  0.063  0.016                     
## Trtmnt_FTLM -0.254 -0.037  0.012 -0.027 -0.105 -0.224              
## Trtmnt_FTLN -0.289 -0.001  0.018  0.019 -0.019 -0.173  0.594       
## Lght_rnttnS -0.252  0.000 -0.086 -0.110  0.028  0.060  0.024 -0.086
summary(lmer(log(Speed_to_light+0.000001) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) , data = Data_ref_mixt_smart))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Speed_to_light + 1e-06) ~ Treatment_bis + Sex + Region +  
##     Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  
##     (1 | Room)
##    Data: Data_ref_mixt_smart
## 
## REML criterion at convergence: 742.9
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.08392 -0.66911 -0.06035  0.64322  2.21103 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept)  3.23538 1.7987  
##  Site     (Intercept)  4.42014 2.1024  
##  Room     (Intercept)  0.08175 0.2859  
##  Residual             34.04042 5.8344  
## Number of obs: 119, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                         Estimate Std. Error        df t value Pr(>|t|)    
## (Intercept)            -10.66573    2.06590   7.61296  -5.163  0.00101 ** 
## Treatment_bisDark       -2.18386    1.57164   9.43522  -1.390  0.19658    
## Treatment_bisFull        0.39335    1.58216   8.81767   0.249  0.80935    
## Treatment_bisSmart      -0.57796    1.82838   2.11320  -0.316  0.78043    
## SexMale                  0.23867    1.14970  95.18672   0.208  0.83599    
## RegionLuxembourg         2.70646    1.92365   6.62081   1.407  0.20461    
## Treatment_FTLMix         4.17538    1.59939 105.95477   2.611  0.01035 *  
## Treatment_FTLNight       6.39674    1.49943 108.75968   4.266 4.26e-05 ***
## Light_orientationSouth  -0.06976    1.12242  98.32173  -0.062  0.95057    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trtm_S SexMal RgnLxm T_FTLM T_FTLN
## Trtmnt_bsDr -0.489                                                 
## Trtmnt_bsFl -0.472  0.589                                          
## Trtmnt_bsSm -0.432  0.546  0.525                                   
## SexMale     -0.231 -0.012 -0.067  0.062                            
## ReginLxmbrg -0.414  0.016  0.039 -0.063  0.016                     
## Trtmnt_FTLM -0.281 -0.007  0.044  0.027 -0.105 -0.224              
## Trtmnt_FTLN -0.275 -0.023 -0.002 -0.019 -0.019 -0.173  0.594       
## Lght_rnttnS -0.352  0.127  0.035  0.110  0.028  0.060  0.024 -0.086
summary(lmer(log(Speed_to_light+0.000001) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) , data = Data_refFTL_Night))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Speed_to_light + 1e-06) ~ Treatment_bis + Sex + Region +  
##     Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  
##     (1 | Room)
##    Data: Data_refFTL_Night
## 
## REML criterion at convergence: 742.9
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.08392 -0.66911 -0.06035  0.64322  2.21103 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept)  3.23538 1.7987  
##  Site     (Intercept)  4.42014 2.1024  
##  Room     (Intercept)  0.08175 0.2859  
##  Residual             34.04042 5.8344  
## Number of obs: 119, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                          Estimate Std. Error        df t value Pr(>|t|)    
## (Intercept)              -6.45285    2.00062  17.11998  -3.225  0.00493 ** 
## Treatment_bisFull         2.57721    1.42897  96.99756   1.804  0.07441 .  
## Treatment_bisSmart        1.60590    1.63584  36.48376   0.982  0.33271    
## Treatment_bisMixt_smart   2.18386    1.57164   9.43522   1.390  0.19658    
## SexMale                   0.23867    1.14970  95.18672   0.208  0.83599    
## RegionLuxembourg          2.70646    1.92365   6.62081   1.407  0.20461    
## Treatment_FTLDay         -6.39674    1.49943 108.75968  -4.266 4.26e-05 ***
## Treatment_FTLMix         -2.22136    1.39932 104.90285  -1.587  0.11542    
## Light_orientationSouth   -0.06976    1.12242  98.32173  -0.062  0.95057    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_FTLD T_FTLM
## Trtmnt_bsFl -0.319                                                 
## Trtmnt_bsSm -0.289  0.408                                          
## Trtmnt_bsM_ -0.264  0.447  0.351                                   
## SexMale     -0.262 -0.061  0.081  0.012                            
## ReginLxmbrg -0.545  0.026 -0.086 -0.016  0.016                     
## Trtmnt_FTLD -0.448 -0.023 -0.001 -0.023  0.019  0.173              
## Trtmnt_FTLM -0.309  0.040  0.041 -0.017 -0.099 -0.071  0.393       
## Lght_rnttnS -0.328 -0.101  0.000 -0.127  0.028  0.060  0.086  0.119
summary(lmer(log(Speed_to_light+0.000001) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) , data = Data_refFTL_Mix))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Speed_to_light + 1e-06) ~ Treatment_bis + Sex + Region +  
##     Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  
##     (1 | Room)
##    Data: Data_refFTL_Mix
## 
## REML criterion at convergence: 742.9
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.08392 -0.66911 -0.06035  0.64322  2.21103 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept)  3.23538 1.7987  
##  Site     (Intercept)  4.42014 2.1024  
##  Room     (Intercept)  0.08175 0.2859  
##  Residual             34.04042 5.8344  
## Number of obs: 119, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                          Estimate Std. Error        df t value Pr(>|t|)    
## (Intercept)              -8.67421    2.05705  17.23126  -4.217 0.000565 ***
## Treatment_bisFull         2.57721    1.42897  96.99756   1.804 0.074407 .  
## Treatment_bisSmart        1.60590    1.63584  36.48377   0.982 0.332714    
## Treatment_bisMixt_smart   2.18386    1.57164   9.43523   1.390 0.196580    
## SexMale                   0.23867    1.14970  95.18672   0.208 0.835988    
## RegionLuxembourg          2.70646    1.92365   6.62081   1.407 0.204612    
## Treatment_FTLDay         -4.17538    1.59939 105.95477  -2.611 0.010347 *  
## Treatment_FTLNight        2.22136    1.39932 104.90285   1.587 0.115419    
## Light_orientationSouth   -0.06976    1.12242  98.32173  -0.062 0.950569    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_FTLD T_FTLN
## Trtmnt_bsFl -0.283                                                 
## Trtmnt_bsSm -0.253  0.408                                          
## Trtmnt_bsM_ -0.268  0.447  0.351                                   
## SexMale     -0.322 -0.061  0.081  0.012                            
## ReginLxmbrg -0.578  0.026 -0.086 -0.016  0.016                     
## Trtmnt_FTLD -0.490 -0.056 -0.037 -0.007  0.105  0.224              
## Trtmnt_FTLN -0.380 -0.040 -0.041  0.017  0.099  0.071  0.507       
## Lght_rnttnS -0.237 -0.101  0.000 -0.127  0.028  0.060 -0.024 -0.119
test1 <- data.frame(Reference_Treatment = "Dark", Reference_Timing = "Day", as.data.frame(( summary(lmer(log(Speed_to_light+0.000001) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room), data = Data))$coeff)[,]))

test2 <- data.frame(Reference_Treatment = "Smart", Reference_Timing = "Day", as.data.frame(( summary(lmer(log(Flight_to_light) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) , data = Data_ref_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test3 <- data.frame(Reference_Treatment = "Full", Reference_Timing = "Day", as.data.frame(( summary(lmer(log(Speed_to_light+0.000001) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) , data = Data_ref_smart))$coeff)[,]))

test4 <- data.frame(Reference_Treatment = "Mixt_smart", Reference_Timing = "Day", as.data.frame(( summary(lmer(log(Speed_to_light+0.000001) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) , data = Data_ref_mixt_smart))$coeff)[,]))

test5 <- data.frame(Reference_Treatment = "Dark", Reference_Timing = "Mixt", as.data.frame(( summary(lmer(log(Speed_to_light+0.000001) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) , data = Data_refFTL_Mix))$coeff)[,]))

test6 <- data.frame(Reference_Treatment = "Dark", Reference_Timing = "Night", as.data.frame(( summary(lmer(log(Speed_to_light+0.000001) ~ Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) , data = Data_refFTL_Night))$coeff)[,]))



Results_Speed_to_light <- rbind(test1,test2,test3,test4,test5,test6)

colnames(Results_Speed_to_light ) <- c("Reference_Treatment", "Reference_Timing" ,"Estimate", "Std. Error", "df", "t.value", "Pr(>|z|)")

write.csv2( Results_Speed_to_light , file = "output/Results_Speed_to_light.csv" )

kable(Results_Speed_to_light , caption = " Temps mis pour voler à la lumière ", padding = 1 )
Temps mis pour voler à la lumière
Reference_Treatment Reference_Timing Estimate Std. Error df t.value Pr(>|z|)
(Intercept) Dark Day -12.8495902 1.8877002 15.563859 -6.8070079 0.0000049
Treatment_bisFull Dark Day 2.5772122 1.4289675 96.997560 1.8035486 0.0744065
Treatment_bisSmart Dark Day 1.6059039 1.6358418 36.483759 0.9816988 0.3327138
Treatment_bisMixt_smart Dark Day 2.1838642 1.5716379 9.435222 1.3895467 0.1965802
SexMale Dark Day 0.2386725 1.1496956 95.186718 0.2075963 0.8359877
RegionLuxembourg Dark Day 2.7064566 1.9236511 6.620815 1.4069374 0.2046123
Treatment_FTLMix Dark Day 4.1753794 1.5993913 105.954771 2.6106053 0.0103473
Treatment_FTLNight Dark Day 6.3967362 1.4994256 108.759682 4.2661245 0.0000426
Light_orientationSouth Dark Day -0.0697592 1.1224196 98.321727 -0.0621507 0.9505690
(Intercept)1 Smart Day 7.1186914 0.7096695 46.131442 10.0309959 0.0000000
Treatment_bisDark Smart Day -0.2634896 0.6012533 48.407207 -0.4382339 0.6631662
Treatment_bisFull1 Smart Day -0.9115651 0.5673725 48.631909 -1.6066431 0.1146070
Treatment_bisMixt_smart1 Smart Day -0.8376421 0.6340025 50.000637 -1.3211968 0.1924501
SexMale1 Smart Day 0.1534485 0.4369309 50.803862 0.3511963 0.7268934
RegionLuxembourg1 Smart Day -0.5369595 0.4806149 20.549394 -1.1172344 0.2767869
Treatment_FTLMix1 Smart Day -1.1781324 0.6445252 49.565032 -1.8279074 0.0735856
Treatment_FTLNight1 Smart Day -1.0428565 0.6062984 50.696778 -1.7200383 0.0915253
Light_orientationSouth1 Smart Day -0.1184522 0.4307041 48.449929 -0.2750200 0.7844703
(Intercept)2 Full Day -11.2436863 2.0845232 17.010205 -5.3938889 0.0000484
Treatment_bisDark1 Full Day -1.6059039 1.6358418 36.483756 -0.9816988 0.3327138
Treatment_bisFull2 Full Day 0.9713083 1.6762885 44.480067 0.5794398 0.5652158
Treatment_bisMixt_smart2 Full Day 0.5779603 1.8283831 2.113202 0.3161046 0.7804343
SexMale2 Full Day 0.2386725 1.1496956 95.186717 0.2075963 0.8359877
RegionLuxembourg2 Full Day 2.7064566 1.9236511 6.620815 1.4069374 0.2046123
Treatment_FTLMix2 Full Day 4.1753794 1.5993913 105.954771 2.6106053 0.0103473
Treatment_FTLNight2 Full Day 6.3967362 1.4994256 108.759682 4.2661245 0.0000426
Light_orientationSouth2 Full Day -0.0697592 1.1224196 98.321727 -0.0621507 0.9505690
(Intercept)3 Mixt_smart Day -10.6657259 2.0659038 7.612956 -5.1627409 0.0010056
Treatment_bisDark2 Mixt_smart Day -2.1838642 1.5716379 9.435222 -1.3895467 0.1965802
Treatment_bisFull3 Mixt_smart Day 0.3933480 1.5821624 8.817670 0.2486142 0.8093527
Treatment_bisSmart1 Mixt_smart Day -0.5779603 1.8283831 2.113203 -0.3161046 0.7804343
SexMale3 Mixt_smart Day 0.2386725 1.1496956 95.186718 0.2075963 0.8359877
RegionLuxembourg3 Mixt_smart Day 2.7064566 1.9236511 6.620815 1.4069374 0.2046123
Treatment_FTLMix3 Mixt_smart Day 4.1753794 1.5993913 105.954771 2.6106053 0.0103473
Treatment_FTLNight3 Mixt_smart Day 6.3967362 1.4994256 108.759682 4.2661245 0.0000426
Light_orientationSouth3 Mixt_smart Day -0.0697592 1.1224196 98.321727 -0.0621507 0.9505690
(Intercept)4 Dark Mixt -8.6742108 2.0570495 17.231259 -4.2168215 0.0005649
Treatment_bisFull4 Dark Mixt 2.5772122 1.4289675 96.997561 1.8035486 0.0744065
Treatment_bisSmart2 Dark Mixt 1.6059040 1.6358418 36.483768 0.9816988 0.3327138
Treatment_bisMixt_smart3 Dark Mixt 2.1838642 1.5716379 9.435226 1.3895467 0.1965802
SexMale4 Dark Mixt 0.2386725 1.1496956 95.186718 0.2075963 0.8359877
RegionLuxembourg4 Dark Mixt 2.7064566 1.9236511 6.620815 1.4069374 0.2046123
Treatment_FTLDay Dark Mixt -4.1753794 1.5993913 105.954771 -2.6106054 0.0103473
Treatment_FTLNight4 Dark Mixt 2.2213568 1.3993185 104.902850 1.5874562 0.1154191
Light_orientationSouth4 Dark Mixt -0.0697592 1.1224196 98.321727 -0.0621507 0.9505690
(Intercept)5 Dark Night -6.4528540 2.0006245 17.119976 -3.2254198 0.0049329
Treatment_bisFull5 Dark Night 2.5772122 1.4289675 96.997560 1.8035486 0.0744065
Treatment_bisSmart3 Dark Night 1.6059039 1.6358418 36.483757 0.9816988 0.3327138
Treatment_bisMixt_smart4 Dark Night 2.1838642 1.5716379 9.435222 1.3895467 0.1965802
SexMale5 Dark Night 0.2386725 1.1496956 95.186718 0.2075963 0.8359877
RegionLuxembourg5 Dark Night 2.7064566 1.9236511 6.620815 1.4069374 0.2046123
Treatment_FTLDay1 Dark Night -6.3967362 1.4994256 108.759682 -4.2661245 0.0000426
Treatment_FTLMix4 Dark Night -2.2213568 1.3993185 104.902850 -1.5874562 0.1154191
Light_orientationSouth5 Dark Night -0.0697592 1.1224196 98.321727 -0.0621507 0.9505690
Info_Speed_to_light <- "
Les individus expérimentés la nuits ou avec la manière mixte (30 min dans l'obscurité avant de faire l'expérience de jour) sont significativement plus rapide que ceux expérimentés le jour. Néanmoins, les individus expérimentés de la manière mixte ne sont pas significativement différent de ceux expérimentés la nuit. Nous pouvons également noter le fait que les individus du traitement Full sont quasiment significativement (p-val = 0.0744) plus rapides que ceux du traitement Dark.
"
Info_Speed_to_light
## [1] "\nLes individus expérimentés la nuits ou avec la manière mixte (30 min dans l'obscurité avant de faire l'expérience de jour) sont significativement plus rapide que ceux expérimentés le jour. Néanmoins, les individus expérimentés de la manière mixte ne sont pas significativement différent de ceux expérimentés la nuit. Nous pouvons également noter le fait que les individus du traitement Full sont quasiment significativement (p-val = 0.0744) plus rapides que ceux du traitement Dark.\n"

5.6.5 Visulaisation

ggplot(Data, aes(x=Treatment_FTL, y=log(Speed_to_light+0.000001), color = Treatment_FTL))+
  geom_boxplot(data = Data %>% filter(Treatment_FTL != "NA"), outlier.shape = NA) +
  geom_jitter(width = 0.2, height = 0.1, alpha = 0.75, aes(shape = Treatment_bis)) +
  labs(title = "Vitesse pour voler à la lumière", x = "Tratiement", y = "log(vitesse pour voler à la lumière m/min)", color = "Timing", shape = "Traitement" ) +
  theme_bw()
## Warning: Removed 330 rows containing missing values (`geom_point()`).

5.7 FTL_by_First_move

5.7.1 Test

LM_FTL_by_First_move <- lmer(Flight_to_light ~ First_move + Treatment_bis + Sex  + Region + Treatment_FTL + Light_orientation + (1|Mother) + (1|Site) + (1|Room)  + Treatment_bis:Sex + Treatment_bis:Region + Treatment_FTL:Sex + Treatment_FTL:Region + Treatment_FTL:Treatment_bis + Light_orientation:Sex + Light_orientation:Region + Light_orientation:Treatment_bis, data = filter(Data))
## boundary (singular) fit: see help('isSingular')
summary(LM_FTL_by_First_move)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Flight_to_light ~ First_move + Treatment_bis + Sex + Region +  
##     Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  
##     (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + Treatment_FTL:Sex +  
##     Treatment_FTL:Region + Treatment_FTL:Treatment_bis + Light_orientation:Sex +  
##     Light_orientation:Region + Light_orientation:Treatment_bis
##    Data: filter(Data)
## 
## REML criterion at convergence: 481.8
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -1.65484 -0.30711 -0.08629  0.33272  1.64804 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 0.000e+00 0.000e+00
##  Site     (Intercept) 5.006e+04 2.237e+02
##  Room     (Intercept) 2.439e-05 4.939e-03
##  Residual             1.706e+05 4.131e+02
## Number of obs: 60, groups:  Mother, 21; Site, 13; Room, 2
## 
## Fixed effects:
##                                                  Estimate Std. Error         df
## (Intercept)                                      458.7688   484.5210    22.1407
## First_move                                         0.6864     0.2787    25.2970
## Treatment_bisFull                                 50.8063   435.9813    21.5918
## Treatment_bisSmart                               687.3076   743.5735    24.2343
## Treatment_bisMixt_smart                         -430.1680   833.9181    28.9967
## SexMale                                         -221.2317   495.2646    28.9920
## RegionLuxembourg                                -123.4481   500.3388    22.7912
## Treatment_FTLMix                                 281.0479   546.0056    27.9143
## Treatment_FTLNight                               569.9451   588.0985    28.8599
## Light_orientationSouth                          -279.3012   481.3959    24.6615
## Treatment_bisFull:SexMale                       -237.8285   458.8940    26.9305
## Treatment_bisSmart:SexMale                        34.0253   501.5470    26.3300
## Treatment_bisMixt_smart:SexMale                  569.9227   505.7951    28.1094
## Treatment_bisFull:RegionLuxembourg               669.2526   455.9144    22.1457
## Treatment_bisSmart:RegionLuxembourg              312.8539   571.7196    26.3189
## Treatment_bisMixt_smart:RegionLuxembourg        -146.5530   531.5947    22.9519
## SexMale:Treatment_FTLMix                         103.9081   525.5852    28.6237
## SexMale:Treatment_FTLNight                       180.1437   491.0847    28.8606
## RegionLuxembourg:Treatment_FTLMix               -574.4767   525.0307    27.7868
## RegionLuxembourg:Treatment_FTLNight             -708.6101   498.5621    28.7557
## Treatment_bisFull:Treatment_FTLMix              -322.7121   532.8287    25.5723
## Treatment_bisSmart:Treatment_FTLMix             -698.5530  1022.4626    25.5066
## Treatment_bisMixt_smart:Treatment_FTLMix         265.1012   857.9328    28.9841
## Treatment_bisFull:Treatment_FTLNight            -665.9761   437.3629    25.1925
## Treatment_bisSmart:Treatment_FTLNight          -1116.2048  1001.2395    26.5237
## Treatment_bisMixt_smart:Treatment_FTLNight       -41.0685   751.1272    28.4605
## SexMale:Light_orientationSouth                  -133.1684   346.5722    23.3404
## RegionLuxembourg:Light_orientationSouth          479.0263   440.9496    25.9508
## Treatment_bisFull:Light_orientationSouth         234.9765   428.6541    25.4788
## Treatment_bisSmart:Light_orientationSouth        -72.2646   516.1990    26.7709
## Treatment_bisMixt_smart:Light_orientationSouth   215.8570   456.6777    26.8200
##                                                t value Pr(>|t|)  
## (Intercept)                                      0.947   0.3539  
## First_move                                       2.462   0.0209 *
## Treatment_bisFull                                0.117   0.9083  
## Treatment_bisSmart                               0.924   0.3644  
## Treatment_bisMixt_smart                         -0.516   0.6099  
## SexMale                                         -0.447   0.6584  
## RegionLuxembourg                                -0.247   0.8073  
## Treatment_FTLMix                                 0.515   0.6108  
## Treatment_FTLNight                               0.969   0.3405  
## Light_orientationSouth                          -0.580   0.5671  
## Treatment_bisFull:SexMale                       -0.518   0.6085  
## Treatment_bisSmart:SexMale                       0.068   0.9464  
## Treatment_bisMixt_smart:SexMale                  1.127   0.2694  
## Treatment_bisFull:RegionLuxembourg               1.468   0.1562  
## Treatment_bisSmart:RegionLuxembourg              0.547   0.5888  
## Treatment_bisMixt_smart:RegionLuxembourg        -0.276   0.7853  
## SexMale:Treatment_FTLMix                         0.198   0.8447  
## SexMale:Treatment_FTLNight                       0.367   0.7164  
## RegionLuxembourg:Treatment_FTLMix               -1.094   0.2833  
## RegionLuxembourg:Treatment_FTLNight             -1.421   0.1660  
## Treatment_bisFull:Treatment_FTLMix              -0.606   0.5501  
## Treatment_bisSmart:Treatment_FTLMix             -0.683   0.5006  
## Treatment_bisMixt_smart:Treatment_FTLMix         0.309   0.7595  
## Treatment_bisFull:Treatment_FTLNight            -1.523   0.1403  
## Treatment_bisSmart:Treatment_FTLNight           -1.115   0.2749  
## Treatment_bisMixt_smart:Treatment_FTLNight      -0.055   0.9568  
## SexMale:Light_orientationSouth                  -0.384   0.7043  
## RegionLuxembourg:Light_orientationSouth          1.086   0.2873  
## Treatment_bisFull:Light_orientationSouth         0.548   0.5883  
## Treatment_bisSmart:Light_orientationSouth       -0.140   0.8897  
## Treatment_bisMixt_smart:Light_orientationSouth   0.473   0.6403  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 31 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
qqnorm(resid(LM_FTL_by_First_move))
qqline(resid(LM_FTL_by_First_move))

Il faut modifier les variables

LM_FTL_by_First_move <- lmer(log(Flight_to_light+0.1) ~ First_move + Treatment_bis + Sex  + Region + Treatment_FTL + Light_orientation + (1|Mother) + (1|Site) + (1|Room)  + Treatment_bis:Sex + Treatment_bis:Region + Treatment_FTL:Sex + Treatment_FTL:Region + Treatment_FTL:Treatment_bis + Light_orientation:Sex + Light_orientation:Region + Light_orientation:Treatment_bis, data = Data)
## boundary (singular) fit: see help('isSingular')
summary(LM_FTL_by_First_move)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Sex +  
##     Region + Treatment_FTL + Light_orientation + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region +  
##     Treatment_FTL:Sex + Treatment_FTL:Region + Treatment_FTL:Treatment_bis +  
##     Light_orientation:Sex + Light_orientation:Region + Light_orientation:Treatment_bis
##    Data: Data
## 
## REML criterion at convergence: 138.8
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -1.40767 -0.48397 -0.03492  0.54980  1.43879 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.2421   0.4921  
##  Site     (Intercept) 0.0000   0.0000  
##  Room     (Intercept) 0.0000   0.0000  
##  Residual             1.2793   1.1311  
## Number of obs: 60, groups:  Mother, 21; Site, 13; Room, 2
## 
## Fixed effects:
##                                                  Estimate Std. Error         df
## (Intercept)                                     4.5206640  1.2752031 22.5814756
## First_move                                      0.0027742  0.0007637 25.9399670
## Treatment_bisFull                               0.4905899  1.1985789 18.8173588
## Treatment_bisSmart                              1.9616369  2.0467853 25.7519860
## Treatment_bisMixt_smart                         1.7572440  2.2560738 28.8793898
## SexMale                                        -0.4264251  1.3254690 28.8149143
## RegionLuxembourg                                0.9364813  1.3158748 24.8838688
## Treatment_FTLMix                               -1.2701101  1.4414885 28.3839150
## Treatment_FTLNight                              1.4607212  1.5872250 28.6864351
## Light_orientationSouth                         -0.3926240  1.3173256 24.7022116
## Treatment_bisFull:SexMale                      -1.0502182  1.2568793 28.6715341
## Treatment_bisSmart:SexMale                      0.2014877  1.3573430 25.7011493
## Treatment_bisMixt_smart:SexMale                 0.3672156  1.3766700 28.6817044
## Treatment_bisFull:RegionLuxembourg              0.3762882  1.2557452 20.8173587
## Treatment_bisSmart:RegionLuxembourg            -0.2436433  1.5658389 25.9185577
## Treatment_bisMixt_smart:RegionLuxembourg       -0.7540643  1.4469452 20.4052876
## SexMale:Treatment_FTLMix                       -0.0954151  1.4373403 28.9551454
## SexMale:Treatment_FTLNight                      0.8437118  1.3414535 28.8059973
## RegionLuxembourg:Treatment_FTLMix              -0.2636456  1.4250429 24.8713664
## RegionLuxembourg:Treatment_FTLNight            -2.7770093  1.3581844 27.0932145
## Treatment_bisFull:Treatment_FTLMix              0.5770367  1.4360162 23.1770933
## Treatment_bisSmart:Treatment_FTLMix            -0.2076286  2.8024666 27.0272499
## Treatment_bisMixt_smart:Treatment_FTLMix       -2.4980074  2.3250355 28.8190234
## Treatment_bisFull:Treatment_FTLNight           -1.8471187  1.2033707 26.1134533
## Treatment_bisSmart:Treatment_FTLNight          -1.5201624  2.7453523 28.2815281
## Treatment_bisMixt_smart:Treatment_FTLNight     -1.7034675  2.0056447 28.8982385
## SexMale:Light_orientationSouth                 -0.6923843  0.9697672 26.2831890
## RegionLuxembourg:Light_orientationSouth         1.5107996  1.2082026 25.9742090
## Treatment_bisFull:Light_orientationSouth        1.4261489  1.1876493 27.9277644
## Treatment_bisSmart:Light_orientationSouth      -0.0356494  1.4122159 28.7377128
## Treatment_bisMixt_smart:Light_orientationSouth  0.0201753  1.2367939 25.3048323
##                                                t value Pr(>|t|)   
## (Intercept)                                      3.545  0.00176 **
## First_move                                       3.633  0.00121 **
## Treatment_bisFull                                0.409  0.68693   
## Treatment_bisSmart                               0.958  0.34677   
## Treatment_bisMixt_smart                          0.779  0.44238   
## SexMale                                         -0.322  0.74999   
## RegionLuxembourg                                 0.712  0.48328   
## Treatment_FTLMix                                -0.881  0.38566   
## Treatment_FTLNight                               0.920  0.36509   
## Light_orientationSouth                          -0.298  0.76816   
## Treatment_bisFull:SexMale                       -0.836  0.41030   
## Treatment_bisSmart:SexMale                       0.148  0.88315   
## Treatment_bisMixt_smart:SexMale                  0.267  0.79158   
## Treatment_bisFull:RegionLuxembourg               0.300  0.76741   
## Treatment_bisSmart:RegionLuxembourg             -0.156  0.87755   
## Treatment_bisMixt_smart:RegionLuxembourg        -0.521  0.60788   
## SexMale:Treatment_FTLMix                        -0.066  0.94753   
## SexMale:Treatment_FTLNight                       0.629  0.53434   
## RegionLuxembourg:Treatment_FTLMix               -0.185  0.85472   
## RegionLuxembourg:Treatment_FTLNight             -2.045  0.05072 . 
## Treatment_bisFull:Treatment_FTLMix               0.402  0.69149   
## Treatment_bisSmart:Treatment_FTLMix             -0.074  0.94149   
## Treatment_bisMixt_smart:Treatment_FTLMix        -1.074  0.29156   
## Treatment_bisFull:Treatment_FTLNight            -1.535  0.13682   
## Treatment_bisSmart:Treatment_FTLNight           -0.554  0.58412   
## Treatment_bisMixt_smart:Treatment_FTLNight      -0.849  0.40268   
## SexMale:Light_orientationSouth                  -0.714  0.48154   
## RegionLuxembourg:Light_orientationSouth          1.250  0.22228   
## Treatment_bisFull:Light_orientationSouth         1.201  0.23991   
## Treatment_bisSmart:Light_orientationSouth       -0.025  0.98004   
## Treatment_bisMixt_smart:Light_orientationSouth   0.016  0.98711   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 31 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
qqnorm(resid(LM_FTL_by_First_move))
qqline(resid(LM_FTL_by_First_move))

Peut mieux faire mais on s’en contentera

Homogénité des variances

plot(LM_FTL_by_First_move)

Distance de cook

plot(cooks.distance(LM_FTL_by_First_move))

5.7.2 Simplification du modèle

drop1(LM_FTL_by_First_move)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + Treatment_FTL:Sex + Treatment_FTL:Region + Treatment_FTL:Treatment_bis + Light_orientation:Sex + Light_orientation:Region + Light_orientation:Treatment_bis
##                                  Sum Sq Mean Sq NumDF  DenDF F value   Pr(>F)
## First_move                      16.8825 16.8825     1 25.940 13.1966 0.001212
## Treatment_bis:Sex                2.8367  0.9456     3 24.688  0.7391 0.538797
## Treatment_bis:Region             1.3690  0.4563     3 22.821  0.3567 0.784750
## Sex:Treatment_FTL                1.3708  0.6854     2 28.815  0.5358 0.590939
## Region:Treatment_FTL            10.2933  5.1467     2 26.742  4.0230 0.029686
## Treatment_bis:Treatment_FTL      9.7723  1.6287     6 27.114  1.2731 0.302334
## Sex:Light_orientation            0.6521  0.6521     1 26.283  0.5098 0.481539
## Region:Light_orientation         2.0004  2.0004     1 25.974  1.5636 0.222283
## Treatment_bis:Light_orientation  2.9611  0.9870     3 27.964  0.7715 0.519697
##                                   
## First_move                      **
## Treatment_bis:Sex                 
## Treatment_bis:Region              
## Sex:Treatment_FTL                 
## Region:Treatment_FTL            * 
## Treatment_bis:Treatment_FTL       
## Sex:Light_orientation             
## Region:Light_orientation          
## Treatment_bis:Light_orientation   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_FTL_by_First_move1 <- update(LM_FTL_by_First_move, . ~ . - Treatment_bis:Region)
## boundary (singular) fit: see help('isSingular')
drop1(LM_FTL_by_First_move1)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Sex:Treatment_FTL + Region:Treatment_FTL + Treatment_bis:Treatment_FTL + Sex:Light_orientation + Region:Light_orientation + Treatment_bis:Light_orientation
##                                  Sum Sq Mean Sq NumDF  DenDF F value    Pr(>F)
## First_move                      24.7990 24.7990     1 31.915 20.1358 8.799e-05
## Treatment_bis:Sex                3.4216  1.1405     3 27.932  0.9261  0.441091
## Sex:Treatment_FTL                2.0214  1.0107     2 31.418  0.8206  0.449359
## Region:Treatment_FTL            14.6080  7.3040     2 29.455  5.9306  0.006849
## Treatment_bis:Treatment_FTL     16.3227  2.7205     6 29.390  2.2089  0.070372
## Sex:Light_orientation            0.9104  0.9104     1 29.893  0.7392  0.396758
## Region:Light_orientation         2.9534  2.9534     1 27.731  2.3980  0.132827
## Treatment_bis:Light_orientation  3.2886  1.0962     3 31.094  0.8901  0.457116
##                                    
## First_move                      ***
## Treatment_bis:Sex                  
## Sex:Treatment_FTL                  
## Region:Treatment_FTL            ** 
## Treatment_bis:Treatment_FTL     .  
## Sex:Light_orientation              
## Region:Light_orientation           
## Treatment_bis:Light_orientation    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_FTL_by_First_move2 <- update(LM_FTL_by_First_move1, . ~ . - Treatment_bis:Light_orientation)
## boundary (singular) fit: see help('isSingular')
drop1(LM_FTL_by_First_move2)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Sex:Treatment_FTL + Region:Treatment_FTL + Treatment_bis:Treatment_FTL + Sex:Light_orientation + Region:Light_orientation
##                              Sum Sq Mean Sq NumDF  DenDF F value    Pr(>F)    
## First_move                  25.7744 25.7744     1 34.758 19.9656 7.995e-05 ***
## Treatment_bis:Sex            2.1451  0.7150     3 29.317  0.5539  0.649609    
## Sex:Treatment_FTL            1.0387  0.5194     2 33.719  0.4023  0.671940    
## Region:Treatment_FTL        14.0748  7.0374     2 30.030  5.4514  0.009555 ** 
## Treatment_bis:Treatment_FTL 14.5688  2.4281     6 32.128  1.8809  0.114626    
## Sex:Light_orientation        0.1840  0.1840     1 33.209  0.1426  0.708158    
## Region:Light_orientation     3.0205  3.0205     1 30.899  2.3398  0.136283    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_FTL_by_First_move3 <- update(LM_FTL_by_First_move2, . ~ . - Sex:Treatment_FTL)
## boundary (singular) fit: see help('isSingular')
drop1(LM_FTL_by_First_move3)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Region:Treatment_FTL + Treatment_bis:Treatment_FTL + Sex:Light_orientation + Region:Light_orientation
##                              Sum Sq Mean Sq NumDF  DenDF F value    Pr(>F)    
## First_move                  25.0975 25.0975     1 36.948 21.3927 4.473e-05 ***
## Treatment_bis:Sex            2.0485  0.6828     3 31.222  0.5820  0.631216    
## Region:Treatment_FTL        15.2699  7.6350     2 35.744  6.5079  0.003889 ** 
## Treatment_bis:Treatment_FTL 14.2613  2.3769     6 32.020  2.0260  0.090927 .  
## Sex:Light_orientation        0.1573  0.1573     1 33.982  0.1341  0.716507    
## Region:Light_orientation     3.0181  3.0181     1 30.781  2.5726  0.118942    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_FTL_by_First_move4 <- update(LM_FTL_by_First_move3, . ~ . - Sex:Light_orientation)
## boundary (singular) fit: see help('isSingular')
drop1(LM_FTL_by_First_move4)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Region:Treatment_FTL + Treatment_bis:Treatment_FTL + Region:Light_orientation
##                              Sum Sq Mean Sq NumDF  DenDF F value    Pr(>F)    
## First_move                  26.0939 26.0939     1 37.576 21.8001 3.791e-05 ***
## Treatment_bis:Sex            2.4231  0.8077     3 34.101  0.6748  0.573457    
## Region:Treatment_FTL        15.7533  7.8766     2 36.269  6.5805  0.003645 ** 
## Treatment_bis:Treatment_FTL 14.4040  2.4007     6 35.308  2.0056  0.090975 .  
## Region:Light_orientation     2.9022  2.9022     1 34.334  2.4246  0.128613    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_FTL_by_First_move5 <- update(LM_FTL_by_First_move4, . ~ . - Treatment_bis:Sex)
## boundary (singular) fit: see help('isSingular')
drop1(LM_FTL_by_First_move5)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Region:Treatment_FTL + Treatment_bis:Treatment_FTL + Region:Light_orientation
##                              Sum Sq Mean Sq NumDF  DenDF F value    Pr(>F)    
## First_move                  25.1341 25.1341     1 40.983 23.3721 1.909e-05 ***
## Sex                          1.8001  1.8001     1 35.236  1.6739  0.204152    
## Region:Treatment_FTL        16.9474  8.4737     2 40.305  7.8797  0.001293 ** 
## Treatment_bis:Treatment_FTL 16.0232  2.6705     6 37.166  2.4833  0.040368 *  
## Region:Light_orientation     5.1916  5.1916     1 38.612  4.8276  0.034075 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_FTL_by_First_move6 <- update(LM_FTL_by_First_move5, . ~ . - Sex)
## boundary (singular) fit: see help('isSingular')
drop1(LM_FTL_by_First_move6)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Region:Treatment_FTL + Treatment_bis:Treatment_FTL + Region:Light_orientation
##                              Sum Sq Mean Sq NumDF  DenDF F value    Pr(>F)    
## First_move                  26.3200 26.3200     1 40.479 22.1036 2.984e-05 ***
## Region:Treatment_FTL        17.2297  8.6148     2 39.449  7.2348  0.002105 ** 
## Treatment_bis:Treatment_FTL 15.5070  2.5845     6 40.273  2.1705  0.066059 .  
## Region:Light_orientation     5.9456  5.9456     1 40.826  4.9932  0.030984 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_FTL_by_First_move7 <- update(LM_FTL_by_First_move6, . ~ . - Treatment_bis:Treatment_FTL)
## boundary (singular) fit: see help('isSingular')
drop1(LM_FTL_by_First_move7)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Region:Treatment_FTL + Region:Light_orientation
##                          Sum Sq Mean Sq NumDF  DenDF F value    Pr(>F)    
## First_move               32.020  32.020     1 45.061 23.3073 1.624e-05 ***
## Treatment_bis            11.267   3.756     3 45.070  2.7336  0.054648 .  
## Region:Treatment_FTL     18.590   9.295     2 44.910  6.7656  0.002702 ** 
## Region:Light_orientation  2.588   2.588     1 47.554  1.8835  0.176377    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_FTL_by_First_move8 <- update(LM_FTL_by_First_move7, . ~ . - Region:Light_orientation)
## boundary (singular) fit: see help('isSingular')
drop1(LM_FTL_by_First_move8)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) + Region:Treatment_FTL
##                      Sum Sq Mean Sq NumDF  DenDF F value    Pr(>F)    
## First_move           49.966  49.966     1 45.379 34.5505 4.609e-07 ***
## Treatment_bis        10.605   3.535     3 46.986  2.4444  0.075647 .  
## Light_orientation     4.792   4.792     1 48.343  3.3136  0.074902 .  
## Region:Treatment_FTL 22.548  11.274     2 45.271  7.7957  0.001232 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Au vu de la complexité du modèle de base, nous utilisons le BIC

BIC(LM_FTL_by_First_move)
## [1] 282.0972
BIC(LM_FTL_by_First_move8)
## [1] 256.6461
BIC(LM_FTL_by_First_move7)
## [1] 257.729
BIC(LM_FTL_by_First_move6)
## [1] 258.782
BIC(LM_FTL_by_First_move5)
## [1] 261.7209
BIC(LM_FTL_by_First_move4)
## [1] 266.9854
BIC(LM_FTL_by_First_move3)
## [1] 269.6751
BIC(LM_FTL_by_First_move2)
## [1] 273.4821
BIC(LM_FTL_by_First_move1)
## [1] 277.5541

Le meilleur modèle est le plus simplifié

LM_FTL_by_First_move <- LM_FTL_by_First_move8

5.7.3 Treatment VS Teatment_bis

AIC(lmer(log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Region +  Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  (1 | Room) + Region:Treatment_FTL, data = Data))
## boundary (singular) fit: see help('isSingular')
## [1] 225.2309
AIC(lmer(log(Flight_to_light + 0.1) ~ First_move + Treatment + Region +  Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  (1 | Room) + Region:Treatment_FTL, data = Data))
## boundary (singular) fit: see help('isSingular')
## [1] 228.0248
summary(lmer(log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Region +  Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  (1 | Room) + Region:Treatment_FTL, data = Data))$coeff
## boundary (singular) fit: see help('isSingular')
##                                         Estimate   Std. Error       df
## (Intercept)                          4.463238865 0.7238142958 42.59248
## First_move                           0.003210518 0.0005461953 45.37934
## Treatment_bisFull                   -0.154709102 0.4459508043 46.70485
## Treatment_bisSmart                   0.623988518 0.4936234677 46.47717
## Treatment_bisMixt_smart             -0.729863048 0.4939461349 45.11992
## RegionLuxembourg                     1.108700393 0.8295757898 38.57466
## Treatment_FTLMix                    -1.818700940 0.7098137022 38.83903
## Treatment_FTLNight                   1.051929611 0.6814252455 41.21263
## Light_orientationSouth               0.637614152 0.3502738958 48.34264
## RegionLuxembourg:Treatment_FTLMix    0.545119326 1.0414989251 43.65128
## RegionLuxembourg:Treatment_FTLNight -2.554254866 0.9748974069 46.23410
##                                        t value     Pr(>|t|)
## (Intercept)                          6.1662762 2.171262e-07
## First_move                           5.8779665 4.609397e-07
## Treatment_bisFull                   -0.3469197 7.302100e-01
## Treatment_bisSmart                   1.2640982 2.124979e-01
## Treatment_bisMixt_smart             -1.4776167 1.464573e-01
## RegionLuxembourg                     1.3364667 1.892269e-01
## Treatment_FTLMix                    -2.5622229 1.439439e-02
## Treatment_FTLNight                   1.5437198 1.303010e-01
## Light_orientationSouth               1.8203302 7.490230e-02
## RegionLuxembourg:Treatment_FTLMix    0.5233988 6.033439e-01
## RegionLuxembourg:Treatment_FTLNight -2.6200243 1.185581e-02
summary(lmer(log(Flight_to_light + 0.1) ~ First_move + Treatment + Region +  Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  (1 | Room) + Region:Treatment_FTL, data = Data))$coeff
## boundary (singular) fit: see help('isSingular')
##                                         Estimate   Std. Error       df
## (Intercept)                          4.692353438 0.8072534789 13.73228
## First_move                           0.003063428 0.0005508164 45.43420
## TreatmentFull                       -0.109496098 0.4543715882 47.04508
## TreatmentSmart                       0.042919240 0.4352120203 44.95577
## RegionLuxembourg                     1.091384048 0.8434533552 40.67988
## Treatment_FTLMix                    -1.848885945 0.7189392884 39.96336
## Treatment_FTLNight                   0.784744887 0.6762032751 41.15971
## Light_orientationSouth               0.466844418 0.3431429862 48.29462
## RegionLuxembourg:Treatment_FTLMix    0.294829518 1.0722105690 45.64827
## RegionLuxembourg:Treatment_FTLNight -2.482617429 0.9947859722 48.25633
##                                         t value     Pr(>|t|)
## (Intercept)                          5.81273858 4.861816e-05
## First_move                           5.56161363 1.353537e-06
## TreatmentFull                       -0.24098359 8.106150e-01
## TreatmentSmart                       0.09861685 9.218809e-01
## RegionLuxembourg                     1.29394713 2.029820e-01
## Treatment_FTLMix                    -2.57168578 1.394597e-02
## Treatment_FTLNight                   1.16051625 2.525258e-01
## Light_orientationSouth               1.36049529 1.799895e-01
## RegionLuxembourg:Treatment_FTLMix    0.27497352 7.845774e-01
## RegionLuxembourg:Treatment_FTLNight -2.49562971 1.604410e-02

On garde Treatment_bis

5.7.4 Résultats

Analyse des p-val

summary(lmer(log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Region +  Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  (1 | Room) + Region:Treatment_FTL, data = Data))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Region +  
##     Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  
##     (1 | Room) + Region:Treatment_FTL
##    Data: Data
## 
## REML criterion at convergence: 195.2
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.09824 -0.49951 -0.03767  0.42591  2.39093 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 2.033e-02 1.426e-01
##  Site     (Intercept) 0.000e+00 0.000e+00
##  Room     (Intercept) 2.225e-09 4.717e-05
##  Residual             1.446e+00 1.203e+00
## Number of obs: 60, groups:  Mother, 21; Site, 13; Room, 2
## 
## Fixed effects:
##                                       Estimate Std. Error         df t value
## (Intercept)                          4.4632389  0.7238143 42.5924788   6.166
## First_move                           0.0032105  0.0005462 45.3793363   5.878
## Treatment_bisFull                   -0.1547091  0.4459508 46.7048466  -0.347
## Treatment_bisSmart                   0.6239885  0.4936235 46.4771663   1.264
## Treatment_bisMixt_smart             -0.7298630  0.4939461 45.1199217  -1.478
## RegionLuxembourg                     1.1087004  0.8295758 38.5746579   1.336
## Treatment_FTLMix                    -1.8187009  0.7098137 38.8390325  -2.562
## Treatment_FTLNight                   1.0519296  0.6814252 41.2126319   1.544
## Light_orientationSouth               0.6376142  0.3502739 48.3426426   1.820
## RegionLuxembourg:Treatment_FTLMix    0.5451193  1.0414989 43.6512788   0.523
## RegionLuxembourg:Treatment_FTLNight -2.5542549  0.9748974 46.2340992  -2.620
##                                     Pr(>|t|)    
## (Intercept)                         2.17e-07 ***
## First_move                          4.61e-07 ***
## Treatment_bisFull                     0.7302    
## Treatment_bisSmart                    0.2125    
## Treatment_bisMixt_smart               0.1465    
## RegionLuxembourg                      0.1892    
## Treatment_FTLMix                      0.0144 *  
## Treatment_FTLNight                    0.1303    
## Light_orientationSouth                0.0749 .  
## RegionLuxembourg:Treatment_FTLMix     0.6033    
## RegionLuxembourg:Treatment_FTLNight   0.0119 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Frst_m Trtm_F Trtm_S Trt_M_ RgnLxm T_FTLM T_FTLN Lght_S
## First_move  -0.482                                                        
## Trtmnt_bsFl -0.456  0.210                                                 
## Trtmnt_bsSm -0.475  0.109  0.537                                          
## Trtmnt_bsM_ -0.276 -0.003  0.544  0.479                                   
## ReginLxmbrg -0.618  0.152  0.093  0.236  0.114                            
## Trtmnt_FTLM -0.481 -0.221  0.050  0.142  0.076  0.441                     
## Trtmnt_FTLN -0.717  0.326  0.080  0.143 -0.091  0.521  0.471              
## Lght_rnttnS -0.433  0.301 -0.003  0.148 -0.180  0.221  0.053  0.228       
## RgnL:T_FTLM  0.406  0.183 -0.106 -0.268 -0.219 -0.774 -0.724 -0.319 -0.087
## RgnL:T_FTLN  0.551 -0.167 -0.058 -0.234 -0.013 -0.861 -0.376 -0.700 -0.251
##             RL:T_FTLM
## First_move           
## Trtmnt_bsFl          
## Trtmnt_bsSm          
## Trtmnt_bsM_          
## ReginLxmbrg          
## Trtmnt_FTLM          
## Trtmnt_FTLN          
## Lght_rnttnS          
## RgnL:T_FTLM          
## RgnL:T_FTLN  0.654   
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Region +  Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  (1 | Room) + Region:Treatment_FTL, data = Data_ref_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Region +  
##     Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  
##     (1 | Room) + Region:Treatment_FTL
##    Data: Data_ref_smart
## 
## REML criterion at convergence: 195.2
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.09824 -0.49951 -0.03767  0.42591  2.39093 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 2.033e-02 1.426e-01
##  Site     (Intercept) 0.000e+00 0.000e+00
##  Room     (Intercept) 2.225e-09 4.717e-05
##  Residual             1.446e+00 1.203e+00
## Number of obs: 60, groups:  Mother, 21; Site, 13; Room, 2
## 
## Fixed effects:
##                                       Estimate Std. Error         df t value
## (Intercept)                          5.0872274  0.6543759 40.9190037   7.774
## First_move                           0.0032105  0.0005462 45.3793363   5.878
## Treatment_bisDark                   -0.6239885  0.4936235 46.4771662  -1.264
## Treatment_bisFull                   -0.7786976  0.4537666 46.9076418  -1.716
## Treatment_bisMixt_smart             -1.3538516  0.5040639 48.6512049  -2.686
## RegionLuxembourg                     1.1087004  0.8295758 38.5746580   1.336
## Treatment_FTLMix                    -1.8187009  0.7098137 38.8390327  -2.562
## Treatment_FTLNight                   1.0519296  0.6814252 41.2126320   1.544
## Light_orientationSouth               0.6376142  0.3502739 48.3426426   1.820
## RegionLuxembourg:Treatment_FTLMix    0.5451193  1.0414989 43.6512790   0.523
## RegionLuxembourg:Treatment_FTLNight -2.5542549  0.9748974 46.2340993  -2.620
##                                     Pr(>|t|)    
## (Intercept)                         1.38e-09 ***
## First_move                          4.61e-07 ***
## Treatment_bisDark                    0.21250    
## Treatment_bisFull                    0.09275 .  
## Treatment_bisMixt_smart              0.00987 ** 
## RegionLuxembourg                     0.18923    
## Treatment_FTLMix                     0.01439 *  
## Treatment_FTLNight                   0.13030    
## Light_orientationSouth               0.07490 .  
## RegionLuxembourg:Treatment_FTLMix    0.60334    
## RegionLuxembourg:Treatment_FTLNight  0.01186 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Frst_m Trtm_D Trtm_F Trt_M_ RgnLxm T_FTLM T_FTLN Lght_S
## First_move  -0.451                                                        
## Trtmnt_bsDr -0.229 -0.109                                                 
## Trtmnt_bsFl -0.346  0.088  0.560                                          
## Trtmnt_bsM_ -0.169 -0.110  0.510  0.562                                   
## ReginLxmbrg -0.506  0.152 -0.236 -0.166 -0.120                            
## Trtmnt_FTLM -0.424 -0.221 -0.142 -0.106 -0.065  0.441                     
## Trtmnt_FTLN -0.685  0.326 -0.143 -0.077 -0.229  0.521  0.471              
## Lght_rnttnS -0.367  0.301 -0.148 -0.164 -0.322  0.221  0.053  0.228       
## RgnL:T_FTLM  0.247  0.183  0.268  0.188  0.048 -0.774 -0.724 -0.319 -0.087
## RgnL:T_FTLN  0.433 -0.167  0.234  0.198  0.217 -0.861 -0.376 -0.700 -0.251
##             RL:T_FTLM
## First_move           
## Trtmnt_bsDr          
## Trtmnt_bsFl          
## Trtmnt_bsM_          
## ReginLxmbrg          
## Trtmnt_FTLM          
## Trtmnt_FTLN          
## Lght_rnttnS          
## RgnL:T_FTLM          
## RgnL:T_FTLN  0.654   
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Region +  Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  (1 | Room) + Region:Treatment_FTL, data = Data_ref_full))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Region +  
##     Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  
##     (1 | Room) + Region:Treatment_FTL
##    Data: Data_ref_full
## 
## REML criterion at convergence: 195.2
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.09824 -0.49951 -0.03767  0.42591  2.39093 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 2.033e-02 1.426e-01
##  Site     (Intercept) 0.000e+00 0.000e+00
##  Room     (Intercept) 2.225e-09 4.717e-05
##  Residual             1.446e+00 1.203e+00
## Number of obs: 60, groups:  Mother, 21; Site, 13; Room, 2
## 
## Fixed effects:
##                                       Estimate Std. Error         df t value
## (Intercept)                          4.3085298  0.6545656 41.1846073   6.582
## First_move                           0.0032105  0.0005462 45.3793363   5.878
## Treatment_bisDark                    0.1547091  0.4459508 46.7048466   0.347
## Treatment_bisSmart                   0.7786976  0.4537666 46.9076420   1.716
## Treatment_bisMixt_smart             -0.5751539  0.4506316 48.8322907  -1.276
## RegionLuxembourg                     1.1087004  0.8295758 38.5746579   1.336
## Treatment_FTLMix                    -1.8187009  0.7098137 38.8390326  -2.562
## Treatment_FTLNight                   1.0519296  0.6814252 41.2126320   1.544
## Light_orientationSouth               0.6376142  0.3502739 48.3426426   1.820
## RegionLuxembourg:Treatment_FTLMix    0.5451193  1.0414989 43.6512787   0.523
## RegionLuxembourg:Treatment_FTLNight -2.5542549  0.9748974 46.2340992  -2.620
##                                     Pr(>|t|)    
## (Intercept)                         6.30e-08 ***
## First_move                          4.61e-07 ***
## Treatment_bisDark                     0.7302    
## Treatment_bisSmart                    0.0927 .  
## Treatment_bisMixt_smart               0.2079    
## RegionLuxembourg                      0.1892    
## Treatment_FTLMix                      0.0144 *  
## Treatment_FTLNight                    0.1303    
## Light_orientationSouth                0.0749 .  
## RegionLuxembourg:Treatment_FTLMix     0.6033    
## RegionLuxembourg:Treatment_FTLNight   0.0119 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Frst_m Trtm_D Trtm_S Trt_M_ RgnLxm T_FTLM T_FTLN Lght_S
## First_move  -0.390                                                        
## Trtmnt_bsDr -0.177 -0.210                                                 
## Trtmnt_bsSm -0.347 -0.088  0.398                                          
## Trtmnt_bsM_ -0.103 -0.211  0.393  0.379                                   
## ReginLxmbrg -0.620  0.152 -0.093  0.166  0.033                            
## Trtmnt_FTLM -0.498 -0.221 -0.050  0.106  0.034  0.441                     
## Trtmnt_FTLN -0.738  0.326 -0.080  0.077 -0.179  0.521  0.471              
## Lght_rnttnS -0.481  0.301  0.003  0.164 -0.195  0.221  0.053  0.228       
## RgnL:T_FTLM  0.377  0.183  0.106 -0.188 -0.136 -0.774 -0.724 -0.319 -0.087
## RgnL:T_FTLN  0.570 -0.167  0.058 -0.198  0.043 -0.861 -0.376 -0.700 -0.251
##             RL:T_FTLM
## First_move           
## Trtmnt_bsDr          
## Trtmnt_bsSm          
## Trtmnt_bsM_          
## ReginLxmbrg          
## Trtmnt_FTLM          
## Trtmnt_FTLN          
## Lght_rnttnS          
## RgnL:T_FTLM          
## RgnL:T_FTLN  0.654   
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Region +  Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  (1 | Room) + Region:Treatment_FTL, data = Data_ref_mixt_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Region +  
##     Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  
##     (1 | Room) + Region:Treatment_FTL
##    Data: Data_ref_mixt_smart
## 
## REML criterion at convergence: 195.2
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.09824 -0.49951 -0.03767  0.42591  2.39093 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 2.033e-02 1.426e-01
##  Site     (Intercept) 0.000e+00 0.000e+00
##  Room     (Intercept) 2.225e-09 4.718e-05
##  Residual             1.446e+00 1.203e+00
## Number of obs: 60, groups:  Mother, 21; Site, 13; Room, 2
## 
## Fixed effects:
##                                       Estimate Std. Error         df t value
## (Intercept)                          3.7333758  0.7555112 43.4146328   4.942
## First_move                           0.0032105  0.0005462 45.3793363   5.878
## Treatment_bisDark                    0.7298630  0.4939461 45.1199224   1.478
## Treatment_bisFull                    0.5751539  0.4506316 48.8322905   1.276
## Treatment_bisSmart                   1.3538516  0.5040639 48.6512095   2.686
## RegionLuxembourg                     1.1087004  0.8295758 38.5746582   1.336
## Treatment_FTLMix                    -1.8187009  0.7098137 38.8390327  -2.562
## Treatment_FTLNight                   1.0519296  0.6814252 41.2126323   1.544
## Light_orientationSouth               0.6376142  0.3502739 48.3426426   1.820
## RegionLuxembourg:Treatment_FTLMix    0.5451193  1.0414989 43.6512789   0.523
## RegionLuxembourg:Treatment_FTLNight -2.5542549  0.9748974 46.2340994  -2.620
##                                     Pr(>|t|)    
## (Intercept)                         1.20e-05 ***
## First_move                          4.61e-07 ***
## Treatment_bisDark                    0.14646    
## Treatment_bisFull                    0.20788    
## Treatment_bisSmart                   0.00987 ** 
## RegionLuxembourg                     0.18923    
## Treatment_FTLMix                     0.01439 *  
## Treatment_FTLNight                   0.13030    
## Light_orientationSouth               0.07490 .  
## RegionLuxembourg:Treatment_FTLMix    0.60334    
## RegionLuxembourg:Treatment_FTLNight  0.01186 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Frst_m Trtm_D Trtm_F Trtm_S RgnLxm T_FTLM T_FTLN Lght_S
## First_move  -0.464                                                        
## Trtmnt_bsDr -0.390  0.003                                                 
## Trtmnt_bsFl -0.507  0.211  0.557                                          
## Trtmnt_bsSm -0.521  0.110  0.511  0.553                                   
## ReginLxmbrg -0.518  0.152 -0.114 -0.033  0.120                            
## Trtmnt_FTLM -0.411 -0.221 -0.076 -0.034  0.065  0.441                     
## Trtmnt_FTLN -0.746  0.326  0.091  0.179  0.229  0.521  0.471              
## Lght_rnttnS -0.533  0.301  0.180  0.195  0.322  0.221  0.053  0.228       
## RgnL:T_FTLM  0.246  0.183  0.219  0.136 -0.048 -0.774 -0.724 -0.319 -0.087
## RgnL:T_FTLN  0.520 -0.167  0.013 -0.043 -0.217 -0.861 -0.376 -0.700 -0.251
##             RL:T_FTLM
## First_move           
## Trtmnt_bsDr          
## Trtmnt_bsFl          
## Trtmnt_bsSm          
## ReginLxmbrg          
## Trtmnt_FTLM          
## Trtmnt_FTLN          
## Lght_rnttnS          
## RgnL:T_FTLM          
## RgnL:T_FTLN  0.654   
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Region +  Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  (1 | Room) + Region:Treatment_FTL, data = Data_refFTL_Mix))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Region +  
##     Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  
##     (1 | Room) + Region:Treatment_FTL
##    Data: Data_refFTL_Mix
## 
## REML criterion at convergence: 195.2
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.09824 -0.49951 -0.03767  0.42591  2.39093 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 2.033e-02 1.426e-01
##  Site     (Intercept) 0.000e+00 0.000e+00
##  Room     (Intercept) 2.225e-09 4.717e-05
##  Residual             1.446e+00 1.203e+00
## Number of obs: 60, groups:  Mother, 21; Site, 13; Room, 2
## 
## Fixed effects:
##                                       Estimate Std. Error         df t value
## (Intercept)                          2.6445379  0.7306158 46.1457854   3.620
## First_move                           0.0032105  0.0005462 45.3793362   5.878
## Treatment_bisFull                   -0.1547091  0.4459508 46.7048466  -0.347
## Treatment_bisSmart                   0.6239885  0.4936235 46.4771662   1.264
## Treatment_bisMixt_smart             -0.7298630  0.4939461 45.1199213  -1.478
## RegionLuxembourg                     1.6538197  0.6592514 31.1147087   2.509
## Treatment_FTLDay                     1.8187009  0.7098137 38.8390326   2.562
## Treatment_FTLNight                   2.8706306  0.7157426 48.8963349   4.011
## Light_orientationSouth               0.6376142  0.3502739 48.3426426   1.820
## RegionLuxembourg:Treatment_FTLDay   -0.5451193  1.0414989 43.6512789  -0.523
## RegionLuxembourg:Treatment_FTLNight -3.0993742  0.8413615 45.4581734  -3.684
##                                     Pr(>|t|)    
## (Intercept)                         0.000730 ***
## First_move                          4.61e-07 ***
## Treatment_bisFull                   0.730210    
## Treatment_bisSmart                  0.212498    
## Treatment_bisMixt_smart             0.146457    
## RegionLuxembourg                    0.017540 *  
## Treatment_FTLDay                    0.014394 *  
## Treatment_FTLNight                  0.000207 ***
## Light_orientationSouth              0.074902 .  
## RegionLuxembourg:Treatment_FTLDay   0.603344    
## RegionLuxembourg:Treatment_FTLNight 0.000609 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Frst_m Trtm_F Trtm_S Trt_M_ RgnLxm T_FTLD T_FTLN Lght_S
## First_move  -0.693                                                        
## Trtmnt_bsFl -0.403  0.210                                                 
## Trtmnt_bsSm -0.332  0.109  0.537                                          
## Trtmnt_bsM_ -0.199 -0.003  0.544  0.479                                   
## ReginLxmbrg -0.707  0.480 -0.050 -0.127 -0.203                            
## Trtmnt_FTLD -0.495  0.221 -0.050 -0.142 -0.076  0.589                     
## Trtmnt_FTLN -0.731  0.530  0.027 -0.005 -0.162  0.729  0.543              
## Lght_rnttnS -0.378  0.301 -0.003  0.148 -0.180  0.141 -0.053  0.164       
## RgnL:T_FTLD  0.301 -0.183  0.106  0.268  0.219 -0.605 -0.724 -0.414  0.087
## RgnL:T_FTLN  0.581 -0.420  0.064  0.061  0.256 -0.808 -0.460 -0.853 -0.183
##             RL:T_FTLD
## First_move           
## Trtmnt_bsFl          
## Trtmnt_bsSm          
## Trtmnt_bsM_          
## ReginLxmbrg          
## Trtmnt_FTLD          
## Trtmnt_FTLN          
## Lght_rnttnS          
## RgnL:T_FTLD          
## RgnL:T_FTLN  0.481   
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Region +  Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  (1 | Room) + Region:Treatment_FTL, data = Data_refFTL_Night))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Region +  
##     Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  
##     (1 | Room) + Region:Treatment_FTL
##    Data: Data_refFTL_Night
## 
## REML criterion at convergence: 195.2
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.09824 -0.49951 -0.03767  0.42591  2.39093 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 2.033e-02 1.426e-01
##  Site     (Intercept) 0.000e+00 0.000e+00
##  Room     (Intercept) 2.225e-09 4.717e-05
##  Residual             1.446e+00 1.203e+00
## Number of obs: 60, groups:  Mother, 21; Site, 13; Room, 2
## 
## Fixed effects:
##                                     Estimate Std. Error         df t value
## (Intercept)                        5.5151685  0.5302735 48.9892980  10.401
## First_move                         0.0032105  0.0005462 45.3793363   5.878
## Treatment_bisFull                 -0.1547091  0.4459508 46.7048466  -0.347
## Treatment_bisSmart                 0.6239885  0.4936235 46.4771665   1.264
## Treatment_bisMixt_smart           -0.7298630  0.4939461 45.1199234  -1.478
## RegionLuxembourg                  -1.4455545  0.4958897 34.5349139  -2.915
## Treatment_FTLDay                  -1.0519296  0.6814252 41.2126321  -1.544
## Treatment_FTLMix                  -2.8706306  0.7157426 48.8963349  -4.011
## Light_orientationSouth             0.6376142  0.3502739 48.3426426   1.820
## RegionLuxembourg:Treatment_FTLDay  2.5542549  0.9748974 46.2340993   2.620
## RegionLuxembourg:Treatment_FTLMix  3.0993742  0.8413615 45.4581735   3.684
##                                   Pr(>|t|)    
## (Intercept)                       5.39e-14 ***
## First_move                        4.61e-07 ***
## Treatment_bisFull                 0.730210    
## Treatment_bisSmart                0.212498    
## Treatment_bisMixt_smart           0.146457    
## RegionLuxembourg                  0.006204 ** 
## Treatment_FTLDay                  0.130301    
## Treatment_FTLMix                  0.000207 ***
## Light_orientationSouth            0.074902 .  
## RegionLuxembourg:Treatment_FTLDay 0.011856 *  
## RegionLuxembourg:Treatment_FTLMix 0.000609 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Frst_m Trtm_F Trtm_S Trt_M_ RgnLxm T_FTLD T_FTLM Lght_S
## First_move  -0.240                                                        
## Trtmnt_bsFl -0.519  0.210                                                 
## Trtmnt_bsSm -0.464  0.109  0.537                                          
## Trtmnt_bsM_ -0.493 -0.003  0.544  0.479                                   
## ReginLxmbrg -0.581 -0.075  0.041 -0.066  0.165                            
## Trtmnt_FTLD -0.307 -0.326 -0.080 -0.143  0.091  0.505                     
## Trtmnt_FTLM -0.342 -0.530 -0.027  0.005  0.162  0.478  0.485              
## Lght_rnttnS -0.299  0.301 -0.003  0.148 -0.180 -0.124 -0.228 -0.164       
## RgnL:T_FTLD  0.148  0.167  0.058  0.234  0.013 -0.526 -0.700 -0.293  0.251
## RgnL:T_FTLM  0.350  0.420 -0.064 -0.061 -0.256 -0.622 -0.416 -0.853  0.183
##             RL:T_FTLD
## First_move           
## Trtmnt_bsFl          
## Trtmnt_bsSm          
## Trtmnt_bsM_          
## ReginLxmbrg          
## Trtmnt_FTLD          
## Trtmnt_FTLM          
## Lght_rnttnS          
## RgnL:T_FTLD          
## RgnL:T_FTLM  0.350   
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
test1 <- data.frame(Reference_Treatment = "Dark", Reference_Timing = "Day", as.data.frame(( summary(lmer(log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Region +  Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  (1 | Room) + Region:Treatment_FTL, data = Data))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test2 <- data.frame(Reference_Treatment = "Smart", Reference_Timing = "Day", as.data.frame(( summary(lmer(log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Region +  Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  (1 | Room) + Region:Treatment_FTL, data = Data_ref_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test3 <- data.frame(Reference_Treatment = "Full", Reference_Timing = "Day", as.data.frame(( summary(lmer(log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Region +  Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  (1 | Room) + Region:Treatment_FTL, data = Data_ref_full))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test4 <- data.frame(Reference_Treatment = "Mixt_smart", Reference_Timing = "Day", as.data.frame(( summary(lmer(log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Region +  Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  (1 | Room) + Region:Treatment_FTL, data = Data_ref_mixt_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test5 <- data.frame(Reference_Treatment = "Dark", Reference_Timing = "Mixt", as.data.frame(( summary(lmer(log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Region +  Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  (1 | Room) + Region:Treatment_FTL, data = Data_refFTL_Mix))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test6 <- data.frame(Reference_Treatment = "Dark", Reference_Timing = "Night", as.data.frame(( summary(lmer(log(Flight_to_light + 0.1) ~ First_move + Treatment_bis + Region +  Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) +  (1 | Room) + Region:Treatment_FTL, data = Data_refFTL_Night))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
Results_FTL_by_first_move <- rbind(test1,test2,test3,test4,test5,test6)

colnames(Results_FTL_by_first_move ) <- c("Reference_Treatment", "Reference_Timing" ,"Estimate", "Std. Error", "df", "t.value", "Pr(>|z|)")

write.csv2( Results_FTL_by_first_move , file = "output/Results_FTL_by_first_move.csv" )

kable(Results_FTL_by_first_move , caption = " Temps mis pour voler à la lumière en fonction du temps mis pour bouger ", padding = 1 )
Temps mis pour voler à la lumière en fonction du temps mis pour bouger
Reference_Treatment Reference_Timing Estimate Std. Error df t.value Pr(>|z|)
(Intercept) Dark Day 4.4632389 0.7238143 42.59248 6.1662762 0.0000002
First_move Dark Day 0.0032105 0.0005462 45.37934 5.8779665 0.0000005
Treatment_bisFull Dark Day -0.1547091 0.4459508 46.70485 -0.3469197 0.7302100
Treatment_bisSmart Dark Day 0.6239885 0.4936235 46.47717 1.2640982 0.2124979
Treatment_bisMixt_smart Dark Day -0.7298630 0.4939461 45.11992 -1.4776167 0.1464573
RegionLuxembourg Dark Day 1.1087004 0.8295758 38.57466 1.3364667 0.1892269
Treatment_FTLMix Dark Day -1.8187009 0.7098137 38.83903 -2.5622229 0.0143944
Treatment_FTLNight Dark Day 1.0519296 0.6814252 41.21263 1.5437198 0.1303010
Light_orientationSouth Dark Day 0.6376142 0.3502739 48.34264 1.8203302 0.0749023
RegionLuxembourg:Treatment_FTLMix Dark Day 0.5451193 1.0414989 43.65128 0.5233988 0.6033439
RegionLuxembourg:Treatment_FTLNight Dark Day -2.5542549 0.9748974 46.23410 -2.6200243 0.0118558
(Intercept)1 Smart Day 5.0872274 0.6543759 40.91900 7.7741670 0.0000000
First_move1 Smart Day 0.0032105 0.0005462 45.37934 5.8779665 0.0000005
Treatment_bisDark Smart Day -0.6239885 0.4936235 46.47717 -1.2640982 0.2124979
Treatment_bisFull1 Smart Day -0.7786976 0.4537666 46.90764 -1.7160752 0.0927467
Treatment_bisMixt_smart1 Smart Day -1.3538516 0.5040639 48.65120 -2.6858729 0.0098672
RegionLuxembourg1 Smart Day 1.1087004 0.8295758 38.57466 1.3364667 0.1892269
Treatment_FTLMix1 Smart Day -1.8187009 0.7098137 38.83903 -2.5622229 0.0143944
Treatment_FTLNight1 Smart Day 1.0519296 0.6814252 41.21263 1.5437198 0.1303010
Light_orientationSouth1 Smart Day 0.6376142 0.3502739 48.34264 1.8203302 0.0749023
RegionLuxembourg:Treatment_FTLMix1 Smart Day 0.5451193 1.0414989 43.65128 0.5233988 0.6033439
RegionLuxembourg:Treatment_FTLNight1 Smart Day -2.5542549 0.9748974 46.23410 -2.6200243 0.0118558
(Intercept)2 Full Day 4.3085298 0.6545656 41.18461 6.5822733 0.0000001
First_move2 Full Day 0.0032105 0.0005462 45.37934 5.8779665 0.0000005
Treatment_bisDark1 Full Day 0.1547091 0.4459508 46.70485 0.3469197 0.7302100
Treatment_bisSmart1 Full Day 0.7786976 0.4537666 46.90764 1.7160752 0.0927467
Treatment_bisMixt_smart2 Full Day -0.5751539 0.4506316 48.83229 -1.2763285 0.2078764
RegionLuxembourg2 Full Day 1.1087004 0.8295758 38.57466 1.3364667 0.1892269
Treatment_FTLMix2 Full Day -1.8187009 0.7098137 38.83903 -2.5622229 0.0143944
Treatment_FTLNight2 Full Day 1.0519296 0.6814252 41.21263 1.5437198 0.1303010
Light_orientationSouth2 Full Day 0.6376142 0.3502739 48.34264 1.8203302 0.0749023
RegionLuxembourg:Treatment_FTLMix2 Full Day 0.5451193 1.0414989 43.65128 0.5233988 0.6033439
RegionLuxembourg:Treatment_FTLNight2 Full Day -2.5542549 0.9748974 46.23410 -2.6200243 0.0118558
(Intercept)3 Mixt_smart Day 3.7333758 0.7555112 43.41463 4.9415226 0.0000120
First_move3 Mixt_smart Day 0.0032105 0.0005462 45.37934 5.8779665 0.0000005
Treatment_bisDark2 Mixt_smart Day 0.7298630 0.4939461 45.11992 1.4776167 0.1464573
Treatment_bisFull2 Mixt_smart Day 0.5751539 0.4506316 48.83229 1.2763285 0.2078764
Treatment_bisSmart2 Mixt_smart Day 1.3538516 0.5040639 48.65121 2.6858729 0.0098672
RegionLuxembourg3 Mixt_smart Day 1.1087004 0.8295758 38.57466 1.3364667 0.1892269
Treatment_FTLMix3 Mixt_smart Day -1.8187009 0.7098137 38.83903 -2.5622229 0.0143944
Treatment_FTLNight3 Mixt_smart Day 1.0519296 0.6814252 41.21263 1.5437198 0.1303010
Light_orientationSouth3 Mixt_smart Day 0.6376142 0.3502739 48.34264 1.8203302 0.0749023
RegionLuxembourg:Treatment_FTLMix3 Mixt_smart Day 0.5451193 1.0414989 43.65128 0.5233988 0.6033439
RegionLuxembourg:Treatment_FTLNight3 Mixt_smart Day -2.5542549 0.9748974 46.23410 -2.6200243 0.0118558
(Intercept)4 Dark Mixt 2.6445379 0.7306158 46.14579 3.6196014 0.0007302
First_move4 Dark Mixt 0.0032105 0.0005462 45.37934 5.8779665 0.0000005
Treatment_bisFull3 Dark Mixt -0.1547091 0.4459508 46.70485 -0.3469197 0.7302100
Treatment_bisSmart3 Dark Mixt 0.6239885 0.4936235 46.47717 1.2640982 0.2124979
Treatment_bisMixt_smart3 Dark Mixt -0.7298630 0.4939461 45.11992 -1.4776167 0.1464573
RegionLuxembourg4 Dark Mixt 1.6538197 0.6592514 31.11471 2.5086327 0.0175405
Treatment_FTLDay Dark Mixt 1.8187009 0.7098137 38.83903 2.5622229 0.0143944
Treatment_FTLNight4 Dark Mixt 2.8706306 0.7157426 48.89633 4.0107022 0.0002068
Light_orientationSouth4 Dark Mixt 0.6376142 0.3502739 48.34264 1.8203302 0.0749023
RegionLuxembourg:Treatment_FTLDay Dark Mixt -0.5451193 1.0414989 43.65128 -0.5233988 0.6033439
RegionLuxembourg:Treatment_FTLNight4 Dark Mixt -3.0993742 0.8413615 45.45817 -3.6837602 0.0006092
(Intercept)5 Dark Night 5.5151685 0.5302735 48.98930 10.4006102 0.0000000
First_move5 Dark Night 0.0032105 0.0005462 45.37934 5.8779665 0.0000005
Treatment_bisFull4 Dark Night -0.1547091 0.4459508 46.70485 -0.3469197 0.7302100
Treatment_bisSmart4 Dark Night 0.6239885 0.4936235 46.47717 1.2640982 0.2124979
Treatment_bisMixt_smart4 Dark Night -0.7298630 0.4939461 45.11992 -1.4776167 0.1464573
RegionLuxembourg5 Dark Night -1.4455545 0.4958897 34.53491 -2.9150728 0.0062041
Treatment_FTLDay1 Dark Night -1.0519296 0.6814252 41.21263 -1.5437198 0.1303010
Treatment_FTLMix4 Dark Night -2.8706306 0.7157426 48.89633 -4.0107022 0.0002068
Light_orientationSouth5 Dark Night 0.6376142 0.3502739 48.34264 1.8203302 0.0749023
RegionLuxembourg:Treatment_FTLDay1 Dark Night 2.5542549 0.9748974 46.23410 2.6200243 0.0118558
RegionLuxembourg:Treatment_FTLMix4 Dark Night 3.0993742 0.8413615 45.45817 3.6837602 0.0006092
Info_Flight_to_light_by_First_move <- "
En moyenne, au plus un individu a bougé rapidement, au plus il volera à la lampe rapidement.
Les individus expérimentés de jours avec 30 min à l'obscurité mettent significativement moins de temps pour atteindre la lampe par rapport aux individus testés à d'autres timing.
Les individus expérimentés de jours avec 30 min à l'obscurité descendant d'une mère provenant du luxembourg  mettent significativement plus de temps pour atteindre la lampe par rapport aux mêmes individus descendants d'une mère provenant du Brabant.
Les individus mettent quasiement significativement (p-val = 0.0749) plus de temps pour aller à la lampe quand elle est au Sud.
Les individus descendant d'une mère provenant de la région luxembourgeoise et expérimentés la nuit mettent significativement moins de temps pour voler à la lumière.
Les individus du traitement Mixt-smart mettent significativement moins de temps pour voler à la lampe que les individus du traitement Smart.
"

5.7.5 Visualisation

ggplot(data = Data, aes(x = log(First_move), y = log(Flight_to_light+0.1))) +
  geom_smooth(method = "lm", aes(color = Treatment_FTL), se = T, alpha = 0.2) +
  geom_point(aes(color = Treatment_FTL, shape = Treatment_bis), alpha = 0.75) +
  labs(title = "Temps pour voler à la lumière en fonction du temps pour faire le premier mouvement", x = "log(Temps pour le premier mouvement (s))", y = "log(Temps pour voler à la lumière (s))", color = "Timing", shape = "Traitement") +
  theme_bw() +
  theme(title=element_text(size=10))
## `geom_smooth()` using formula = 'y ~ x'
## Warning: Removed 400 rows containing non-finite values (`stat_smooth()`).
## Warning: Removed 390 rows containing missing values (`geom_point()`).

5.8 STL_by_First_move

5.8.1 Test

LM_Speed_to_light_by_First_move <- lmer(log(Speed_to_light+0.000001) ~ First_move + Treatment_bis + Sex  + Region + Treatment_FTL + Light_orientation + (1|Mother) + (1|Site) + (1|Room) , data = Data)
## boundary (singular) fit: see help('isSingular')
summary(LM_Speed_to_light_by_First_move)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Speed_to_light + 1e-06) ~ First_move + Treatment_bis + Sex +  
##     Region + Treatment_FTL + Light_orientation + (1 | Mother) +  
##     (1 | Site) + (1 | Room)
##    Data: Data
## 
## REML criterion at convergence: 692.3
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.01775 -0.65717 -0.07406  0.63276  2.20497 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 2.699e+00 1.642765
##  Site     (Intercept) 3.247e+00 1.802035
##  Room     (Intercept) 1.417e-08 0.000119
##  Residual             3.416e+01 5.844406
## Number of obs: 110, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                           Estimate Std. Error         df t value Pr(>|t|)    
## (Intercept)             -13.417097   2.121696  24.497447  -6.324 1.41e-06 ***
## First_move                0.001244   0.001761  92.275774   0.707  0.48154    
## Treatment_bisFull         2.734727   1.519617  93.663025   1.800  0.07514 .  
## Treatment_bisSmart        1.013157   1.714339  91.897979   0.591  0.55598    
## Treatment_bisMixt_smart   2.550798   1.644914  92.078674   1.551  0.12440    
## SexMale                  -0.103134   1.186712  90.551400  -0.087  0.93094    
## RegionLuxembourg          3.268222   1.840014   7.449481   1.776  0.11638    
## Treatment_FTLMix          4.799654   1.679418  86.731824   2.858  0.00534 ** 
## Treatment_FTLNight        7.109570   1.639176  87.379616   4.337 3.85e-05 ***
## Light_orientationSouth   -0.095795   1.176134  90.392439  -0.081  0.93527    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Frst_m Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_FTLM T_FTLN
## First_move  -0.471                                                        
## Trtmnt_bsFl -0.415  0.123                                                 
## Trtmnt_bsSm -0.321  0.055  0.440                                          
## Trtmnt_bsM_ -0.302 -0.001  0.466  0.381                                   
## SexMale     -0.286  0.052  0.003  0.114  0.066                            
## ReginLxmbrg -0.425  0.163  0.031 -0.093  0.010  0.033                     
## Trtmnt_FTLM -0.335  0.123  0.080  0.015 -0.006 -0.108 -0.220              
## Trtmnt_FTLN -0.411  0.310  0.051 -0.029 -0.020 -0.029 -0.111  0.597       
## Lght_rnttnS -0.280  0.068 -0.087  0.021 -0.122  0.024  0.080 -0.005 -0.076
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
qqnorm(resid(LM_Speed_to_light_by_First_move))
qqline(resid(LM_Speed_to_light_by_First_move))

Homogénité des variances

plot(LM_Speed_to_light_by_First_move)

Distance de cook

plot(cooks.distance(LM_Speed_to_light_by_First_move))

5.8.2 Simplification du modèle

On est partit d’un modèle avec aucune interaction aussi non le modèle devient trop complexe pour très peu d’échantillons.

5.8.3 Treatment VS Treatment_bis

AIC(lmer(log(Speed_to_light+0.000001) ~ First_move + Treatment_bis + Sex  + Region + Treatment_FTL + Light_orientation + (1|Mother) + (1|Site) + (1|Room) , data = Data))
## boundary (singular) fit: see help('isSingular')
## [1] 720.311
AIC(lmer(log(Speed_to_light+0.000001) ~ First_move + Treatment + Sex  + Region + Treatment_FTL + Light_orientation + (1|Mother) + (1|Site) + (1|Room) , data = Data))
## [1] 722.0312
summary(lmer(log(Speed_to_light+0.000001) ~ First_move + Treatment_bis + Sex  + Region + Treatment_FTL + Light_orientation + (1|Mother) + (1|Site) + (1|Room) , data = Data))$coeff
## boundary (singular) fit: see help('isSingular')
##                              Estimate  Std. Error        df     t value
## (Intercept)             -13.417096726 2.121696335 24.497447 -6.32375920
## First_move                0.001244351 0.001760816 92.275774  0.70669030
## Treatment_bisFull         2.734727118 1.519616597 93.663025  1.79961651
## Treatment_bisSmart        1.013156765 1.714338533 91.897979  0.59098990
## Treatment_bisMixt_smart   2.550798172 1.644914251 92.078674  1.55071802
## SexMale                  -0.103134245 1.186712445 90.551400 -0.08690753
## RegionLuxembourg          3.268222256 1.840014001  7.449481  1.77619423
## Treatment_FTLMix          4.799653803 1.679418069 86.731824  2.85792674
## Treatment_FTLNight        7.109570363 1.639176355 87.379616  4.33728216
## Light_orientationSouth   -0.095794730 1.176133673 90.392439 -0.08144885
##                             Pr(>|t|)
## (Intercept)             1.407205e-06
## First_move              4.815397e-01
## Treatment_bisFull       7.514111e-02
## Treatment_bisSmart      5.559780e-01
## Treatment_bisMixt_smart 1.243997e-01
## SexMale                 9.309369e-01
## RegionLuxembourg        1.163774e-01
## Treatment_FTLMix        5.338094e-03
## Treatment_FTLNight      3.854067e-05
## Light_orientationSouth  9.352651e-01
summary(lmer(log(Speed_to_light+0.000001) ~ First_move + Treatment + Sex  + Region + Treatment_FTL + Light_orientation + (1|Mother) + (1|Site) + (1|Room) , data = Data))$coeff
##                            Estimate  Std. Error        df     t value
## (Intercept)            -13.47489204 2.133917682 25.129126 -6.31462598
## First_move               0.00131445 0.001748786 90.568592  0.75163586
## TreatmentFull            2.71170413 1.511502559 92.967695  1.79404535
## TreatmentSmart           1.79995243 1.387836559 91.122242  1.29694842
## SexMale                 -0.04639529 1.178675286 89.954337 -0.03936223
## RegionLuxembourg         3.21183656 1.830479874  7.403374  1.75464183
## Treatment_FTLMix         4.74954675 1.676179370 84.364983  2.83355519
## Treatment_FTLNight       7.00209744 1.632484787 83.439941  4.28922677
## Light_orientationSouth   0.06541316 1.159801323 88.959284  0.05640032
##                            Pr(>|t|)
## (Intercept)            1.282046e-06
## First_move             4.542189e-01
## TreatmentFull          7.605671e-02
## TreatmentSmart         1.979233e-01
## SexMale                9.686888e-01
## RegionLuxembourg       1.204269e-01
## Treatment_FTLMix       5.757649e-03
## Treatment_FTLNight     4.794276e-05
## Light_orientationSouth 9.551494e-01

Il serait légèrement préférable de continuer avec Treatment_bis

5.8.4 Résultats

Analyse des p-val

summary(lmer(log(Speed_to_light+0.000001) ~ First_move +Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room), data = Data))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Speed_to_light + 1e-06) ~ First_move + Treatment_bis + Sex +  
##     Region + Treatment_FTL + Light_orientation + (1 | Mother) +  
##     (1 | Site) + (1 | Room)
##    Data: Data
## 
## REML criterion at convergence: 692.3
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.01775 -0.65717 -0.07406  0.63276  2.20497 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 2.699e+00 1.642765
##  Site     (Intercept) 3.247e+00 1.802035
##  Room     (Intercept) 1.417e-08 0.000119
##  Residual             3.416e+01 5.844406
## Number of obs: 110, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                           Estimate Std. Error         df t value Pr(>|t|)    
## (Intercept)             -13.417097   2.121696  24.497447  -6.324 1.41e-06 ***
## First_move                0.001244   0.001761  92.275774   0.707  0.48154    
## Treatment_bisFull         2.734727   1.519617  93.663025   1.800  0.07514 .  
## Treatment_bisSmart        1.013157   1.714339  91.897979   0.591  0.55598    
## Treatment_bisMixt_smart   2.550798   1.644914  92.078674   1.551  0.12440    
## SexMale                  -0.103134   1.186712  90.551400  -0.087  0.93094    
## RegionLuxembourg          3.268222   1.840014   7.449481   1.776  0.11638    
## Treatment_FTLMix          4.799654   1.679418  86.731824   2.858  0.00534 ** 
## Treatment_FTLNight        7.109570   1.639176  87.379616   4.337 3.85e-05 ***
## Light_orientationSouth   -0.095795   1.176134  90.392439  -0.081  0.93527    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Frst_m Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_FTLM T_FTLN
## First_move  -0.471                                                        
## Trtmnt_bsFl -0.415  0.123                                                 
## Trtmnt_bsSm -0.321  0.055  0.440                                          
## Trtmnt_bsM_ -0.302 -0.001  0.466  0.381                                   
## SexMale     -0.286  0.052  0.003  0.114  0.066                            
## ReginLxmbrg -0.425  0.163  0.031 -0.093  0.010  0.033                     
## Trtmnt_FTLM -0.335  0.123  0.080  0.015 -0.006 -0.108 -0.220              
## Trtmnt_FTLN -0.411  0.310  0.051 -0.029 -0.020 -0.029 -0.111  0.597       
## Lght_rnttnS -0.280  0.068 -0.087  0.021 -0.122  0.024  0.080 -0.005 -0.076
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Speed_to_light+0.000001) ~ First_move +Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) , data = Data_ref_full))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Speed_to_light + 1e-06) ~ First_move + Treatment_bis + Sex +  
##     Region + Treatment_FTL + Light_orientation + (1 | Mother) +  
##     (1 | Site) + (1 | Room)
##    Data: Data_ref_full
## 
## REML criterion at convergence: 692.3
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.01775 -0.65717 -0.07406  0.63276  2.20497 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 2.699e+00 1.642765
##  Site     (Intercept) 3.247e+00 1.802035
##  Room     (Intercept) 1.417e-08 0.000119
##  Residual             3.416e+01 5.844406
## Number of obs: 110, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                           Estimate Std. Error         df t value Pr(>|t|)    
## (Intercept)             -10.682370   2.033615  26.782549  -5.253 1.58e-05 ***
## First_move                0.001244   0.001761  92.275774   0.707  0.48154    
## Treatment_bisDark        -2.734727   1.519617  93.663024  -1.800  0.07514 .  
## Treatment_bisSmart       -1.721570   1.719342  92.071638  -1.001  0.31931    
## Treatment_bisMixt_smart  -0.183929   1.638545  87.263545  -0.112  0.91088    
## SexMale                  -0.103134   1.186712  90.551400  -0.087  0.93094    
## RegionLuxembourg          3.268222   1.840014   7.449481   1.776  0.11638    
## Treatment_FTLMix          4.799654   1.679418  86.731824   2.858  0.00534 ** 
## Treatment_FTLNight        7.109570   1.639176  87.379616   4.337 3.85e-05 ***
## Light_orientationSouth   -0.095795   1.176134  90.392439  -0.081  0.93527    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Frst_m Trtm_D Trtm_S Trt_M_ SexMal RgnLxm T_FTLM T_FTLN
## First_move  -0.400                                                        
## Trtmnt_bsDr -0.314 -0.123                                                 
## Trtmnt_bsSm -0.285 -0.053  0.445                                          
## Trtmnt_bsM_ -0.258 -0.114  0.460  0.380                                   
## SexMale     -0.296  0.052 -0.003  0.111  0.064                            
## ReginLxmbrg -0.420  0.163 -0.031 -0.121 -0.019  0.033                     
## Trtmnt_FTLM -0.290  0.123 -0.080 -0.056 -0.081 -0.108 -0.220              
## Trtmnt_FTLN -0.391  0.310 -0.051 -0.074 -0.067 -0.029 -0.111  0.597       
## Lght_rnttnS -0.357  0.068  0.087  0.098 -0.043  0.024  0.080 -0.005 -0.076
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Speed_to_light+0.000001) ~ First_move +Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) , data = Data_ref_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Speed_to_light + 1e-06) ~ First_move + Treatment_bis + Sex +  
##     Region + Treatment_FTL + Light_orientation + (1 | Mother) +  
##     (1 | Site) + (1 | Room)
##    Data: Data_ref_smart
## 
## REML criterion at convergence: 692.3
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.01775 -0.65717 -0.07406  0.63276  2.20497 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 2.699e+00 1.642765
##  Site     (Intercept) 3.247e+00 1.802035
##  Room     (Intercept) 1.417e-08 0.000119
##  Residual             3.416e+01 5.844406
## Number of obs: 110, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                           Estimate Std. Error         df t value Pr(>|t|)    
## (Intercept)             -12.403940   2.258758  32.509707  -5.491 4.53e-06 ***
## First_move                0.001244   0.001761  92.275774   0.707  0.48154    
## Treatment_bisDark        -1.013157   1.714339  91.897979  -0.591  0.55598    
## Treatment_bisFull         1.721570   1.719342  92.071639   1.001  0.31931    
## Treatment_bisMixt_smart   1.537641   1.870205  94.894187   0.822  0.41304    
## SexMale                  -0.103134   1.186712  90.551400  -0.087  0.93094    
## RegionLuxembourg          3.268222   1.840014   7.449481   1.776  0.11638    
## Treatment_FTLMix          4.799654   1.679418  86.731824   2.858  0.00534 ** 
## Treatment_FTLNight        7.109570   1.639176  87.379616   4.337 3.85e-05 ***
## Light_orientationSouth   -0.095795   1.176134  90.392439  -0.081  0.93527    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Frst_m Trtm_D Trtm_F Trt_M_ SexMal RgnLxm T_FTLM T_FTLN
## First_move  -0.400                                                        
## Trtmnt_bsDr -0.457 -0.055                                                 
## Trtmnt_bsFl -0.505  0.053  0.608                                          
## Trtmnt_bsM_ -0.414 -0.051  0.582  0.586                                   
## SexMale     -0.182  0.052 -0.114 -0.111 -0.046                            
## ReginLxmbrg -0.470  0.163  0.093  0.121  0.094  0.033                     
## Trtmnt_FTLM -0.303  0.123 -0.015  0.056 -0.019 -0.108 -0.220              
## Trtmnt_FTLN -0.408  0.310  0.029  0.074  0.009 -0.029 -0.111  0.597       
## Lght_rnttnS -0.247  0.068 -0.021 -0.098 -0.127  0.024  0.080 -0.005 -0.076
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Speed_to_light+0.000001) ~ First_move +Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) , data = Data_ref_mixt_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Speed_to_light + 1e-06) ~ First_move + Treatment_bis + Sex +  
##     Region + Treatment_FTL + Light_orientation + (1 | Mother) +  
##     (1 | Site) + (1 | Room)
##    Data: Data_ref_mixt_smart
## 
## REML criterion at convergence: 692.3
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.01775 -0.65717 -0.07406  0.63276  2.20497 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 2.699e+00 1.642765
##  Site     (Intercept) 3.247e+00 1.802035
##  Room     (Intercept) 1.417e-08 0.000119
##  Residual             3.416e+01 5.844406
## Number of obs: 110, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                          Estimate Std. Error         df t value Pr(>|t|)    
## (Intercept)            -10.866299   2.258045  36.101393  -4.812 2.65e-05 ***
## First_move               0.001244   0.001761  92.275774   0.707  0.48154    
## Treatment_bisDark       -2.550798   1.644914  92.078677  -1.551  0.12440    
## Treatment_bisFull        0.183929   1.638545  87.263551   0.112  0.91088    
## Treatment_bisSmart      -1.537641   1.870205  94.894206  -0.822  0.41304    
## SexMale                 -0.103134   1.186712  90.551400  -0.087  0.93094    
## RegionLuxembourg         3.268222   1.840014   7.449481   1.776  0.11638    
## Treatment_FTLMix         4.799654   1.679418  86.731824   2.858  0.00534 ** 
## Treatment_FTLNight       7.109570   1.639176  87.379616   4.337 3.85e-05 ***
## Light_orientationSouth  -0.095795   1.176134  90.392439  -0.081  0.93527    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Frst_m Trtm_D Trtm_F Trtm_S SexMal RgnLxm T_FTLM T_FTLN
## First_move  -0.443                                                        
## Trtmnt_bsDr -0.445  0.001                                                 
## Trtmnt_bsFl -0.493  0.114  0.572                                          
## Trtmnt_bsSm -0.414  0.051  0.531  0.526                                   
## SexMale     -0.221  0.052 -0.066 -0.064  0.046                            
## ReginLxmbrg -0.392  0.163 -0.010  0.019 -0.094  0.033                     
## Trtmnt_FTLM -0.319  0.123  0.006  0.081  0.019 -0.108 -0.220              
## Trtmnt_FTLN -0.401  0.310  0.020  0.067 -0.009 -0.029 -0.111  0.597       
## Lght_rnttnS -0.352  0.068  0.122  0.043  0.127  0.024  0.080 -0.005 -0.076
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Speed_to_light+0.000001) ~ First_move +Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) , data = Data_refFTL_Night))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Speed_to_light + 1e-06) ~ First_move + Treatment_bis + Sex +  
##     Region + Treatment_FTL + Light_orientation + (1 | Mother) +  
##     (1 | Site) + (1 | Room)
##    Data: Data_refFTL_Night
## 
## REML criterion at convergence: 692.3
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.01775 -0.65717 -0.07406  0.63276  2.20497 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 2.699e+00 1.642765
##  Site     (Intercept) 3.247e+00 1.802035
##  Room     (Intercept) 1.417e-08 0.000119
##  Residual             3.416e+01 5.844406
## Number of obs: 110, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                          Estimate Std. Error        df t value Pr(>|t|)    
## (Intercept)             -6.307526   2.080642 21.030478  -3.032  0.00634 ** 
## First_move               0.001244   0.001761 92.275774   0.707  0.48154    
## Treatment_bisFull        2.734727   1.519617 93.663025   1.800  0.07514 .  
## Treatment_bisSmart       1.013157   1.714339 91.897978   0.591  0.55598    
## Treatment_bisMixt_smart  2.550798   1.644914 92.078671   1.551  0.12440    
## SexMale                 -0.103134   1.186712 90.551400  -0.087  0.93094    
## RegionLuxembourg         3.268222   1.840014  7.449481   1.776  0.11638    
## Treatment_FTLDay        -7.109570   1.639176 87.379615  -4.337 3.85e-05 ***
## Treatment_FTLMix        -2.309917   1.489258 93.918429  -1.551  0.12425    
## Light_orientationSouth  -0.095795   1.176134 90.392439  -0.081  0.93527    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Frst_m Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_FTLD T_FTLM
## First_move  -0.236                                                        
## Trtmnt_bsFl -0.383  0.123                                                 
## Trtmnt_bsSm -0.351  0.055  0.440                                          
## Trtmnt_bsM_ -0.324 -0.001  0.466  0.381                                   
## SexMale     -0.315  0.052  0.003  0.114  0.066                            
## ReginLxmbrg -0.521  0.163  0.031 -0.093  0.010  0.033                     
## Trtmnt_FTLD -0.369 -0.310 -0.051  0.029  0.020  0.029  0.111              
## Trtmnt_FTLM -0.260 -0.202  0.035  0.049  0.015 -0.090 -0.125  0.427       
## Lght_rnttnS -0.346  0.068 -0.087  0.021 -0.122  0.024  0.080  0.076  0.078
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Speed_to_light+0.000001) ~ First_move +Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) , data = Data_refFTL_Mix))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Speed_to_light + 1e-06) ~ First_move + Treatment_bis + Sex +  
##     Region + Treatment_FTL + Light_orientation + (1 | Mother) +  
##     (1 | Site) + (1 | Room)
##    Data: Data_refFTL_Mix
## 
## REML criterion at convergence: 692.3
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.01775 -0.65717 -0.07406  0.63276  2.20497 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 2.699e+00 1.642765
##  Site     (Intercept) 3.247e+00 1.802035
##  Room     (Intercept) 1.417e-08 0.000119
##  Residual             3.416e+01 5.844406
## Number of obs: 110, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                          Estimate Std. Error        df t value Pr(>|t|)    
## (Intercept)             -8.617443   2.221448 24.591749  -3.879 0.000691 ***
## First_move               0.001244   0.001761 92.275774   0.707 0.481540    
## Treatment_bisFull        2.734727   1.519617 93.663024   1.800 0.075141 .  
## Treatment_bisSmart       1.013157   1.714339 91.897978   0.591 0.555978    
## Treatment_bisMixt_smart  2.550798   1.644914 92.078671   1.551 0.124400    
## SexMale                 -0.103134   1.186712 90.551400  -0.087 0.930937    
## RegionLuxembourg         3.268222   1.840014  7.449481   1.776 0.116377    
## Treatment_FTLDay        -4.799654   1.679418 86.731824  -2.858 0.005338 ** 
## Treatment_FTLNight       2.309917   1.489258 93.918429   1.551 0.124253    
## Light_orientationSouth  -0.095795   1.176134 90.392439  -0.081 0.935265    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Frst_m Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_FTLD T_FTLN
## First_move  -0.357                                                        
## Trtmnt_bsFl -0.336  0.123                                                 
## Trtmnt_bsSm -0.296  0.055  0.440                                          
## Trtmnt_bsM_ -0.293 -0.001  0.466  0.381                                   
## SexMale     -0.355  0.052  0.003  0.114  0.066                            
## ReginLxmbrg -0.572  0.163  0.031 -0.093  0.010  0.033                     
## Trtmnt_FTLD -0.436 -0.123 -0.080 -0.015  0.006  0.108  0.220              
## Trtmnt_FTLN -0.427  0.202 -0.035 -0.049 -0.015  0.090  0.125  0.470       
## Lght_rnttnS -0.271  0.068 -0.087  0.021 -0.122  0.024  0.080  0.005 -0.078
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
test1 <- data.frame(Reference_Treatment = "Dark", Reference_Timing = "Day", as.data.frame(( summary(lmer(log(Speed_to_light+0.000001) ~ First_move +Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room), data = Data))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test2 <- data.frame(Reference_Treatment = "Smart", Reference_Timing = "Day", as.data.frame(( summary(lmer(log(Speed_to_light+0.000001) ~ First_move +Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) , data = Data_ref_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test3 <- data.frame(Reference_Treatment = "Full", Reference_Timing = "Day", as.data.frame(( summary(lmer(log(Speed_to_light+0.000001) ~ First_move +Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) , data = Data_ref_full))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test4 <- data.frame(Reference_Treatment = "Mixt_smart", Reference_Timing = "Day", as.data.frame(( summary(lmer(log(Speed_to_light+0.000001) ~ First_move +Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) , data = Data_ref_mixt_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test5 <- data.frame(Reference_Treatment = "Dark", Reference_Timing = "Mixt", as.data.frame(( summary(lmer(log(Speed_to_light+0.000001) ~ First_move +Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) , data = Data_refFTL_Mix))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test6 <- data.frame(Reference_Treatment = "Dark", Reference_Timing = "Night", as.data.frame(( summary(lmer(log(Speed_to_light+0.000001) ~ First_move +Treatment_bis + Sex + Region + Treatment_FTL + Light_orientation + (1 | Mother) + (1 | Site) + (1 | Room) , data = Data_refFTL_Night))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
Results_SPL_by_first_move <- rbind(test1,test2,test3,test4,test5,test6)

colnames(Results_SPL_by_first_move ) <- c("Reference_Treatment", "Reference_Timing" ,"Estimate", "Std. Error", "df", "t.value", "Pr(>|z|)")

write.csv2( Results_SPL_by_first_move , file = "output/Results_SPL_by_first_move.csv" )

kable(Results_SPL_by_first_move , caption = "Vitesse pour voler à la lumière en fonction du temps mis pour bouger", padding = 1 )
Vitesse pour voler à la lumière en fonction du temps mis pour bouger
Reference_Treatment Reference_Timing Estimate Std. Error df t.value Pr(>|z|)
(Intercept) Dark Day -13.4170967 2.1216963 24.497447 -6.3237592 0.0000014
First_move Dark Day 0.0012444 0.0017608 92.275774 0.7066903 0.4815397
Treatment_bisFull Dark Day 2.7347271 1.5196166 93.663025 1.7996165 0.0751411
Treatment_bisSmart Dark Day 1.0131568 1.7143385 91.897979 0.5909899 0.5559780
Treatment_bisMixt_smart Dark Day 2.5507982 1.6449143 92.078674 1.5507180 0.1243997
SexMale Dark Day -0.1031342 1.1867124 90.551400 -0.0869075 0.9309369
RegionLuxembourg Dark Day 3.2682223 1.8400140 7.449481 1.7761942 0.1163774
Treatment_FTLMix Dark Day 4.7996538 1.6794181 86.731824 2.8579267 0.0053381
Treatment_FTLNight Dark Day 7.1095704 1.6391764 87.379616 4.3372822 0.0000385
Light_orientationSouth Dark Day -0.0957947 1.1761337 90.392439 -0.0814488 0.9352651
(Intercept)1 Smart Day -12.4039400 2.2587576 32.509707 -5.4914879 0.0000045
First_move1 Smart Day 0.0012444 0.0017608 92.275774 0.7066903 0.4815397
Treatment_bisDark Smart Day -1.0131568 1.7143385 91.897979 -0.5909899 0.5559780
Treatment_bisFull1 Smart Day 1.7215704 1.7193416 92.071639 1.0012963 0.3193079
Treatment_bisMixt_smart1 Smart Day 1.5376414 1.8702050 94.894187 0.8221780 0.4130367
SexMale1 Smart Day -0.1031342 1.1867124 90.551400 -0.0869075 0.9309369
RegionLuxembourg1 Smart Day 3.2682223 1.8400140 7.449481 1.7761942 0.1163774
Treatment_FTLMix1 Smart Day 4.7996538 1.6794181 86.731824 2.8579267 0.0053381
Treatment_FTLNight1 Smart Day 7.1095704 1.6391764 87.379616 4.3372822 0.0000385
Light_orientationSouth1 Smart Day -0.0957947 1.1761337 90.392439 -0.0814488 0.9352651
(Intercept)2 Full Day -10.6823696 2.0336153 26.782549 -5.2528959 0.0000158
First_move2 Full Day 0.0012444 0.0017608 92.275774 0.7066903 0.4815397
Treatment_bisDark1 Full Day -2.7347271 1.5196166 93.663025 -1.7996165 0.0751411
Treatment_bisSmart1 Full Day -1.7215704 1.7193416 92.071638 -1.0012963 0.3193079
Treatment_bisMixt_smart2 Full Day -0.1839289 1.6385450 87.263545 -0.1122514 0.9108819
SexMale2 Full Day -0.1031342 1.1867124 90.551400 -0.0869075 0.9309369
RegionLuxembourg2 Full Day 3.2682223 1.8400140 7.449481 1.7761942 0.1163774
Treatment_FTLMix2 Full Day 4.7996538 1.6794181 86.731824 2.8579267 0.0053381
Treatment_FTLNight2 Full Day 7.1095704 1.6391764 87.379616 4.3372822 0.0000385
Light_orientationSouth2 Full Day -0.0957947 1.1761337 90.392439 -0.0814488 0.9352651
(Intercept)3 Mixt_smart Day -10.8662986 2.2580447 36.101393 -4.8122601 0.0000265
First_move3 Mixt_smart Day 0.0012444 0.0017608 92.275774 0.7066903 0.4815397
Treatment_bisDark2 Mixt_smart Day -2.5507982 1.6449143 92.078677 -1.5507180 0.1243997
Treatment_bisFull2 Mixt_smart Day 0.1839289 1.6385450 87.263551 0.1122514 0.9108819
Treatment_bisSmart2 Mixt_smart Day -1.5376414 1.8702050 94.894206 -0.8221780 0.4130367
SexMale3 Mixt_smart Day -0.1031342 1.1867124 90.551400 -0.0869075 0.9309369
RegionLuxembourg3 Mixt_smart Day 3.2682223 1.8400140 7.449481 1.7761942 0.1163774
Treatment_FTLMix3 Mixt_smart Day 4.7996538 1.6794181 86.731824 2.8579267 0.0053381
Treatment_FTLNight3 Mixt_smart Day 7.1095704 1.6391764 87.379616 4.3372822 0.0000385
Light_orientationSouth3 Mixt_smart Day -0.0957947 1.1761337 90.392439 -0.0814488 0.9352651
(Intercept)4 Dark Mixt -8.6174429 2.2214479 24.591749 -3.8792010 0.0006907
First_move4 Dark Mixt 0.0012444 0.0017608 92.275774 0.7066903 0.4815397
Treatment_bisFull3 Dark Mixt 2.7347271 1.5196166 93.663025 1.7996165 0.0751411
Treatment_bisSmart3 Dark Mixt 1.0131568 1.7143385 91.897978 0.5909899 0.5559780
Treatment_bisMixt_smart3 Dark Mixt 2.5507982 1.6449143 92.078671 1.5507180 0.1243997
SexMale4 Dark Mixt -0.1031342 1.1867124 90.551400 -0.0869075 0.9309369
RegionLuxembourg4 Dark Mixt 3.2682223 1.8400140 7.449480 1.7761942 0.1163774
Treatment_FTLDay Dark Mixt -4.7996538 1.6794181 86.731824 -2.8579267 0.0053381
Treatment_FTLNight4 Dark Mixt 2.3099166 1.4892579 93.918429 1.5510521 0.1242526
Light_orientationSouth4 Dark Mixt -0.0957947 1.1761337 90.392439 -0.0814488 0.9352651
(Intercept)5 Dark Night -6.3075264 2.0806416 21.030478 -3.0315294 0.0063400
First_move5 Dark Night 0.0012444 0.0017608 92.275774 0.7066903 0.4815397
Treatment_bisFull4 Dark Night 2.7347271 1.5196166 93.663025 1.7996165 0.0751411
Treatment_bisSmart4 Dark Night 1.0131568 1.7143385 91.897978 0.5909899 0.5559780
Treatment_bisMixt_smart4 Dark Night 2.5507982 1.6449143 92.078671 1.5507180 0.1243997
SexMale5 Dark Night -0.1031342 1.1867124 90.551400 -0.0869075 0.9309369
RegionLuxembourg5 Dark Night 3.2682223 1.8400140 7.449480 1.7761942 0.1163774
Treatment_FTLDay1 Dark Night -7.1095704 1.6391764 87.379615 -4.3372822 0.0000385
Treatment_FTLMix4 Dark Night -2.3099166 1.4892579 93.918429 -1.5510521 0.1242526
Light_orientationSouth5 Dark Night -0.0957947 1.1761337 90.392439 -0.0814488 0.9352651
Info_Speed_to_light_by_First_move <- "
Aucun effet significatif de First move.
Les individus venants du traitement Full sont quasiement significativement (p-val = 0.07514) plus rapide que ceux du traitement Dark.
Les individus expérimentés durant la nuit ou en timing mixte sont significativement plus rapide que ceux de jour.
Les individus étants expérimentés dans les conditions mixtes sont plus lent que les individus expérimentés durant la nuit mais pas de manière significative (p-val = 0.124253).
"

5.8.5 Visualisation

ggplot(data = Data, aes(x = log(First_move), y = log(Speed_to_light+0.000001))) +
  geom_smooth(method = "lm", aes(color = Treatment_FTL), se = T, alpha = 0.2) + 
  geom_point(aes(color = Treatment_FTL, shape = Treatment_bis), alpha = 0.75) +
  labs(title = "Vitesse de déplacement à la lumière en fonction du temps pour le premier mouvement", x = "log(Temps mis pour faire le premier mouvement (s) ", y = "log(Vitesse pour aller à la lumière (min/s))", color = "Timing", shape = "Traitement") +
  theme_bw() +
  theme(title=element_text(size=10))
## `geom_smooth()` using formula = 'y ~ x'
## Warning: Removed 349 rows containing non-finite values (`stat_smooth()`).
## Warning: Removed 339 rows containing missing values (`geom_point()`).

6 Split by Species

6.1 Total_molt OP

Vu que c’est une variable de comptage, nous comptons faire un glm de type poisson

6.1.1 Test

GLM_Total_molt_OP <- glmer(Total_molt ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region + Sex:Region , family = poisson, data = Data_OP)
## boundary (singular) fit: see help('isSingular')
summary(GLM_Total_molt_OP)
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: poisson  ( log )
## Formula: Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region +  
##     Sex:Region
##    Data: Data_OP
## 
##      AIC      BIC   logLik deviance df.resid 
##    393.1    431.3   -183.6    367.1      126 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.3352 -0.4717  0.1827  0.2777  1.6632 
## 
## Random effects:
##  Groups Name        Variance Std.Dev.
##  Mother (Intercept) 0        0       
##  Site   (Intercept) 0        0       
##  Room   (Intercept) 0        0       
## Number of obs: 139, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                                     Estimate Std. Error z value Pr(>|z|)    
## (Intercept)                          0.52979    0.15002   3.532 0.000413 ***
## Treatment_bisFull                   -0.25607    0.26808  -0.955 0.339480    
## Treatment_bisSmart                   0.04200    0.35589   0.118 0.906060    
## SexMale                              0.02922    0.22234   0.131 0.895431    
## RegionLuxembourg                    -0.03272    0.21397  -0.153 0.878478    
## Treatment_bisFull:SexMale            0.06870    0.29733   0.231 0.817268    
## Treatment_bisSmart:SexMale          -0.10748    0.41449  -0.259 0.795398    
## Treatment_bisFull:RegionLuxembourg   0.32306    0.29816   1.084 0.278570    
## Treatment_bisSmart:RegionLuxembourg  0.03914    0.41722   0.094 0.925251    
## SexMale:RegionLuxembourg            -0.08501    0.27212  -0.312 0.754725    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S SexMal RgnLxm T_F:SM T_S:SM T_F:RL T_S:RL
## Trtmnt_bsFl -0.447                                                        
## Trtmnt_bsSm -0.361  0.223                                                 
## SexMale     -0.580  0.130  0.141                                          
## ReginLxmbrg -0.619  0.163  0.163  0.265                                   
## Trtmnt_F:SM  0.261 -0.580 -0.136 -0.450  0.082                            
## Trtmnt_S:SM  0.185 -0.142 -0.473 -0.319  0.062  0.297                     
## Trtmnt_F:RL  0.284 -0.632 -0.146  0.086 -0.459  0.062  0.009              
## Trtmnt_S:RL  0.225 -0.136 -0.626  0.023 -0.364 -0.001 -0.075  0.276       
## SxMl:RgnLxm  0.316  0.180  0.057 -0.545 -0.511 -0.139 -0.107 -0.139 -0.029
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Pas d’effet significatifs

Vérification des hypothèses

resid_panel(GLM_Total_molt_OP, plots = c("resid"), smoother = TRUE)
## `geom_smooth()` using formula = 'y ~ x'

Le modèle pourrait être siplifié par AIC (surtout pour les interactions)

6.1.2 Sipmplification du modèle

Simplification par AIC/BIC

drop1(GLM_Total_molt_OP)
## boundary (singular) fit: see help('isSingular')
## boundary (singular) fit: see help('isSingular')
## boundary (singular) fit: see help('isSingular')
## Single term deletions
## 
## Model:
## Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | 
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + 
##     Sex:Region
##                      npar    AIC
## <none>                    393.13
## Treatment_bis:Sex       2 389.30
## Treatment_bis:Region    2 390.36
## Sex:Region              1 391.23
GLM_Total_molt2_OP <- update(GLM_Total_molt_OP, . ~ . - Treatment_bis:Sex)
## boundary (singular) fit: see help('isSingular')
drop1(GLM_Total_molt2_OP)
## boundary (singular) fit: see help('isSingular')
## boundary (singular) fit: see help('isSingular')
## Single term deletions
## 
## Model:
## Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | 
##     Site) + (1 | Room) + Treatment_bis:Region + Sex:Region
##                      npar    AIC
## <none>                    389.30
## Treatment_bis:Region    2 386.51
## Sex:Region              1 387.40
GLM_Total_molt3_OP <- update(GLM_Total_molt2_OP, . ~ . - Treatment_bis:Region)
## boundary (singular) fit: see help('isSingular')
drop1(GLM_Total_molt3_OP)
## boundary (singular) fit: see help('isSingular')
## boundary (singular) fit: see help('isSingular')
## Single term deletions
## 
## Model:
## Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | 
##     Site) + (1 | Room) + Sex:Region
##               npar    AIC
## <none>             386.51
## Treatment_bis    2 382.63
## Sex:Region       1 384.55

Modèle final, aucune interactions n’était significative

GLM_Total_molt_OP <- GLM_Total_molt3_OP
summary(GLM_Total_molt_OP)
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: poisson  ( log )
## Formula: Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Sex:Region
##    Data: Data_OP
## 
##      AIC      BIC   logLik deviance df.resid 
##    386.5    412.9   -184.3    368.5      130 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.3136 -0.4910  0.2565  0.2931  1.9117 
## 
## Random effects:
##  Groups Name        Variance Std.Dev.
##  Mother (Intercept) 0        0       
##  Site   (Intercept) 0        0       
##  Room   (Intercept) 0        0       
## Number of obs: 139, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                           Estimate Std. Error z value Pr(>|z|)    
## (Intercept)               0.486245   0.136864   3.553 0.000381 ***
## Treatment_bisFull        -0.048515   0.146899  -0.330 0.741205    
## Treatment_bisSmart       -0.003917   0.205580  -0.019 0.984797    
## SexMale                   0.012236   0.192056   0.064 0.949201    
## RegionLuxembourg          0.063288   0.180318   0.351 0.725604    
## SexMale:RegionLuxembourg -0.049736   0.266602  -0.187 0.852009    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S SexMal RgnLxm
## Trtmnt_bsFl -0.319                            
## Trtmnt_bsSm -0.238  0.288                     
## SexMale     -0.588 -0.115 -0.026              
## ReginLxmbrg -0.633 -0.081 -0.055  0.482       
## SxMl:RgnLxm  0.440  0.049 -0.025 -0.717 -0.674
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

6.1.3 Treatment VS Treatment_bis

AIC(GLM_Total_molt_OP)
## [1] 386.5136
AIC(update(GLM_Total_molt_OP, . ~ . - Treatment_bis + Treatment))
## boundary (singular) fit: see help('isSingular')
## [1] 386.3491
summary(GLM_Total_molt_OP)$coeff
##                              Estimate Std. Error     z value     Pr(>|z|)
## (Intercept)               0.486245105  0.1368636  3.55277208 0.0003811946
## Treatment_bisFull        -0.048514668  0.1468992 -0.33025830 0.7412047961
## Treatment_bisSmart       -0.003917321  0.2055798 -0.01905499 0.9847972341
## SexMale                   0.012235869  0.1920557  0.06371000 0.9492011455
## RegionLuxembourg          0.063287922  0.1803179  0.35097969 0.7256035888
## SexMale:RegionLuxembourg -0.049735933  0.2666017 -0.18655521 0.8520093850
summary(update(GLM_Total_molt_OP, . ~ . - Treatment_bis + Treatment))$coeff
## boundary (singular) fit: see help('isSingular')
##                             Estimate Std. Error     z value    Pr(>|z|)
## (Intercept)               0.45373071  0.1551115  2.92519115 0.003442447
## SexMale                   0.01267160  0.1920041  0.06599650 0.947380613
## RegionLuxembourg          0.05773210  0.1805075  0.31983223 0.749095514
## TreatmentFull            -0.01457958  0.1633023 -0.08927969 0.928859638
## TreatmentSmart            0.06659543  0.1640351  0.40598292 0.684755152
## SexMale:RegionLuxembourg -0.04465214  0.2668129 -0.16735376 0.867091705

Aucune différence de significativité entre treatment et treatment_bis, on peut garder treatment_bis qui est meilleur scientifiquement parlant.

6.1.4 Résultats

summary(glmer(Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Sex:Region, family = poisson, data = Data_OP))
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: poisson  ( log )
## Formula: Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Sex:Region
##    Data: Data_OP
## 
##      AIC      BIC   logLik deviance df.resid 
##    386.5    412.9   -184.3    368.5      130 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.3136 -0.4910  0.2565  0.2931  1.9117 
## 
## Random effects:
##  Groups Name        Variance Std.Dev.
##  Mother (Intercept) 0        0       
##  Site   (Intercept) 0        0       
##  Room   (Intercept) 0        0       
## Number of obs: 139, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                           Estimate Std. Error z value Pr(>|z|)    
## (Intercept)               0.486245   0.136864   3.553 0.000381 ***
## Treatment_bisFull        -0.048515   0.146899  -0.330 0.741205    
## Treatment_bisSmart       -0.003917   0.205580  -0.019 0.984797    
## SexMale                   0.012236   0.192056   0.064 0.949201    
## RegionLuxembourg          0.063288   0.180318   0.351 0.725604    
## SexMale:RegionLuxembourg -0.049736   0.266602  -0.187 0.852009    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S SexMal RgnLxm
## Trtmnt_bsFl -0.319                            
## Trtmnt_bsSm -0.238  0.288                     
## SexMale     -0.588 -0.115 -0.026              
## ReginLxmbrg -0.633 -0.081 -0.055  0.482       
## SxMl:RgnLxm  0.440  0.049 -0.025 -0.717 -0.674
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(glmer(Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Sex:Region, family = poisson, data = Data_OP_ref_smart))
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: poisson  ( log )
## Formula: Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Sex:Region
##    Data: Data_OP_ref_smart
## 
##      AIC      BIC   logLik deviance df.resid 
##    386.5    412.9   -184.3    368.5      130 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.3136 -0.4910  0.2565  0.2931  1.9117 
## 
## Random effects:
##  Groups Name        Variance Std.Dev.
##  Mother (Intercept) 0        0       
##  Site   (Intercept) 0        0       
##  Room   (Intercept) 0        0       
## Number of obs: 139, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                           Estimate Std. Error z value Pr(>|z|)  
## (Intercept)               0.482328   0.218165   2.211    0.027 *
## Treatment_bisDark         0.003917   0.205580   0.019    0.985  
## Treatment_bisFull        -0.044597   0.215493  -0.207    0.836  
## SexMale                   0.012236   0.192056   0.064    0.949  
## RegionLuxembourg          0.063288   0.180318   0.351    0.726  
## SexMale:RegionLuxembourg -0.049736   0.266602  -0.187    0.852  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F SexMal RgnLxm
## Trtmnt_bsDr -0.793                            
## Trtmnt_bsFl -0.708  0.758                     
## SexMale     -0.393  0.026 -0.054              
## ReginLxmbrg -0.450  0.055 -0.002  0.482       
## SxMl:RgnLxm  0.252  0.025  0.057 -0.717 -0.674
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(glmer(Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Sex:Region, family = poisson, data = Data_OP_ref_full))
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: poisson  ( log )
## Formula: Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Sex:Region
##    Data: Data_OP_ref_full
## 
##      AIC      BIC   logLik deviance df.resid 
##    386.5    412.9   -184.3    368.5      130 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.3136 -0.4910  0.2565  0.2931  1.9117 
## 
## Random effects:
##  Groups Name        Variance Std.Dev.
##  Mother (Intercept) 0        0       
##  Site   (Intercept) 0        0       
##  Room   (Intercept) 0        0       
## Number of obs: 139, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                          Estimate Std. Error z value Pr(>|z|)   
## (Intercept)               0.43773    0.16584   2.640   0.0083 **
## Treatment_bisDark         0.04851    0.14690   0.330   0.7412   
## Treatment_bisSmart        0.04460    0.21549   0.207   0.8360   
## SexMale                   0.01224    0.19206   0.064   0.9492   
## RegionLuxembourg          0.06329    0.18032   0.351   0.7256   
## SexMale:RegionLuxembourg -0.04974    0.26660  -0.187   0.8520   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S SexMal RgnLxm
## Trtmnt_bsDr -0.623                            
## Trtmnt_bsSm -0.369  0.407                     
## SexMale     -0.587  0.115  0.054              
## ReginLxmbrg -0.594  0.081  0.002  0.482       
## SxMl:RgnLxm  0.407 -0.049 -0.057 -0.717 -0.674
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
test1 <- data.frame(Reference = "Dark", as.data.frame((summary(glmer(Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Sex:Region, family = poisson, data = Data_OP))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test2 <- data.frame(Reference = "Smart", as.data.frame((summary(glmer(Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Sex:Region, family = poisson, data = Data_OP_ref_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test3 <- data.frame(Reference = "Full", as.data.frame((summary(glmer(Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Sex:Region, family = poisson, data = Data_OP_ref_full))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
Results_Total_molt_OP <- rbind(test1,test2,test3)

colnames(Results_Total_molt_OP) <- c("Reference","Estimate", "Std. Error", "z value", "Pr(>|z|)")

write.csv2(Results_Total_molt_OP, file = "output/Results_Total_molt_OP.csv")

kable(Results_Total_molt_OP, caption = "Nombre total de mues OP", padding = 1 )
Nombre total de mues OP
Reference Estimate Std. Error z value Pr(>|z|)
(Intercept) Dark 0.4862451 0.1368636 3.5527721 0.0003812
Treatment_bisFull Dark -0.0485147 0.1468992 -0.3302583 0.7412048
Treatment_bisSmart Dark -0.0039173 0.2055798 -0.0190550 0.9847972
SexMale Dark 0.0122359 0.1920557 0.0637100 0.9492011
RegionLuxembourg Dark 0.0632879 0.1803179 0.3509797 0.7256036
SexMale:RegionLuxembourg Dark -0.0497359 0.2666017 -0.1865552 0.8520094
(Intercept)1 Smart 0.4823278 0.2181653 2.2108365 0.0270472
Treatment_bisDark Smart 0.0039173 0.2055798 0.0190550 0.9847972
Treatment_bisFull1 Smart -0.0445973 0.2154928 -0.2069551 0.8360449
SexMale1 Smart 0.0122359 0.1920558 0.0637100 0.9492012
RegionLuxembourg1 Smart 0.0632879 0.1803180 0.3509796 0.7256037
SexMale:RegionLuxembourg1 Smart -0.0497359 0.2666018 -0.1865551 0.8520095
(Intercept)2 Full 0.4377304 0.1658354 2.6395471 0.0083017
Treatment_bisDark1 Full 0.0485147 0.1468991 0.3302584 0.7412047
Treatment_bisSmart1 Full 0.0445973 0.2154928 0.2069551 0.8360449
SexMale2 Full 0.0122359 0.1920556 0.0637100 0.9492011
RegionLuxembourg2 Full 0.0632879 0.1803178 0.3509799 0.7256034
SexMale:RegionLuxembourg2 Full -0.0497359 0.2666015 -0.1865554 0.8520093
Info_Total_molt_OP <- "
Aucun effet significatif
"
Info_Total_molt_OP
## [1] "\nAucun effet significatif\n"

6.2 Total_molt AE

Vu que c’est une variable de comptage, nous comptons faire un glm de type poisson

6.2.1 Test

GLM_Total_molt_AE <- glmer(Total_molt ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region + Sex:Region , family = poisson, data = Data_AE)
## boundary (singular) fit: see help('isSingular')
summary(GLM_Total_molt_AE)
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: poisson  ( log )
## Formula: Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region +  
##     Sex:Region
##    Data: Data_AE
## 
##      AIC      BIC   logLik deviance df.resid 
##    598.6    648.3   -283.3    566.6      149 
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -1.85168 -0.29760 -0.02683  0.35037  1.27936 
## 
## Random effects:
##  Groups Name        Variance Std.Dev.
##  Mother (Intercept) 0.000000 0.00000 
##  Site   (Intercept) 0.001461 0.03822 
##  Room   (Intercept) 0.000000 0.00000 
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                           Estimate Std. Error z value Pr(>|z|)
## (Intercept)                               1.263775   0.118915  10.628   <2e-16
## Treatment_bisFull                        -0.147804   0.169427  -0.872    0.383
## Treatment_bisSmart                        0.058173   0.187460   0.310    0.756
## Treatment_bisMixt_smart                  -0.068014   0.197910  -0.344    0.731
## SexMale                                  -0.004123   0.165806  -0.025    0.980
## RegionLuxembourg                          0.061470   0.165136   0.372    0.710
## Treatment_bisFull:SexMale                 0.056400   0.210073   0.268    0.788
## Treatment_bisSmart:SexMale               -0.128764   0.249517  -0.516    0.606
## Treatment_bisMixt_smart:SexMale          -0.082381   0.246444  -0.334    0.738
## Treatment_bisFull:RegionLuxembourg        0.090312   0.208530   0.433    0.665
## Treatment_bisSmart:RegionLuxembourg      -0.061967   0.239124  -0.259    0.796
## Treatment_bisMixt_smart:RegionLuxembourg  0.167184   0.244110   0.685    0.493
## SexMale:RegionLuxembourg                  0.084125   0.168281   0.500    0.617
##                                             
## (Intercept)                              ***
## Treatment_bisFull                           
## Treatment_bisSmart                          
## Treatment_bisMixt_smart                     
## SexMale                                     
## RegionLuxembourg                            
## Treatment_bisFull:SexMale                   
## Treatment_bisSmart:SexMale                  
## Treatment_bisMixt_smart:SexMale             
## Treatment_bisFull:RegionLuxembourg          
## Treatment_bisSmart:RegionLuxembourg         
## Treatment_bisMixt_smart:RegionLuxembourg    
## SexMale:RegionLuxembourg                    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 13 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Pas d’effet significatifs

Vérification des hypothèses

resid_panel(GLM_Total_molt_AE, plots = c("resid"), smoother = TRUE)
## `geom_smooth()` using formula = 'y ~ x'

Le modèle pourrait être siplifié par AIC (surtout pour les interactions)

6.2.2 Sipmplification du modèle

Simplification par AIC/BIC

drop1(GLM_Total_molt_AE)
## boundary (singular) fit: see help('isSingular')
## boundary (singular) fit: see help('isSingular')
## boundary (singular) fit: see help('isSingular')
## Single term deletions
## 
## Model:
## Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | 
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + 
##     Sex:Region
##                      npar    AIC
## <none>                    598.63
## Treatment_bis:Sex       3 593.31
## Treatment_bis:Region    3 593.52
## Sex:Region              1 596.88
GLM_Total_molt2_AE <- update(GLM_Total_molt_AE, . ~ . - Treatment_bis:Sex)
## boundary (singular) fit: see help('isSingular')
drop1(GLM_Total_molt2_AE)
## boundary (singular) fit: see help('isSingular')
## boundary (singular) fit: see help('isSingular')
## Single term deletions
## 
## Model:
## Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | 
##     Site) + (1 | Room) + Treatment_bis:Region + Sex:Region
##                      npar    AIC
## <none>                    593.31
## Treatment_bis:Region    3 588.22
## Sex:Region              1 591.52
GLM_Total_molt3_AE <- update(GLM_Total_molt2_AE, . ~ . - Treatment_bis:Region)
## boundary (singular) fit: see help('isSingular')
drop1(GLM_Total_molt3_AE)
## boundary (singular) fit: see help('isSingular')
## boundary (singular) fit: see help('isSingular')
## Single term deletions
## 
## Model:
## Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | 
##     Site) + (1 | Room) + Sex:Region
##               npar    AIC
## <none>             588.22
## Treatment_bis    3 582.83
## Sex:Region       1 586.49

Modèle final, aucune interactions n’était significative

GLM_Total_molt_AE <- GLM_Total_molt3_AE
summary(GLM_Total_molt_AE)
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: poisson  ( log )
## Formula: Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Sex:Region
##    Data: Data_AE
## 
##      AIC      BIC   logLik deviance df.resid 
##    588.2    619.3   -284.1    568.2      155 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.8177 -0.3005 -0.0176  0.3129  1.3558 
## 
## Random effects:
##  Groups Name        Variance Std.Dev.
##  Mother (Intercept) 0.00000  0.00000 
##  Site   (Intercept) 0.00168  0.04099 
##  Room   (Intercept) 0.00000  0.00000 
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                          Estimate Std. Error z value Pr(>|z|)    
## (Intercept)               1.25340    0.09608  13.046   <2e-16 ***
## Treatment_bisFull        -0.07918    0.10390  -0.762    0.446    
## Treatment_bisSmart       -0.02561    0.11910  -0.215    0.830    
## Treatment_bisMixt_smart  -0.02337    0.12161  -0.192    0.848    
## SexMale                  -0.02681    0.11680  -0.230    0.818    
## RegionLuxembourg          0.10462    0.11250   0.930    0.352    
## SexMale:RegionLuxembourg  0.08672    0.16709   0.519    0.604    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm
## Trtmnt_bsFl -0.499                                   
## Trtmnt_bsSm -0.442  0.423                            
## Trtmnt_bsM_ -0.433  0.416  0.361                     
## SexMale     -0.485 -0.043  0.025 -0.018              
## ReginLxmbrg -0.526 -0.028 -0.058 -0.016  0.422       
## SxMl:RgnLxm  0.332  0.037  0.014  0.009 -0.698 -0.638
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

6.2.3 Treatment VS Treatment_bis

AIC(GLM_Total_molt_AE)
## [1] 588.2157
AIC(update(GLM_Total_molt_AE, . ~ . - Treatment_bis + Treatment))
## boundary (singular) fit: see help('isSingular')
## [1] 586.2159
summary(GLM_Total_molt_AE)$coeff
##                             Estimate Std. Error    z value     Pr(>|z|)
## (Intercept)               1.25339959  0.0960771 13.0457678 6.717682e-39
## Treatment_bisFull        -0.07917892  0.1038985 -0.7620796 4.460125e-01
## Treatment_bisSmart       -0.02560763  0.1190957 -0.2150173 8.297538e-01
## Treatment_bisMixt_smart  -0.02336661  0.1216071 -0.1921483 8.476260e-01
## SexMale                  -0.02681319  0.1168015 -0.2295620 8.184322e-01
## RegionLuxembourg          0.10461994  0.1125019  0.9299393 3.524025e-01
## SexMale:RegionLuxembourg  0.08672455  0.1670898  0.5190297 6.037400e-01
summary(update(GLM_Total_molt_AE, . ~ . - Treatment_bis + Treatment))$coeff
## boundary (singular) fit: see help('isSingular')
##                             Estimate Std. Error    z value     Pr(>|z|)
## (Intercept)               1.25339688 0.09607333 13.0462527 6.675070e-39
## SexMale                  -0.02673650 0.11671376 -0.2290775 8.188087e-01
## RegionLuxembourg          0.10454904 0.11242188  0.9299705 3.523863e-01
## TreatmentFull            -0.07916520 0.10389824 -0.7619494 4.460902e-01
## TreatmentSmart           -0.02453236 0.09926301 -0.2471450 8.047960e-01
## SexMale:RegionLuxembourg  0.08674486 0.16708641  0.5191617 6.036480e-01

Aucune différence de significativité entre treatment et treatment_bis

6.2.4 Résultats

summary(glmer(Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Sex:Region, data = Data_AE, family = poisson))
## boundary (singular) fit: see help('isSingular')
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: poisson  ( log )
## Formula: Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Sex:Region
##    Data: Data_AE
## 
##      AIC      BIC   logLik deviance df.resid 
##    588.2    619.3   -284.1    568.2      155 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.8177 -0.3005 -0.0176  0.3129  1.3558 
## 
## Random effects:
##  Groups Name        Variance Std.Dev.
##  Mother (Intercept) 0.00000  0.00000 
##  Site   (Intercept) 0.00168  0.04099 
##  Room   (Intercept) 0.00000  0.00000 
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                          Estimate Std. Error z value Pr(>|z|)    
## (Intercept)               1.25340    0.09608  13.046   <2e-16 ***
## Treatment_bisFull        -0.07918    0.10390  -0.762    0.446    
## Treatment_bisSmart       -0.02561    0.11910  -0.215    0.830    
## Treatment_bisMixt_smart  -0.02337    0.12161  -0.192    0.848    
## SexMale                  -0.02681    0.11680  -0.230    0.818    
## RegionLuxembourg          0.10462    0.11250   0.930    0.352    
## SexMale:RegionLuxembourg  0.08672    0.16709   0.519    0.604    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm
## Trtmnt_bsFl -0.499                                   
## Trtmnt_bsSm -0.442  0.423                            
## Trtmnt_bsM_ -0.433  0.416  0.361                     
## SexMale     -0.485 -0.043  0.025 -0.018              
## ReginLxmbrg -0.526 -0.028 -0.058 -0.016  0.422       
## SxMl:RgnLxm  0.332  0.037  0.014  0.009 -0.698 -0.638
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(glmer(Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Sex:Region, data = Data_AE_ref_smart, family = poisson))
## boundary (singular) fit: see help('isSingular')
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: poisson  ( log )
## Formula: Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Sex:Region
##    Data: Data_AE_ref_smart
## 
##      AIC      BIC   logLik deviance df.resid 
##    588.2    619.3   -284.1    568.2      155 
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -1.81768 -0.30049 -0.01761  0.31285  1.35587 
## 
## Random effects:
##  Groups Name        Variance Std.Dev.
##  Mother (Intercept) 0.000000 0.000   
##  Site   (Intercept) 0.001681 0.041   
##  Room   (Intercept) 0.000000 0.000   
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                           Estimate Std. Error z value Pr(>|z|)    
## (Intercept)               1.227792   0.115314  10.647   <2e-16 ***
## Treatment_bisDark         0.025602   0.119096   0.215    0.830    
## Treatment_bisFull        -0.053548   0.120457  -0.445    0.657    
## Treatment_bisMixt_smart   0.002248   0.136061   0.017    0.987    
## SexMale                  -0.026821   0.116802  -0.230    0.818    
## RegionLuxembourg          0.104594   0.112503   0.930    0.353    
## SexMale:RegionLuxembourg  0.086754   0.167090   0.519    0.604    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trt_M_ SexMal RgnLxm
## Trtmnt_bsDr -0.664                                   
## Trtmnt_bsFl -0.639  0.624                            
## Trtmnt_bsM_ -0.571  0.553  0.548                     
## SexMale     -0.378 -0.025 -0.063 -0.039              
## ReginLxmbrg -0.498  0.058  0.032  0.036  0.422       
## SxMl:RgnLxm  0.290 -0.014  0.019 -0.004 -0.698 -0.638
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(glmer(Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Sex:Region, data = Data_AE_ref_full, family = poisson))
## boundary (singular) fit: see help('isSingular')
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: poisson  ( log )
## Formula: Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Sex:Region
##    Data: Data_AE_ref_full
## 
##      AIC      BIC   logLik deviance df.resid 
##    588.2    619.3   -284.1    568.2      155 
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -1.81767 -0.30048 -0.01762  0.31286  1.35587 
## 
## Random effects:
##  Groups Name        Variance Std.Dev.
##  Mother (Intercept) 0.000000 0.000   
##  Site   (Intercept) 0.001681 0.041   
##  Room   (Intercept) 0.000000 0.000   
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                          Estimate Std. Error z value Pr(>|z|)    
## (Intercept)               1.17425    0.10029  11.708   <2e-16 ***
## Treatment_bisDark         0.07914    0.10390   0.762    0.446    
## Treatment_bisSmart        0.05354    0.12046   0.444    0.657    
## Treatment_bisMixt_smart   0.05580    0.12277   0.455    0.649    
## SexMale                  -0.02682    0.11680  -0.230    0.818    
## RegionLuxembourg          0.10460    0.11250   0.930    0.352    
## SexMale:RegionLuxembourg  0.08675    0.16709   0.519    0.604    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S Trt_M_ SexMal RgnLxm
## Trtmnt_bsDr -0.558                                   
## Trtmnt_bsSm -0.466  0.444                            
## Trtmnt_bsM_ -0.456  0.434  0.374                     
## SexMale     -0.510  0.043  0.063  0.018              
## ReginLxmbrg -0.533  0.028 -0.032  0.009  0.422       
## SxMl:RgnLxm  0.356 -0.037 -0.019 -0.023 -0.698 -0.638
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(glmer(Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Sex:Region, data = Data_AE_ref_full, family = poisson))
## boundary (singular) fit: see help('isSingular')
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: poisson  ( log )
## Formula: Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Sex:Region
##    Data: Data_AE_ref_full
## 
##      AIC      BIC   logLik deviance df.resid 
##    588.2    619.3   -284.1    568.2      155 
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -1.81767 -0.30048 -0.01762  0.31286  1.35587 
## 
## Random effects:
##  Groups Name        Variance Std.Dev.
##  Mother (Intercept) 0.000000 0.000   
##  Site   (Intercept) 0.001681 0.041   
##  Room   (Intercept) 0.000000 0.000   
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                          Estimate Std. Error z value Pr(>|z|)    
## (Intercept)               1.17425    0.10029  11.708   <2e-16 ***
## Treatment_bisDark         0.07914    0.10390   0.762    0.446    
## Treatment_bisSmart        0.05354    0.12046   0.444    0.657    
## Treatment_bisMixt_smart   0.05580    0.12277   0.455    0.649    
## SexMale                  -0.02682    0.11680  -0.230    0.818    
## RegionLuxembourg          0.10460    0.11250   0.930    0.352    
## SexMale:RegionLuxembourg  0.08675    0.16709   0.519    0.604    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S Trt_M_ SexMal RgnLxm
## Trtmnt_bsDr -0.558                                   
## Trtmnt_bsSm -0.466  0.444                            
## Trtmnt_bsM_ -0.456  0.434  0.374                     
## SexMale     -0.510  0.043  0.063  0.018              
## ReginLxmbrg -0.533  0.028 -0.032  0.009  0.422       
## SxMl:RgnLxm  0.356 -0.037 -0.019 -0.023 -0.698 -0.638
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
test1 <- data.frame(Reference = "Dark", as.data.frame(( summary(glmer(Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Sex:Region, data = Data_AE, family = poisson))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test2 <- data.frame(Reference = "Smart", as.data.frame(( summary(glmer(Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Sex:Region, data = Data_AE_ref_smart, family = poisson))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test3 <- data.frame(Reference = "Full", as.data.frame(( summary(glmer(Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Sex:Region, data = Data_AE_ref_full, family = poisson))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test4 <- data.frame(Reference = "Mixt_smart", as.data.frame(( summary(glmer(Total_molt ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Sex:Region, data = Data_AE_ref_mixt_smart, family = poisson))$coeff)[,])) 
## boundary (singular) fit: see help('isSingular')
Results_Total_molt_AE <- rbind(test1,test2,test3,test4)

colnames(Results_Total_molt_AE ) <- c("Reference","Estimate", "Std. Error", "z value", "Pr(>|z|)")

write.csv2(  Results_Total_molt_AE, file = "output/Results_Total_molt_AE.csv" )

kable(Results_Total_molt_AE , caption = " Nombre total de mues AE ", padding = 1 )
Nombre total de mues AE
Reference Estimate Std. Error z value Pr(>|z|)
(Intercept) Dark 1.2533996 0.0960771 13.0457678 0.0000000
Treatment_bisFull Dark -0.0791789 0.1038985 -0.7620796 0.4460125
Treatment_bisSmart Dark -0.0256076 0.1190957 -0.2150173 0.8297538
Treatment_bisMixt_smart Dark -0.0233666 0.1216071 -0.1921483 0.8476260
SexMale Dark -0.0268132 0.1168015 -0.2295620 0.8184322
RegionLuxembourg Dark 0.1046199 0.1125019 0.9299393 0.3524025
SexMale:RegionLuxembourg Dark 0.0867246 0.1670898 0.5190297 0.6037400
(Intercept)1 Smart 1.2277921 0.1153139 10.6473891 0.0000000
Treatment_bisDark Smart 0.0256021 0.1190965 0.2149691 0.8297914
Treatment_bisFull1 Smart -0.0535476 0.1204570 -0.4445371 0.6566543
Treatment_bisMixt_smart1 Smart 0.0022477 0.1360605 0.0165200 0.9868195
SexMale1 Smart -0.0268207 0.1168015 -0.2296260 0.8183824
RegionLuxembourg1 Smart 0.1045939 0.1125026 0.9297022 0.3525253
SexMale:RegionLuxembourg1 Smart 0.0867544 0.1670901 0.5192071 0.6036163
(Intercept)2 Full 1.1742453 0.1002937 11.7080620 0.0000000
Treatment_bisDark1 Full 0.0791422 0.1038985 0.7617263 0.4462234
Treatment_bisSmart1 Full 0.0535413 0.1204569 0.4444847 0.6566922
Treatment_bisMixt_smart2 Full 0.0558013 0.1227738 0.4545049 0.6494655
SexMale2 Full -0.0268181 0.1168015 -0.2296038 0.8183997
RegionLuxembourg2 Full 0.1046034 0.1125026 0.9297858 0.3524820
SexMale:RegionLuxembourg2 Full 0.0867451 0.1670900 0.5191518 0.6036549
(Intercept)3 Mixt_smart 1.2300293 0.1179253 10.4305769 0.0000000
Treatment_bisDark2 Mixt_smart 0.0233765 0.1216072 0.1922296 0.8475624
Treatment_bisFull2 Mixt_smart -0.0557830 0.1227740 -0.4543548 0.6495735
Treatment_bisSmart2 Mixt_smart -0.0022566 0.1360609 -0.0165850 0.9867677
SexMale3 Mixt_smart -0.0268038 0.1168010 -0.2294826 0.8184939
RegionLuxembourg3 Mixt_smart 0.1046209 0.1125020 0.9299465 0.3523988
SexMale:RegionLuxembourg3 Mixt_smart 0.0867120 0.1670895 0.5189554 0.6037919
Info_Total_molt_AE <- "
Aucun effet significatif
"
Info_Total_molt_AE
## [1] "\nAucun effet significatif\n"

6.3 Diapause OP

6.3.1 Test

GLM_Diapause_OP <- glmer(Diapause ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_OP, family = binomial)
## boundary (singular) fit: see help('isSingular')
summary(GLM_Diapause_OP)
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: Diapause ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data_OP
## 
##      AIC      BIC   logLik deviance df.resid 
##    113.7    149.0    -44.9     89.7      127 
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -0.70211 -0.41489 -0.33654 -0.00003  2.68571 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev. 
##  Mother (Intercept) 3.610e-01 6.008e-01
##  Site   (Intercept) 1.274e-10 1.129e-05
##  Room   (Intercept) 4.152e-10 2.038e-05
## Number of obs: 139, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                                       Estimate Std. Error z value Pr(>|z|)   
## (Intercept)                           -1.93804    0.60041  -3.228  0.00125 **
## Treatment_bisFull                      0.53178    0.97859   0.543  0.58685   
## Treatment_bisSmart                     0.33979    1.30885   0.260  0.79517   
## SexMale                                0.37934    0.65921   0.575  0.56498   
## RegionLuxembourg                      -0.04201    0.77203  -0.054  0.95661   
## Treatment_bisFull:SexMale             -1.72193    1.50534  -1.144  0.25267   
## Treatment_bisSmart:SexMale           -19.25642 9641.21023  -0.002  0.99841   
## Treatment_bisFull:RegionLuxembourg   -18.25665 4692.29814  -0.004  0.99690   
## Treatment_bisSmart:RegionLuxembourg    0.01103    1.80291   0.006  0.99512   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S SexMal RgnLxm T_F:SM T_S:SM T_F:RL
## Trtmnt_bsFl -0.505                                                 
## Trtmnt_bsSm -0.342  0.210                                          
## SexMale     -0.497  0.304  0.240                                   
## ReginLxmbrg -0.568  0.264  0.164 -0.036                            
## Trtmnt_F:SM  0.235 -0.593 -0.094 -0.431 -0.001                     
## Trtmnt_S:SM  0.000  0.000  0.000  0.000  0.000  0.000              
## Trtmnt_F:RL  0.000  0.000  0.000  0.000  0.000  0.000  0.000       
## Trtmnt_S:RL  0.157 -0.097 -0.682  0.009 -0.322 -0.011  0.000  0.000
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

6.3.2 Simplification du modèle

drop1(GLM_Diapause_OP)
## Single term deletions
## 
## Model:
## Diapause ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | 
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##                      npar    AIC
## <none>                    113.74
## Treatment_bis:Sex       2 113.24
## Treatment_bis:Region    2 113.78
GLM_Diapause1_OP <- update(GLM_Diapause_OP, . ~ . - Treatment_bis:Sex)
AIC(GLM_Diapause1_OP)
## [1] 113.2411
AIC(glmer(Diapause ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room), data = Data_OP, family = binomial))
## [1] 113.0036
GLM_Diapause_OP <- glmer(Diapause ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room), data = Data_OP, family = binomial)
## boundary (singular) fit: see help('isSingular')

6.3.3 Treatment VS Treatment_bis

AIC(glmer(Diapause ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room), data = Data_OP, family = binomial))
## boundary (singular) fit: see help('isSingular')
## [1] 113.0036
AIC(glmer(Diapause ~ Treatment + Sex + Region + (1|Mother) + (1|Site) + (1|Room), data = Data_OP, family = binomial))
## boundary (singular) fit: see help('isSingular')
## [1] 110.2848
summary(glmer(Diapause ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room), data = Data_OP, family = binomial))$coeff
## boundary (singular) fit: see help('isSingular')
##                      Estimate Std. Error    z value   Pr(>|z|)
## (Intercept)        -1.5383308  0.5835173 -2.6363069 0.00838139
## Treatment_bisFull  -1.0197762  0.6953539 -1.4665572 0.14249656
## Treatment_bisSmart -0.4659057  0.8578540 -0.5431060 0.58705683
## SexMale            -0.1806979  0.5579441 -0.3238638 0.74604115
## RegionLuxembourg   -0.4975839  0.7190727 -0.6919800 0.48894987
summary(glmer(Diapause ~ Treatment + Sex + Region + (1|Mother) + (1|Site) + (1|Room), data = Data_OP, family = binomial))$coeff
## boundary (singular) fit: see help('isSingular')
##                    Estimate Std. Error    z value   Pr(>|z|)
## (Intercept)      -1.1922173  0.6288869 -1.8957578 0.05799208
## TreatmentFull    -1.3861118  0.7189575 -1.9279468 0.05386175
## TreatmentSmart   -1.1175479  0.6726800 -1.6613366 0.09664587
## SexMale          -0.2208998  0.5644002 -0.3913886 0.69551000
## RegionLuxembourg -0.4581785  0.7457911 -0.6143523 0.53898252

Il vaut mieux garder treatment

6.3.4 Résultats

Analyse des p-val

summary(glmer(Diapause ~ Treatment + Sex + Region + (1|Mother) + (1|Site) + (1|Room), data = Data_OP, family = binomial))
## boundary (singular) fit: see help('isSingular')
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: Diapause ~ Treatment + Sex + Region + (1 | Mother) + (1 | Site) +  
##     (1 | Room)
##    Data: Data_OP
## 
##      AIC      BIC   logLik deviance df.resid 
##    110.3    133.8    -47.1     94.3      131 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -0.9322 -0.4109 -0.2479 -0.2104  3.5143 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev. 
##  Mother (Intercept) 5.097e-01 7.140e-01
##  Site   (Intercept) 4.129e-10 2.032e-05
##  Room   (Intercept) 0.000e+00 0.000e+00
## Number of obs: 139, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                  Estimate Std. Error z value Pr(>|z|)  
## (Intercept)       -1.1922     0.6289  -1.896   0.0580 .
## TreatmentFull     -1.3861     0.7190  -1.928   0.0539 .
## TreatmentSmart    -1.1175     0.6727  -1.661   0.0966 .
## SexMale           -0.2209     0.5644  -0.391   0.6955  
## RegionLuxembourg  -0.4582     0.7458  -0.614   0.5390  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TrtmnF TrtmnS SexMal
## TreatmntFll -0.277                     
## TretmntSmrt -0.280  0.300              
## SexMale     -0.335 -0.078  0.048       
## ReginLxmbrg -0.551 -0.024 -0.064 -0.028
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(glmer(Diapause ~ Treatment + Sex + Region + (1|Mother) + (1|Site) + (1|Room), data = Data_OP_ref_smart, family = binomial))
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: Diapause ~ Treatment + Sex + Region + (1 | Mother) + (1 | Site) +  
##     (1 | Room)
##    Data: Data_OP_ref_smart
## 
##      AIC      BIC   logLik deviance df.resid 
##    110.3    133.8    -47.1     94.3      131 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -0.9326 -0.4109 -0.2479 -0.2104  3.5150 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev.
##  Mother (Intercept) 5.110e-01 0.714816
##  Site   (Intercept) 9.000e-06 0.003000
##  Room   (Intercept) 2.692e-06 0.001641
## Number of obs: 139, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                  Estimate Std. Error z value Pr(>|z|)   
## (Intercept)       -2.3103     0.7819  -2.955  0.00313 **
## TreatmentDark      1.1173     0.6727   1.661  0.09671 . 
## TreatmentFull     -0.2689     0.8243  -0.326  0.74431   
## SexMale           -0.2212     0.5644  -0.392  0.69512   
## RegionLuxembourg  -0.4571     0.7462  -0.613  0.54016   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TrtmnD TrtmnF SexMal
## TreatmntDrk -0.635                     
## TreatmntFll -0.487  0.555              
## SexMale     -0.228 -0.048 -0.107       
## ReginLxmbrg -0.499  0.064  0.031 -0.028
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## Model failed to converge with max|grad| = 0.00689381 (tol = 0.002, component 1)
summary(glmer(Diapause ~ Treatment + Sex + Region + (1|Mother) + (1|Site) + (1|Room), data = Data_OP_ref_full, family = binomial))
## boundary (singular) fit: see help('isSingular')
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: Diapause ~ Treatment + Sex + Region + (1 | Mother) + (1 | Site) +  
##     (1 | Room)
##    Data: Data_OP_ref_full
## 
##      AIC      BIC   logLik deviance df.resid 
##    110.3    133.8    -47.1     94.3      131 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -0.9322 -0.4109 -0.2479 -0.2104  3.5145 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev. 
##  Mother (Intercept) 5.097e-01 7.139e-01
##  Site   (Intercept) 3.545e-09 5.954e-05
##  Room   (Intercept) 2.899e-10 1.703e-05
## Number of obs: 139, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                  Estimate Std. Error z value Pr(>|z|)   
## (Intercept)       -2.5784     0.8137  -3.169  0.00153 **
## TreatmentDark      1.3862     0.7190   1.928  0.05385 . 
## TreatmentSmart     0.2686     0.8243   0.326  0.74452   
## SexMale           -0.2209     0.5644  -0.391  0.69555   
## RegionLuxembourg  -0.4582     0.7458  -0.614  0.53899   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TrtmnD TrtmnS SexMal
## TreatmntDrk -0.670                     
## TretmntSmrt -0.545  0.628              
## SexMale     -0.328  0.078  0.107       
## ReginLxmbrg -0.447  0.024 -0.031 -0.028
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
test1 <- data.frame(Reference = "Dark", as.data.frame(( summary(glmer(Diapause ~ Treatment + Sex + Region + (1|Mother) + (1|Site) + (1|Room), data = Data_OP, family = binomial))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test2 <- data.frame(Reference = "Smart", as.data.frame(( summary(glmer(Diapause ~ Treatment + Sex + Region + (1|Mother) + (1|Site) + (1|Room), data = Data_OP_ref_smart, family = binomial))$coeff)[,]))
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## Model failed to converge with max|grad| = 0.00689381 (tol = 0.002, component 1)
test3 <- data.frame(Reference = "Full", as.data.frame(( summary(glmer(Diapause ~ Treatment + Sex + Region + (1|Mother) + (1|Site) + (1|Room), data = Data_OP_ref_full, family = binomial))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
Results_Diapause_OP <- rbind(test1,test2,test3)

colnames(Results_Diapause_OP ) <- c("Reference","Estimate", "Std. Error", "z value", "Pr(>|z|)")

write.csv2( Results_Diapause_OP , file = "output/Results_Diapause_OP.csv" )

kable(Results_Diapause_OP , caption = " Diapause OP ", padding = 1 )
Diapause OP
Reference Estimate Std. Error z value Pr(>|z|)
(Intercept) Dark -1.1922173 0.6288869 -1.8957578 0.0579921
TreatmentFull Dark -1.3861118 0.7189575 -1.9279468 0.0538617
TreatmentSmart Dark -1.1175479 0.6726800 -1.6613366 0.0966459
SexMale Dark -0.2208998 0.5644002 -0.3913886 0.6955100
RegionLuxembourg Dark -0.4581785 0.7457911 -0.6143523 0.5389825
(Intercept)1 Smart -2.3103071 0.7818686 -2.9548532 0.0031282
TreatmentDark Smart 1.1173213 0.6726738 1.6610150 0.0967104
TreatmentFull1 Smart -0.2688523 0.8243078 -0.3261552 0.7443069
SexMale1 Smart -0.2212116 0.5644356 -0.3919165 0.6951199
RegionLuxembourg1 Smart -0.4571072 0.7462111 -0.6125709 0.5401601
(Intercept)2 Full -2.5783911 0.8137345 -3.1685902 0.0015318
TreatmentDark1 Full 1.3861830 0.7189671 1.9280202 0.0538526
TreatmentSmart1 Full 0.2686228 0.8243133 0.3258747 0.7445192
SexMale2 Full -0.2208663 0.5643993 -0.3913299 0.6955534
RegionLuxembourg2 Full -0.4581691 0.7457825 -0.6143468 0.5389862
Info_Diapause_OP <-"
Aucun des paramètres sélectionnés n'est significatif mais les individus du traitements Full ont quasiement significativements (p-val = 0.0539) une plus faible probabilité d'être en diapause que les individus du traitement Dark.
"

6.4 Diapause AE

6.4.1 Test

GLM_Diapause_AE <- glmer(Diapause ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_AE, family = binomial)
## boundary (singular) fit: see help('isSingular')
summary(GLM_Diapause_AE)
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: Diapause ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data_AE
## 
##      AIC      BIC   logLik deviance df.resid 
##     84.5    131.1    -27.2     54.5      150 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.2621 -0.2014  0.0000  0.0000  6.0246 
## 
## Random effects:
##  Groups Name        Variance Std.Dev.
##  Mother (Intercept) 0.000    0.000   
##  Site   (Intercept) 2.419    1.555   
##  Room   (Intercept) 0.000    0.000   
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error z value Pr(>|z|)
## (Intercept)                                  -3.070      1.308  -2.348   0.0189
## Treatment_bisFull                             1.868      1.309   1.427   0.1536
## Treatment_bisSmart                          -19.403  21265.855  -0.001   0.9993
## Treatment_bisMixt_smart                     -43.129  52867.052  -0.001   0.9993
## SexMale                                     -19.759  24403.393  -0.001   0.9994
## RegionLuxembourg                            -19.593  16593.170  -0.001   0.9991
## Treatment_bisFull:SexMale                    17.505  24403.393   0.001   0.9994
## Treatment_bisSmart:SexMale                   40.943  32369.154   0.001   0.9990
## Treatment_bisMixt_smart:SexMale              42.791  47428.388   0.001   0.9993
## Treatment_bisFull:RegionLuxembourg           18.383  16593.170   0.001   0.9991
## Treatment_bisSmart:RegionLuxembourg          -5.582 271826.080   0.000   1.0000
## Treatment_bisMixt_smart:RegionLuxembourg     40.271  37634.287   0.001   0.9991
##                                           
## (Intercept)                              *
## Treatment_bisFull                         
## Treatment_bisSmart                        
## Treatment_bisMixt_smart                   
## SexMale                                   
## RegionLuxembourg                          
## Treatment_bisFull:SexMale                 
## Treatment_bisSmart:SexMale                
## Treatment_bisMixt_smart:SexMale           
## Treatment_bisFull:RegionLuxembourg        
## Treatment_bisSmart:RegionLuxembourg       
## Treatment_bisMixt_smart:RegionLuxembourg  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_F:SM T_S:SM T_M_:S
## Trtmnt_bsFl -0.748                                                        
## Trtmnt_bsSm  0.000  0.000                                                 
## Trtmnt_bsM_  0.000  0.000  0.000                                          
## SexMale      0.000  0.000  0.000  0.000                                   
## ReginLxmbrg  0.000  0.000  0.000  0.000  0.000                            
## Trtmnt_F:SM  0.000  0.000  0.000  0.000 -1.000  0.000                     
## Trtmnt_S:SM  0.000  0.000 -0.657  0.000 -0.754  0.000  0.754              
## Trtmn_M_:SM  0.000  0.000  0.000 -0.660 -0.515  0.000  0.515  0.388       
## Trtmnt_F:RL  0.000  0.000  0.000  0.000  0.000 -1.000  0.000  0.000  0.000
## Trtmnt_S:RL  0.000  0.000  0.000  0.000  0.000 -0.061  0.000  0.000  0.000
## Trtmn_M_:RL  0.000  0.000  0.000 -0.573  0.000 -0.441  0.000  0.000  0.000
##             T_F:RL T_S:RL
## Trtmnt_bsFl              
## Trtmnt_bsSm              
## Trtmnt_bsM_              
## SexMale                  
## ReginLxmbrg              
## Trtmnt_F:SM              
## Trtmnt_S:SM              
## Trtmn_M_:SM              
## Trtmnt_F:RL              
## Trtmnt_S:RL  0.061       
## Trtmn_M_:RL  0.441  0.027
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

6.4.2 Simplification du modèle

drop1(GLM_Diapause_AE)
## boundary (singular) fit: see help('isSingular')
## Single term deletions
## 
## Model:
## Diapause ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | 
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##                      npar    AIC
## <none>                    84.490
## Treatment_bis:Sex       3 88.846
## Treatment_bis:Region    3 82.414
GLM_Diapause1_AE <- update(GLM_Diapause_AE, . ~ . - Treatment_bis:Region)
drop1(GLM_Diapause1_AE)
## Single term deletions
## 
## Model:
## Diapause ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | 
##     Site) + (1 | Room) + Treatment_bis:Sex
##                   npar    AIC
## <none>                 82.414
## Region               1 81.154
## Treatment_bis:Sex    3 86.730
GLM_Diapause_AE <- glmer(Diapause ~ Treatment_bis + Sex + Region + Treatment_bis:Sex + (1|Mother) + (1|Site) + (1|Room), data = Data_AE, family = binomial)
## boundary (singular) fit: see help('isSingular')

6.4.3 Treatment VS Treatment_bis

AIC(glmer(Diapause ~ Treatment_bis + Sex + Region + Treatment_bis:Sex + (1|Mother) + (1|Site) + (1|Room), data = Data_AE, family = binomial))
## boundary (singular) fit: see help('isSingular')
## [1] 82.41361
AIC(glmer(Diapause ~ Treatment + Sex + Region + Treatment:Sex + (1|Mother) + (1|Site) + (1|Room), data = Data_AE, family = binomial))
## boundary (singular) fit: see help('isSingular')
## [1] 78.68738
summary(glmer(Diapause ~ Treatment_bis + Sex + Region + Treatment_bis:Sex + (1|Mother) + (1|Site) + (1|Room), data = Data_AE, family = binomial))$coeff
## boundary (singular) fit: see help('isSingular')
##                                   Estimate Std. Error     z value    Pr(>|z|)
## (Intercept)                      -3.479122   1.280532 -2.71693428 0.006588969
## Treatment_bisFull                 2.210197   1.192416  1.85354611 0.063804123
## Treatment_bisSmart              -19.223144 592.969459 -0.03241844 0.974138359
## Treatment_bisMixt_smart         -20.187756 366.887936 -0.05502431 0.956119097
## SexMale                         -19.453899 260.237462 -0.07475441 0.940410113
## RegionLuxembourg                 -1.155446   1.527478 -0.75644019 0.449385317
## Treatment_bisFull:SexMale        17.281962 260.238690  0.06640812 0.947052905
## Treatment_bisSmart:SexMale       40.278179 556.803635  0.07233821 0.942332757
## Treatment_bisMixt_smart:SexMale  40.354707 394.738420  0.10223152 0.918572913
summary(glmer(Diapause ~ Treatment + Sex + Region + Treatment:Sex + (1|Mother) + (1|Site) + (1|Room), data = Data_AE, family = binomial))$coeff
## boundary (singular) fit: see help('isSingular')
##                          Estimate  Std. Error     z value    Pr(>|z|)
## (Intercept)             -3.477686    1.258433 -2.76350571 0.005718409
## TreatmentFull            2.200500    1.181990  1.86169087 0.062646676
## TreatmentSmart         -18.903029 1643.105392 -0.01150445 0.990820977
## SexMale                -18.259327  621.035110 -0.02940144 0.976544423
## RegionLuxembourg        -1.039567    1.446369 -0.71874273 0.472299450
## TreatmentFull:SexMale   16.118509  621.034465  0.02595429 0.979293797
## TreatmentSmart:SexMale  38.265406 1456.455366  0.02627297 0.979039615

Il vaut mieux garder treatment

6.4.4 Résultats

Analyse des p-val

summary(glmer(Diapause ~ Treatment + Sex + Region + Treatment_bis:Sex + (1|Mother) + (1|Site) + (1|Room), data = Data_AE, family = binomial))
## fixed-effect model matrix is rank deficient so dropping 2 columns / coefficients
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: Diapause ~ Treatment + Sex + Region + Treatment_bis:Sex + (1 |  
##     Mother) + (1 | Site) + (1 | Room)
##    Data: Data_AE
## 
##      AIC      BIC   logLik deviance df.resid 
##     82.4    119.7    -29.2     58.4      153 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.2913 -0.1992 -0.0833  0.0000  5.5202 
## 
## Random effects:
##  Groups Name        Variance  Std.Dev.
##  Mother (Intercept) 3.007e-05 0.005484
##  Site   (Intercept) 2.279e+00 1.509567
##  Room   (Intercept) 1.259e-06 0.001122
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                     Estimate Std. Error z value Pr(>|z|)   
## (Intercept)                          -3.4791     1.3273  -2.621  0.00876 **
## TreatmentFull                        19.4110 15811.6683   0.001  0.99902   
## TreatmentSmart                       20.0856 15811.6683   0.001  0.99899   
## SexMale                             -19.3726 15811.6683  -0.001  0.99902   
## RegionLuxembourg                     -1.1554     1.3136  -0.880  0.37909   
## SexFemale:Treatment_bisFull         -17.2008 15811.6683  -0.001  0.99913   
## SexFemale:Treatment_bisSmart        -37.9449 17563.3624  -0.002  0.99828   
## SexMale:Treatment_bisSmart            0.8881     1.7244   0.515  0.60656   
## SexFemale:Treatment_bisMixt_smart   -38.7115 19020.5388  -0.002  0.99838   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TrtmnF TrtmnS SexMal RgnLxm SF:T_F SF:T_S SM:T_S
## TreatmntFll  0.000                                                 
## TretmntSmrt  0.000  1.000                                          
## SexMale      0.000 -1.000 -1.000                                   
## ReginLxmbrg -0.340  0.000  0.000  0.000                            
## SxFml:Trt_F  0.000 -1.000 -1.000  1.000  0.000                     
## SxFml:Trt_S  0.000 -0.900 -0.900  0.900  0.000  0.900              
## SxMl:Trtm_S  0.021  0.000  0.000  0.000 -0.045  0.000  0.000       
## SxFml:Tr_M_  0.000 -0.831 -0.831  0.831  0.000  0.831  0.748  0.000
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 2 columns / coefficients
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## unable to evaluate scaled gradient
## Model failed to converge: degenerate  Hessian with 1 negative eigenvalues
summary(glmer(Diapause ~ Treatment + Sex + Region + Treatment_bis:Sex + (1|Mother) + (1|Site) + (1|Room), data = Data_AE_ref_full, family = binomial))
## fixed-effect model matrix is rank deficient so dropping 2 columns / coefficients
## boundary (singular) fit: see help('isSingular')
## Generalized linear mixed model fit by maximum likelihood (Laplace
##   Approximation) [glmerMod]
##  Family: binomial  ( logit )
## Formula: Diapause ~ Treatment + Sex + Region + Treatment_bis:Sex + (1 |  
##     Mother) + (1 | Site) + (1 | Room)
##    Data: Data_AE_ref_full
## 
##      AIC      BIC   logLik deviance df.resid 
##     82.4    119.7    -29.2     58.4      153 
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.2914 -0.1992 -0.0833  0.0000  5.5205 
## 
## Random effects:
##  Groups Name        Variance Std.Dev.
##  Mother (Intercept) 0.000    0.00    
##  Site   (Intercept) 2.279    1.51    
##  Room   (Intercept) 0.000    0.00    
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                     Estimate Std. Error z value Pr(>|z|)  
## (Intercept)                       -1.269e+00  8.878e-01  -1.429   0.1529  
## TreatmentDark                     -2.464e+01  2.165e+05   0.000   0.9999  
## TreatmentSmart                     6.748e-01  1.661e+00   0.406   0.6845  
## SexMale                           -2.172e+00  1.292e+00  -1.681   0.0927 .
## RegionLuxembourg                  -1.155e+00  1.314e+00  -0.880   0.3791  
## SexFemale:Treatment_bisDark        2.243e+01  2.165e+05   0.000   0.9999  
## SexFemale:Treatment_bisSmart      -1.690e+02  1.501e+07   0.000   1.0000  
## SexMale:Treatment_bisSmart         8.881e-01  1.724e+00   0.515   0.6065  
## SexFemale:Treatment_bisMixt_smart -1.803e+02  1.678e+07   0.000   1.0000  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TrtmnD TrtmnS SexMal RgnLxm SF:T_D SF:T_S SM:T_S
## TreatmntDrk  0.000                                                 
## TretmntSmrt  0.013  0.000                                          
## SexMale     -0.286  0.000 -0.630                                   
## ReginLxmbrg -0.571  0.000 -0.014  0.051                            
## SxFml:Trt_D  0.000 -1.000  0.000  0.000  0.000                     
## SxFml:Trt_S  0.000  0.000  0.000  0.000  0.000  0.000              
## SxMl:Trtm_S  0.030  0.000 -0.510 -0.020 -0.045  0.000  0.000       
## SxFml:Tr_M_  0.000  0.000  0.000  0.000  0.000  0.000  0.000  0.000
## fit warnings:
## fixed-effect model matrix is rank deficient so dropping 2 columns / coefficients
## optimizer (Nelder_Mead) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
test1 <- data.frame(Reference = "Dark", as.data.frame(( summary(glmer(Diapause ~ Treatment + Sex + Region + Treatment_bis:Sex + (1|Mother) + (1|Site) + (1|Room), data = Data_AE, family = binomial))$coeff)[,]))
## fixed-effect model matrix is rank deficient so dropping 2 columns / coefficients
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## unable to evaluate scaled gradient
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## Model failed to converge: degenerate Hessian with 1 negative eigenvalues
## Warning in vcov.merMod(object, use.hessian = use.hessian): variance-covariance matrix computed from finite-difference Hessian is
## not positive definite or contains NA values: falling back to var-cov estimated from RX
## Warning in vcov.merMod(object, correlation = correlation, sigm = sig): variance-covariance matrix computed from finite-difference Hessian is
## not positive definite or contains NA values: falling back to var-cov estimated from RX
test2 <- data.frame(Reference = "Smart", as.data.frame(( summary(glmer(Diapause ~ Treatment + Sex + Region + Treatment_bis:Sex + (1|Mother) + (1|Site) + (1|Room), data = Data_AE_ref_full, family = binomial))$coeff)[,]))
## fixed-effect model matrix is rank deficient so dropping 2 columns / coefficients
## boundary (singular) fit: see help('isSingular')
## Warning in vcov.merMod(object, use.hessian = use.hessian): variance-covariance matrix computed from finite-difference Hessian is
## not positive definite or contains NA values: falling back to var-cov estimated from RX

## Warning in vcov.merMod(object, use.hessian = use.hessian): variance-covariance matrix computed from finite-difference Hessian is
## not positive definite or contains NA values: falling back to var-cov estimated from RX
Results_Diapause_AE <- rbind(test1,test2)

colnames(Results_Diapause_AE ) <- c("Reference","Estimate", "Std. Error", "z value", "Pr(>|z|)")

write.csv2( Results_Diapause_AE , file = "output/Results_Diapause_AE.csv" )

kable(Results_Diapause_AE , caption = " Diapause AE ", padding = 1 )
Diapause AE
Reference Estimate Std. Error z value Pr(>|z|)
(Intercept) Dark -3.4791485 1.327303e+00 -2.6212170 0.0087616
TreatmentFull Dark 19.4109581 1.581167e+04 0.0012276 0.9990205
TreatmentSmart Dark 20.0856412 1.581167e+04 0.0012703 0.9989864
SexMale Dark -19.3725899 1.581167e+04 -0.0012252 0.9990224
RegionLuxembourg Dark -1.1553667 1.313561e+00 -0.8795685 0.3790931
SexFemale:Treatment_bisFull Dark -17.2007606 1.581167e+04 -0.0010879 0.9991320
SexFemale:Treatment_bisSmart Dark -37.9449212 1.756336e+04 -0.0021605 0.9982762
SexMale:Treatment_bisSmart Dark 0.8880640 1.724417e+00 0.5149939 0.6065573
SexFemale:Treatment_bisMixt_smart Dark -38.7115363 1.902054e+04 -0.0020352 0.9983761
(Intercept)1 Smart -1.2689256 8.878030e-01 -1.4292873 0.1529217
TreatmentDark Smart -24.6442357 2.164656e+05 -0.0001138 0.9999092
TreatmentSmart1 Smart 0.6747943 1.660676e+00 0.4063372 0.6844949
SexMale1 Smart -2.1719363 1.291803e+00 -1.6813213 0.0927005
RegionLuxembourg1 Smart -1.1554460 1.313586e+00 -0.8796120 0.3790695
SexFemale:Treatment_bisDark Smart 22.4340391 2.164656e+05 0.0001036 0.9999173
SexFemale:Treatment_bisSmart1 Smart -168.9557808 1.500600e+07 -0.0000113 0.9999910
SexMale:Treatment_bisSmart1 Smart 0.8880807 1.724407e+00 0.5150063 0.6065486
SexFemale:Treatment_bisMixt_smart1 Smart -180.3280889 1.677722e+07 -0.0000107 0.9999914
Info_Diapause_AE <-"
Aucun des facteurs repris ne s'avère significatif.
"

6.5 TT_pupation OP

6.5.1 Test

LM_TT_pupation_OP <- lmer(TT_pupation ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_OP)
## boundary (singular) fit: see help('isSingular')
summary(LM_TT_pupation_OP)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: TT_pupation ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data_OP
## 
## REML criterion at convergence: 602
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.45945 -0.60793 -0.06979  0.62440  2.53240 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 3.826e+00 1.9560376
##  Site     (Intercept) 8.949e-09 0.0000946
##  Room     (Intercept) 0.000e+00 0.0000000
##  Residual             4.163e+00 2.0402435
## Number of obs: 139, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                                      Estimate Std. Error        df t value
## (Intercept)                          15.02193    0.89649  10.84024  16.756
## Treatment_bisFull                    -0.47255    0.66966 120.05094  -0.706
## Treatment_bisSmart                   -0.36411    0.98124 120.30282  -0.371
## SexMale                              -0.58369    0.49716 119.35550  -1.174
## RegionLuxembourg                     -0.18131    1.24845  10.21058  -0.145
## Treatment_bisFull:SexMale            -0.21553    0.78291 120.17333  -0.275
## Treatment_bisSmart:SexMale           -0.08466    1.13599 121.98001  -0.075
## Treatment_bisFull:RegionLuxembourg    0.81149    0.76755 119.60400   1.057
## Treatment_bisSmart:RegionLuxembourg   1.41543    1.13659 120.69955   1.245
##                                     Pr(>|t|)    
## (Intercept)                         4.28e-09 ***
## Treatment_bisFull                      0.482    
## Treatment_bisSmart                     0.711    
## SexMale                                0.243    
## RegionLuxembourg                       0.887    
## Treatment_bisFull:SexMale              0.784    
## Treatment_bisSmart:SexMale             0.941    
## Treatment_bisFull:RegionLuxembourg     0.293    
## Treatment_bisSmart:RegionLuxembourg    0.215    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S SexMal RgnLxm T_F:SM T_S:SM T_F:RL
## Trtmnt_bsFl -0.256                                                 
## Trtmnt_bsSm -0.155  0.224                                          
## SexMale     -0.197  0.269  0.198                                   
## ReginLxmbrg -0.684  0.127  0.067 -0.029                            
## Trtmnt_F:SM  0.135 -0.568 -0.129 -0.634  0.028                     
## Trtmnt_S:SM  0.082 -0.123 -0.487 -0.456  0.040  0.298              
## Trtmnt_F:RL  0.164 -0.591 -0.140  0.039 -0.259  0.009 -0.022       
## Trtmnt_S:RL  0.098 -0.127 -0.595  0.031 -0.181 -0.040 -0.127  0.277
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Normalité des résidus

qqnorm(resid(LM_TT_pupation_OP))
qqline(resid(LM_TT_pupation_OP))

Homogénité des variances

plot(LM_TT_pupation_OP)

Distance de cook

plot(cooks.distance(LM_TT_pupation_OP))

6.5.2 Simplification du modèle

drop1(LM_TT_pupation_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## TT_pupation ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##                      Sum Sq Mean Sq NumDF  DenDF F value Pr(>F)
## Treatment_bis:Sex    0.3157  0.1579     2 121.02  0.0379 0.9628
## Treatment_bis:Region 8.7427  4.3714     2 120.25  1.0502 0.3531
LM_TT_pupation1_OP <- update(LM_TT_pupation_OP, . ~ . - Treatment_bis:Sex)
## boundary (singular) fit: see help('isSingular')
drop1(LM_TT_pupation1_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## TT_pupation ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region
##                       Sum Sq Mean Sq NumDF  DenDF F value  Pr(>F)  
## Sex                  14.5126  14.513     1 122.35  3.5428 0.06218 .
## Treatment_bis:Region  8.7461   4.373     2 122.25  1.0675 0.34704  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_TT_pupation2_OP <- update(LM_TT_pupation1_OP, . ~ . - Treatment_bis:Region)
## boundary (singular) fit: see help('isSingular')
drop1(LM_TT_pupation2_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## TT_pupation ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room)
##                Sum Sq Mean Sq NumDF   DenDF F value  Pr(>F)  
## Treatment_bis  3.9397  1.9699     2 124.438  0.4814 0.61905  
## Sex           14.5677 14.5677     1 124.254  3.5603 0.06151 .
## Region         0.2717  0.2717     1   8.904  0.0664 0.80252  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

On a plus d’interactions, nous pouvons nous arrêter ici

LM_TT_pupation_OP <- LM_TT_pupation2_OP

6.5.3 Treatment VS Treatment_bis

AIC(lmer(TT_pupation ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) , data = Data_OP))
## boundary (singular) fit: see help('isSingular')
## [1] 628.8124
AIC(lmer(TT_pupation ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) , data = Data_OP))
## boundary (singular) fit: see help('isSingular')
## [1] 629.7694
summary(lmer(TT_pupation ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) , data = Data_OP))$coeff
## boundary (singular) fit: see help('isSingular')
##                      Estimate Std. Error         df    t value     Pr(>|t|)
## (Intercept)        14.8358273  0.8847806   9.993524 16.7678031 1.203012e-08
## Treatment_bisFull  -0.1725540  0.3831668 123.907326 -0.4503363 6.532549e-01
## Treatment_bisSmart  0.3866638  0.5527276 124.887166  0.6995558 4.855057e-01
## SexMale            -0.6684056  0.3542391 124.254186 -1.8868770 6.151027e-02
## RegionLuxembourg    0.3129471  1.2145570   8.903706  0.2576636 8.025228e-01
summary(lmer(TT_pupation ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) , data = Data_OP))$coeff
## boundary (singular) fit: see help('isSingular')
##                     Estimate Std. Error         df    t value     Pr(>|t|)
## (Intercept)      14.86569007  0.9092172  10.913056 16.3499870 5.080861e-09
## TreatmentFull    -0.22772494  0.4220603 123.587713 -0.5395555 5.904744e-01
## TreatmentSmart    0.04939317  0.4350396 123.965021  0.1135372 9.097883e-01
## SexMale          -0.64459955  0.3536232 124.018063 -1.8228429 7.073596e-02
## RegionLuxembourg  0.34650054  1.2211154   8.894624  0.2837574 7.830906e-01

Aucune différence significative

6.5.4 Résultats

Analyse des P-val

summary(lmer(TT_pupation ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) , data = Data_OP))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: TT_pupation ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room)
##    Data: Data_OP
## 
## REML criterion at convergence: 610.8
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.3490 -0.5984 -0.1176  0.5181  2.6717 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 3.961    1.990   
##  Site     (Intercept) 0.000    0.000   
##  Room     (Intercept) 0.000    0.000   
##  Residual             4.092    2.023   
## Number of obs: 139, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                    Estimate Std. Error       df t value Pr(>|t|)    
## (Intercept)         14.8358     0.8848   9.9935  16.768  1.2e-08 ***
## Treatment_bisFull   -0.1726     0.3832 123.9073  -0.450   0.6533    
## Treatment_bisSmart   0.3867     0.5527 124.8872   0.700   0.4855    
## SexMale             -0.6684     0.3542 124.2542  -1.887   0.0615 .  
## RegionLuxembourg     0.3129     1.2146   8.9037   0.258   0.8025    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S SexMal
## Trtmnt_bsFl -0.151                     
## Trtmnt_bsSm -0.086  0.296              
## SexMale     -0.144 -0.134 -0.089       
## ReginLxmbrg -0.686 -0.014 -0.043  0.004
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(TT_pupation ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) , data = Data_OP_ref_full))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: TT_pupation ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room)
##    Data: Data_OP_ref_full
## 
## REML criterion at convergence: 610.8
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.3490 -0.5984 -0.1176  0.5181  2.6717 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 3.961    1.990   
##  Site     (Intercept) 0.000    0.000   
##  Room     (Intercept) 0.000    0.000   
##  Residual             4.092    2.023   
## Number of obs: 139, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                    Estimate Std. Error       df t value Pr(>|t|)    
## (Intercept)         14.6633     0.9095  11.2160  16.122 4.14e-09 ***
## Treatment_bisDark    0.1726     0.3832 123.9073   0.450   0.6533    
## Treatment_bisSmart   0.5592     0.5719 124.7909   0.978   0.3300    
## SexMale             -0.6684     0.3542 124.2542  -1.887   0.0615 .  
## RegionLuxembourg     0.3129     1.2146   8.9037   0.258   0.8025    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S SexMal
## Trtmnt_bsDr -0.274                     
## Trtmnt_bsSm -0.145  0.384              
## SexMale     -0.197  0.134  0.003       
## ReginLxmbrg -0.673  0.014 -0.032  0.004
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(TT_pupation ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) , data = Data_OP_ref_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: TT_pupation ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room)
##    Data: Data_OP_ref_smart
## 
## REML criterion at convergence: 610.8
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.3490 -0.5984 -0.1176  0.5181  2.6717 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 3.961    1.990   
##  Site     (Intercept) 0.000    0.000   
##  Room     (Intercept) 0.000    0.000   
##  Residual             4.092    2.023   
## Number of obs: 139, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                   Estimate Std. Error       df t value Pr(>|t|)    
## (Intercept)        15.2225     1.0019  16.2439  15.193 5.03e-11 ***
## Treatment_bisDark  -0.3867     0.5527 124.8872  -0.700   0.4855    
## Treatment_bisFull  -0.5592     0.5719 124.7909  -0.978   0.3300    
## SexMale            -0.6684     0.3542 124.2542  -1.887   0.0615 .  
## RegionLuxembourg    0.3129     1.2146   8.9037   0.258   0.8025    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F SexMal
## Trtmnt_bsDr -0.475                     
## Trtmnt_bsFl -0.439  0.768              
## SexMale     -0.177  0.089 -0.003       
## ReginLxmbrg -0.629  0.043  0.032  0.004
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
test1 <- data.frame(Reference = "Dark", as.data.frame(( summary(lmer(TT_pupation ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) , data = Data_OP))
$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test2 <- data.frame(Reference = "Smart", as.data.frame(( summary(lmer(TT_pupation ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) , data = Data_OP_ref_smart))
$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test3 <- data.frame(Reference = "Full", as.data.frame(( summary(lmer(TT_pupation ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) , data = Data_OP_ref_full))
$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
Results_TT_pupation_OP <- rbind(test1,test2,test3)

colnames(Results_TT_pupation_OP ) <- c("Reference","Estimate", "Std. Error", "df", "t.value", "Pr(>|z|)")

write.csv2( Results_TT_pupation_OP , file = "output/Results_TT_pupation_OP.csv" )

kable(Results_TT_pupation_OP , caption = " Temps pour entrer en chrysalide OP ", padding = 1 )
Temps pour entrer en chrysalide OP
Reference Estimate Std. Error df t.value Pr(>|z|)
(Intercept) Dark 14.8358273 0.8847806 9.993524 16.7678031 0.0000000
Treatment_bisFull Dark -0.1725540 0.3831668 123.907326 -0.4503363 0.6532549
Treatment_bisSmart Dark 0.3866638 0.5527276 124.887166 0.6995558 0.4855057
SexMale Dark -0.6684056 0.3542391 124.254186 -1.8868770 0.0615103
RegionLuxembourg Dark 0.3129471 1.2145570 8.903706 0.2576636 0.8025228
(Intercept)1 Smart 15.2224911 1.0019155 16.243857 15.1933879 0.0000000
Treatment_bisDark Smart -0.3866638 0.5527276 124.887166 -0.6995558 0.4855057
Treatment_bisFull1 Smart -0.5592178 0.5718510 124.790868 -0.9779082 0.3300117
SexMale1 Smart -0.6684056 0.3542391 124.254186 -1.8868770 0.0615103
RegionLuxembourg1 Smart 0.3129471 1.2145570 8.903706 0.2576636 0.8025228
(Intercept)2 Full 14.6632733 0.9095338 11.215986 16.1217470 0.0000000
Treatment_bisDark1 Full 0.1725540 0.3831668 123.907326 0.4503363 0.6532549
Treatment_bisSmart1 Full 0.5592178 0.5718510 124.790868 0.9779082 0.3300117
SexMale2 Full -0.6684056 0.3542391 124.254186 -1.8868770 0.0615103
RegionLuxembourg2 Full 0.3129471 1.2145570 8.903706 0.2576636 0.8025228
Infos_TT_pupation_OP <- "
Mâle presque significativement plus rapide mais c'est tout
"
Infos_TT_pupation_OP
## [1] "\nMâle presque significativement plus rapide mais c'est tout\n"

6.6 TT_pupation AE

6.6.1 Test

LM_TT_pupation_AE <- lmer(TT_pupation ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_AE)
## boundary (singular) fit: see help('isSingular')
summary(LM_TT_pupation_AE)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: TT_pupation ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data_AE
## 
## REML criterion at convergence: 1233.5
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.6434 -0.6315 -0.1904  0.3115  3.8242 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept)  10.15    3.186  
##  Site     (Intercept)  32.31    5.684  
##  Room     (Intercept)   0.00    0.000  
##  Residual             132.06   11.492  
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                          Estimate Std. Error       df t value
## (Intercept)                               44.2774     3.6308  20.1945  12.195
## Treatment_bisFull                         -3.8390     3.6159 141.0138  -1.062
## Treatment_bisSmart                        -4.1040     4.1892 140.4374  -0.980
## Treatment_bisMixt_smart                   -1.6233     4.2992 141.4031  -0.378
## SexMale                                    0.3753     3.3456 144.8243   0.112
## RegionLuxembourg                           5.3725     4.8686  18.9736   1.104
## Treatment_bisFull:SexMale                  2.5994     4.6580 142.8523   0.558
## Treatment_bisSmart:SexMale                -1.2746     5.6524 147.1038  -0.226
## Treatment_bisMixt_smart:SexMale           -5.9932     5.6222 145.6177  -1.066
## Treatment_bisFull:RegionLuxembourg         5.8975     4.6430 142.3144   1.270
## Treatment_bisSmart:RegionLuxembourg       -6.6351     5.2952 137.6381  -1.253
## Treatment_bisMixt_smart:RegionLuxembourg  13.0384     5.5123 142.4527   2.365
##                                          Pr(>|t|)    
## (Intercept)                              9.02e-11 ***
## Treatment_bisFull                          0.2902    
## Treatment_bisSmart                         0.3289    
## Treatment_bisMixt_smart                    0.7063    
## SexMale                                    0.9108    
## RegionLuxembourg                           0.2836    
## Treatment_bisFull:SexMale                  0.5777    
## Treatment_bisSmart:SexMale                 0.8219    
## Treatment_bisMixt_smart:SexMale            0.2882    
## Treatment_bisFull:RegionLuxembourg         0.2061    
## Treatment_bisSmart:RegionLuxembourg        0.2123    
## Treatment_bisMixt_smart:RegionLuxembourg   0.0194 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_F:SM T_S:SM T_M_:S
## Trtmnt_bsFl -0.475                                                        
## Trtmnt_bsSm -0.409  0.418                                                 
## Trtmnt_bsM_ -0.401  0.407  0.356                                          
## SexMale     -0.357  0.365  0.318  0.316                                   
## ReginLxmbrg -0.634  0.243  0.205  0.199 -0.047                            
## Trtmnt_F:SM  0.252 -0.558 -0.229 -0.229 -0.715  0.031                     
## Trtmnt_S:SM  0.224 -0.222 -0.481 -0.201 -0.596  0.020  0.427              
## Trtmn_M_:SM  0.201 -0.216 -0.193 -0.547 -0.606  0.042  0.435  0.375       
## Trtmnt_F:RL  0.259 -0.532 -0.221 -0.211  0.031 -0.487 -0.007 -0.024 -0.032
## Trtmnt_S:RL  0.217 -0.224 -0.584 -0.184  0.035 -0.416 -0.026 -0.047 -0.029
## Trtmn_M_:RL  0.219 -0.214 -0.176 -0.515  0.035 -0.411 -0.029 -0.044 -0.056
##             T_F:RL T_S:RL
## Trtmnt_bsFl              
## Trtmnt_bsSm              
## Trtmnt_bsM_              
## SexMale                  
## ReginLxmbrg              
## Trtmnt_F:SM              
## Trtmnt_S:SM              
## Trtmn_M_:SM              
## Trtmnt_F:RL              
## Trtmnt_S:RL  0.445       
## Trtmn_M_:RL  0.445  0.375
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Normalité des résidus

qqnorm(resid(LM_TT_pupation_AE))
qqline(resid(LM_TT_pupation_AE))

on va changer les variables pour la normlité

LM_TT_pupation_AE <- lmer(log(TT_pupation) ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_AE)
summary(LM_TT_pupation_AE)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(TT_pupation) ~ Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data_AE
## 
## REML criterion at convergence: 26.7
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.7522 -0.7113 -0.1251  0.4975  3.5229 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 4.035e-03 6.352e-02
##  Site     (Intercept) 1.596e-02 1.263e-01
##  Room     (Intercept) 1.683e-09 4.102e-05
##  Residual             4.880e-02 2.209e-01
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                                3.727700   0.074789  18.913487
## Treatment_bisFull                         -0.049799   0.069570 140.897669
## Treatment_bisSmart                        -0.063499   0.080609 140.306436
## Treatment_bisMixt_smart                   -0.003782   0.082723 141.208570
## SexMale                                    0.014702   0.064452 144.202865
## RegionLuxembourg                           0.137796   0.100542  17.888419
## Treatment_bisFull:SexMale                  0.047749   0.089669 142.395943
## Treatment_bisSmart:SexMale                -0.025900   0.108948 146.299619
## Treatment_bisMixt_smart:SexMale           -0.121506   0.108356 144.782853
## Treatment_bisFull:RegionLuxembourg         0.087540   0.089382 142.002105
## Treatment_bisSmart:RegionLuxembourg       -0.154330   0.101842 137.807876
## Treatment_bisMixt_smart:RegionLuxembourg   0.241384   0.106128 142.084559
##                                          t value Pr(>|t|)    
## (Intercept)                               49.843   <2e-16 ***
## Treatment_bisFull                         -0.716   0.4753    
## Treatment_bisSmart                        -0.788   0.4322    
## Treatment_bisMixt_smart                   -0.046   0.9636    
## SexMale                                    0.228   0.8199    
## RegionLuxembourg                           1.371   0.1875    
## Treatment_bisFull:SexMale                  0.533   0.5952    
## Treatment_bisSmart:SexMale                -0.238   0.8124    
## Treatment_bisMixt_smart:SexMale           -1.121   0.2640    
## Treatment_bisFull:RegionLuxembourg         0.979   0.3291    
## Treatment_bisSmart:RegionLuxembourg       -1.515   0.1320    
## Treatment_bisMixt_smart:RegionLuxembourg   2.274   0.0244 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_F:SM T_S:SM T_M_:S
## Trtmnt_bsFl -0.444                                                        
## Trtmnt_bsSm -0.382  0.419                                                 
## Trtmnt_bsM_ -0.374  0.407  0.356                                          
## SexMale     -0.332  0.364  0.318  0.317                                   
## ReginLxmbrg -0.647  0.227  0.192  0.185 -0.045                            
## Trtmnt_F:SM  0.234 -0.558 -0.229 -0.229 -0.715  0.029                     
## Trtmnt_S:SM  0.210 -0.223 -0.482 -0.202 -0.595  0.017  0.427              
## Trtmn_M_:SM  0.186 -0.215 -0.193 -0.547 -0.606  0.041  0.435  0.376       
## Trtmnt_F:RL  0.243 -0.532 -0.221 -0.211  0.030 -0.454 -0.007 -0.024 -0.033
## Trtmnt_S:RL  0.202 -0.224 -0.583 -0.184  0.035 -0.388 -0.026 -0.047 -0.030
## Trtmn_M_:RL  0.205 -0.214 -0.175 -0.514  0.035 -0.383 -0.029 -0.045 -0.057
##             T_F:RL T_S:RL
## Trtmnt_bsFl              
## Trtmnt_bsSm              
## Trtmnt_bsM_              
## SexMale                  
## ReginLxmbrg              
## Trtmnt_F:SM              
## Trtmnt_S:SM              
## Trtmn_M_:SM              
## Trtmnt_F:RL              
## Trtmnt_S:RL  0.446       
## Trtmn_M_:RL  0.446  0.375

Normalité des résidus

qqnorm(resid(LM_TT_pupation_AE))
qqline(resid(LM_TT_pupation_AE))

On a vu mieux mais c’est passable

Homogénité des variances

plot(LM_TT_pupation_AE)

Distance de cook

plot(cooks.distance(LM_TT_pupation_AE))

6.6.2 Simplification du modèle

drop1(LM_TT_pupation_AE)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(TT_pupation) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##                       Sum Sq  Mean Sq NumDF  DenDF F value   Pr(>F)   
## Treatment_bis:Sex    0.12547 0.041825     3 144.43  0.8571 0.464989   
## Treatment_bis:Region 0.60784 0.202612     3 139.47  4.1521 0.007475 **
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_TT_pupation1_AE <- update(LM_TT_pupation_AE, . ~ . - Treatment_bis:Sex)
## boundary (singular) fit: see help('isSingular')
drop1(LM_TT_pupation1_AE)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(TT_pupation) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region
##                       Sum Sq Mean Sq NumDF  DenDF F value   Pr(>F)   
## Sex                  0.00086 0.00086     1 147.53  0.0178 0.894088   
## Treatment_bis:Region 0.59337 0.19779     3 142.36  4.0906 0.008054 **
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

On a plus d’interactions, nous pouvons nous arrêter ici

LM_TT_pupation_AE <- LM_TT_pupation1_AE

6.6.3 Treatment VS Treatment_bis

AIC(lmer(log(TT_pupation) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE))
## boundary (singular) fit: see help('isSingular')
## [1] 46.57387
AIC(lmer(log(TT_pupation) ~ Treatment + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment:Region, data = Data_AE))
## [1] 55.09817
summary(lmer(log(TT_pupation) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE))$coeff
## boundary (singular) fit: see help('isSingular')
##                                              Estimate Std. Error        df
## (Intercept)                               3.730223205 0.07267785  15.92756
## Treatment_bisFull                        -0.025346748 0.05742573 141.05583
## Treatment_bisSmart                       -0.071769793 0.07028877 140.34241
## Treatment_bisMixt_smart                  -0.055765049 0.06896240 142.48142
## SexMale                                   0.004833461 0.03624287 147.53480
## RegionLuxembourg                          0.141065196 0.10142588  17.48479
## Treatment_bisFull:RegionLuxembourg        0.083329462 0.08899521 144.91426
## Treatment_bisSmart:RegionLuxembourg      -0.156870585 0.10129398 140.77135
## Treatment_bisMixt_smart:RegionLuxembourg  0.234981708 0.10553265 144.89788
##                                             t value     Pr(>|t|)
## (Intercept)                              51.3254449 4.041975e-19
## Treatment_bisFull                        -0.4413831 6.596115e-01
## Treatment_bisSmart                       -1.0210706 3.089779e-01
## Treatment_bisMixt_smart                  -0.8086298 4.200763e-01
## SexMale                                   0.1333631 8.940880e-01
## RegionLuxembourg                          1.3908205 1.817283e-01
## Treatment_bisFull:RegionLuxembourg        0.9363365 3.506578e-01
## Treatment_bisSmart:RegionLuxembourg      -1.5486664 1.237072e-01
## Treatment_bisMixt_smart:RegionLuxembourg  2.2266257 2.751530e-02
summary(lmer(log(TT_pupation) ~ Treatment + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment:Region, data = Data_AE))$coeff
##                                     Estimate Std. Error         df    t value
## (Intercept)                      3.727275648 0.08231733   7.972213 45.2793573
## TreatmentFull                   -0.030251953 0.06068200 142.616997 -0.4985326
## TreatmentSmart                  -0.067656742 0.06032158 144.162915 -1.1216010
## SexMale                          0.016566041 0.03808825 149.267773  0.4349383
## RegionLuxembourg                 0.148222348 0.09964665  19.036282  1.4874795
## TreatmentFull:RegionLuxembourg   0.077130107 0.09391471 146.616611  0.8212783
## TreatmentSmart:RegionLuxembourg  0.009738645 0.09026273 145.003643  0.1078922
##                                     Pr(>|t|)
## (Intercept)                     6.669934e-11
## TreatmentFull                   6.188767e-01
## TreatmentSmart                  2.638968e-01
## SexMale                         6.642354e-01
## RegionLuxembourg                1.532657e-01
## TreatmentFull:RegionLuxembourg  4.128212e-01
## TreatmentSmart:RegionLuxembourg 9.142303e-01

Treatment_bis est mieux mais il y a aucune différence significatives

6.6.4 Résultats

Analyse des P-val

summary(lmer(log(TT_pupation) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(TT_pupation) ~ Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_AE
## 
## REML criterion at convergence: 20.6
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.7966 -0.7170 -0.1319  0.4654  3.4962 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.004651 0.0682  
##  Site     (Intercept) 0.016315 0.1277  
##  Room     (Intercept) 0.000000 0.0000  
##  Residual             0.048352 0.2199  
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                                3.730223   0.072678  15.927558
## Treatment_bisFull                         -0.025347   0.057426 141.055825
## Treatment_bisSmart                        -0.071770   0.070289 140.342406
## Treatment_bisMixt_smart                   -0.055765   0.068962 142.481416
## SexMale                                    0.004833   0.036243 147.534799
## RegionLuxembourg                           0.141065   0.101426  17.484790
## Treatment_bisFull:RegionLuxembourg         0.083329   0.088995 144.914259
## Treatment_bisSmart:RegionLuxembourg       -0.156871   0.101294 140.771354
## Treatment_bisMixt_smart:RegionLuxembourg   0.234982   0.105533 144.897884
##                                          t value Pr(>|t|)    
## (Intercept)                               51.325   <2e-16 ***
## Treatment_bisFull                         -0.441   0.6596    
## Treatment_bisSmart                        -1.021   0.3090    
## Treatment_bisMixt_smart                   -0.809   0.4201    
## SexMale                                    0.133   0.8941    
## RegionLuxembourg                           1.391   0.1817    
## Treatment_bisFull:RegionLuxembourg         0.936   0.3507    
## Treatment_bisSmart:RegionLuxembourg       -1.549   0.1237    
## Treatment_bisMixt_smart:RegionLuxembourg   2.227   0.0275 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_F:RL T_S:RL
## Trtmnt_bsFl -0.391                                                 
## Trtmnt_bsSm -0.323  0.411                                          
## Trtmnt_bsM_ -0.335  0.425  0.345                                   
## SexMale     -0.198 -0.047  0.035 -0.021                            
## ReginLxmbrg -0.684  0.288  0.226  0.244 -0.024                     
## Trtmnt_F:RL  0.255 -0.645 -0.266 -0.274  0.018 -0.447              
## Trtmnt_S:RL  0.219 -0.287 -0.693 -0.240  0.001 -0.382  0.445       
## Trtmn_M_:RL  0.225 -0.277 -0.226 -0.653 -0.016 -0.376  0.446  0.374
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(TT_pupation) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE_ref_full))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(TT_pupation) ~ Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_AE_ref_full
## 
## REML criterion at convergence: 20.6
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.7966 -0.7170 -0.1319  0.4654  3.4962 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.004651 0.0682  
##  Site     (Intercept) 0.016315 0.1277  
##  Room     (Intercept) 0.000000 0.0000  
##  Residual             0.048352 0.2199  
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                                3.704876   0.072897  16.458332
## Treatment_bisDark                          0.025347   0.057426 141.055825
## Treatment_bisSmart                        -0.046423   0.070124 138.684052
## Treatment_bisMixt_smart                   -0.030418   0.068443 139.646914
## SexMale                                    0.004833   0.036243 147.534799
## RegionLuxembourg                           0.224395   0.100684  17.426481
## Treatment_bisDark:RegionLuxembourg        -0.083329   0.088995 144.914259
## Treatment_bisSmart:RegionLuxembourg       -0.240200   0.100750 140.268830
## Treatment_bisMixt_smart:RegionLuxembourg   0.151652   0.103368 141.401768
##                                          t value Pr(>|t|)    
## (Intercept)                               50.823   <2e-16 ***
## Treatment_bisDark                          0.441   0.6596    
## Treatment_bisSmart                        -0.662   0.5091    
## Treatment_bisMixt_smart                   -0.444   0.6574    
## SexMale                                    0.133   0.8941    
## RegionLuxembourg                           2.229   0.0393 *  
## Treatment_bisDark:RegionLuxembourg        -0.936   0.3507    
## Treatment_bisSmart:RegionLuxembourg       -2.384   0.0185 *  
## Treatment_bisMixt_smart:RegionLuxembourg   1.467   0.1446    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S Trt_M_ SexMal RgnLxm T_D:RL T_S:RL
## Trtmnt_bsDr -0.398                                                 
## Trtmnt_bsSm -0.324  0.407                                          
## Trtmnt_bsM_ -0.333  0.410  0.338                                   
## SexMale     -0.234  0.047  0.073  0.018                            
## ReginLxmbrg -0.682  0.280  0.222  0.238 -0.009                     
## Trtmnt_D:RL  0.254 -0.645 -0.261 -0.265 -0.018 -0.434              
## Trtmnt_S:RL  0.217 -0.281 -0.693 -0.235 -0.015 -0.374  0.436       
## Trtmn_M_:RL  0.225 -0.273 -0.225 -0.662 -0.032 -0.358  0.406  0.357
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(TT_pupation) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE_ref_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(TT_pupation) ~ Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_AE_ref_smart
## 
## REML criterion at convergence: 20.6
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.7966 -0.7170 -0.1319  0.4654  3.4962 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.004651 0.0682  
##  Site     (Intercept) 0.016315 0.1277  
##  Room     (Intercept) 0.000000 0.0000  
##  Residual             0.048352 0.2199  
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                                3.658453   0.083180  26.780046
## Treatment_bisDark                          0.071770   0.070289 140.342406
## Treatment_bisFull                          0.046423   0.070124 138.684052
## Treatment_bisMixt_smart                    0.016005   0.079726 139.234651
## SexMale                                    0.004833   0.036243 147.534799
## RegionLuxembourg                          -0.015805   0.112663  26.449320
## Treatment_bisDark:RegionLuxembourg         0.156871   0.101294 140.771354
## Treatment_bisFull:RegionLuxembourg         0.240200   0.100750 140.268830
## Treatment_bisMixt_smart:RegionLuxembourg   0.391852   0.115762 141.419410
##                                          t value Pr(>|t|)    
## (Intercept)                               43.982  < 2e-16 ***
## Treatment_bisDark                          1.021 0.308978    
## Treatment_bisFull                          0.662 0.509059    
## Treatment_bisMixt_smart                    0.201 0.841190    
## SexMale                                    0.133 0.894088    
## RegionLuxembourg                          -0.140 0.889495    
## Treatment_bisDark:RegionLuxembourg         1.549 0.123707    
## Treatment_bisFull:RegionLuxembourg         2.384 0.018459 *  
## Treatment_bisMixt_smart:RegionLuxembourg   3.385 0.000922 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trt_M_ SexMal RgnLxm T_D:RL T_F:RL
## Trtmnt_bsDr -0.562                                                 
## Trtmnt_bsFl -0.559  0.665                                          
## Trtmnt_bsM_ -0.497  0.584  0.589                                   
## SexMale     -0.143 -0.035 -0.073 -0.049                            
## ReginLxmbrg -0.720  0.420  0.422  0.373 -0.021                     
## Trtmnt_D:RL  0.394 -0.693 -0.460 -0.404 -0.001 -0.555              
## Trtmnt_F:RL  0.394 -0.462 -0.693 -0.408  0.015 -0.560  0.612       
## Trtmn_M_:RL  0.350 -0.400 -0.402 -0.686 -0.016 -0.488  0.534  0.552
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(TT_pupation) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE_ref_mixt_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(TT_pupation) ~ Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_AE_ref_mixt_smart
## 
## REML criterion at convergence: 20.6
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.7966 -0.7170 -0.1319  0.4654  3.4962 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.004651 0.0682  
##  Site     (Intercept) 0.016315 0.1277  
##  Room     (Intercept) 0.000000 0.0000  
##  Residual             0.048352 0.2199  
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                       Estimate Std. Error         df t value
## (Intercept)                           3.674458   0.081727  25.792872  44.960
## Treatment_bisDark                     0.055765   0.068962 142.481416   0.809
## Treatment_bisFull                     0.030418   0.068443 139.646914   0.444
## Treatment_bisSmart                   -0.016005   0.079726 139.234651  -0.201
## SexMale                               0.004833   0.036243 147.534799   0.133
## RegionLuxembourg                      0.376047   0.115644  28.846394   3.252
## Treatment_bisDark:RegionLuxembourg   -0.234982   0.105533 144.897884  -2.227
## Treatment_bisFull:RegionLuxembourg   -0.151652   0.103368 141.401768  -1.467
## Treatment_bisSmart:RegionLuxembourg  -0.391852   0.115762 141.419410  -3.385
##                                     Pr(>|t|)    
## (Intercept)                          < 2e-16 ***
## Treatment_bisDark                   0.420076    
## Treatment_bisFull                   0.657419    
## Treatment_bisSmart                  0.841190    
## SexMale                             0.894088    
## RegionLuxembourg                    0.002918 ** 
## Treatment_bisDark:RegionLuxembourg  0.027515 *  
## Treatment_bisFull:RegionLuxembourg  0.144566    
## Treatment_bisSmart:RegionLuxembourg 0.000922 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trtm_S SexMal RgnLxm T_D:RL T_F:RL
## Trtmnt_bsDr -0.546                                                 
## Trtmnt_bsFl -0.541  0.651                                          
## Trtmnt_bsSm -0.469  0.561  0.561                                   
## SexMale     -0.194  0.021 -0.018  0.049                            
## ReginLxmbrg -0.673  0.382  0.385  0.323 -0.036                     
## Trtmnt_D:RL  0.351 -0.653 -0.426 -0.365  0.016 -0.583              
## Trtmnt_F:RL  0.354 -0.430 -0.662 -0.371  0.032 -0.582  0.637       
## Trtmnt_S:RL  0.314 -0.385 -0.387 -0.686  0.016 -0.526  0.584  0.582
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
test1 <- data.frame(Reference = "Dark", as.data.frame(( summary(lmer(log(TT_pupation) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test2 <- data.frame(Reference = "Smart", as.data.frame(( summary(lmer(log(TT_pupation) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE_ref_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test3 <- data.frame(Reference = "Full", as.data.frame(( summary(lmer(log(TT_pupation) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE_ref_full))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test4 <- data.frame(Reference = "Mixt_smart", as.data.frame(( summary(lmer(log(TT_pupation) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE_ref_mixt_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
Results_TT_puapation_AE <- rbind(test1,test2,test3, test4)

colnames(Results_TT_puapation_AE ) <- c("Reference","Estimate", "Std. Error", "df", "t.value", "Pr(>|z|)")

write.csv2( Results_TT_puapation_AE , file = "output/Results_TT_puapation_AE.csv" )

kable(Results_TT_puapation_AE , caption = " Temps pour entrer en chrysalide AE ", padding = 1 )
Temps pour entrer en chrysalide AE
Reference Estimate Std. Error df t.value Pr(>|z|)
(Intercept) Dark 3.7302232 0.0726779 15.92756 51.3254449 0.0000000
Treatment_bisFull Dark -0.0253467 0.0574257 141.05583 -0.4413831 0.6596115
Treatment_bisSmart Dark -0.0717698 0.0702888 140.34241 -1.0210706 0.3089779
Treatment_bisMixt_smart Dark -0.0557650 0.0689624 142.48142 -0.8086298 0.4200763
SexMale Dark 0.0048335 0.0362429 147.53480 0.1333631 0.8940880
RegionLuxembourg Dark 0.1410652 0.1014259 17.48479 1.3908205 0.1817283
Treatment_bisFull:RegionLuxembourg Dark 0.0833295 0.0889952 144.91426 0.9363365 0.3506578
Treatment_bisSmart:RegionLuxembourg Dark -0.1568706 0.1012940 140.77135 -1.5486664 0.1237072
Treatment_bisMixt_smart:RegionLuxembourg Dark 0.2349817 0.1055326 144.89788 2.2266257 0.0275153
(Intercept)1 Smart 3.6584534 0.0831800 26.78005 43.9823472 0.0000000
Treatment_bisDark Smart 0.0717698 0.0702888 140.34241 1.0210706 0.3089779
Treatment_bisFull1 Smart 0.0464230 0.0701237 138.68405 0.6620167 0.5090591
Treatment_bisMixt_smart1 Smart 0.0160047 0.0797264 139.23465 0.2007459 0.8411902
SexMale1 Smart 0.0048335 0.0362429 147.53480 0.1333631 0.8940880
RegionLuxembourg1 Smart -0.0158054 0.1126633 26.44932 -0.1402887 0.8894948
Treatment_bisDark:RegionLuxembourg Smart 0.1568706 0.1012940 140.77135 1.5486664 0.1237072
Treatment_bisFull:RegionLuxembourg1 Smart 0.2402000 0.1007504 140.26883 2.3841095 0.0184588
Treatment_bisMixt_smart:RegionLuxembourg1 Smart 0.3918523 0.1157621 141.41941 3.3849784 0.0009215
(Intercept)2 Full 3.7048765 0.0728969 16.45833 50.8234938 0.0000000
Treatment_bisDark1 Full 0.0253467 0.0574257 141.05583 0.4413831 0.6596115
Treatment_bisSmart1 Full -0.0464230 0.0701237 138.68405 -0.6620167 0.5090591
Treatment_bisMixt_smart2 Full -0.0304183 0.0684432 139.64691 -0.4444316 0.6574186
SexMale2 Full 0.0048335 0.0362429 147.53480 0.1333631 0.8940880
RegionLuxembourg2 Full 0.2243947 0.1006837 17.42648 2.2287087 0.0392648
Treatment_bisDark:RegionLuxembourg1 Full -0.0833295 0.0889952 144.91426 -0.9363365 0.3506578
Treatment_bisSmart:RegionLuxembourg1 Full -0.2402000 0.1007504 140.26883 -2.3841095 0.0184588
Treatment_bisMixt_smart:RegionLuxembourg2 Full 0.1516522 0.1033678 141.40177 1.4671126 0.1445661
(Intercept)3 Mixt_smart 3.6744582 0.0817268 25.79287 44.9602738 0.0000000
Treatment_bisDark2 Mixt_smart 0.0557650 0.0689624 142.48142 0.8086298 0.4200763
Treatment_bisFull2 Mixt_smart 0.0304183 0.0684432 139.64691 0.4444316 0.6574186
Treatment_bisSmart2 Mixt_smart -0.0160047 0.0797264 139.23465 -0.2007459 0.8411902
SexMale3 Mixt_smart 0.0048335 0.0362429 147.53480 0.1333631 0.8940880
RegionLuxembourg3 Mixt_smart 0.3760469 0.1156445 28.84639 3.2517495 0.0029183
Treatment_bisDark:RegionLuxembourg2 Mixt_smart -0.2349817 0.1055326 144.89788 -2.2266257 0.0275153
Treatment_bisFull:RegionLuxembourg2 Mixt_smart -0.1516522 0.1033678 141.40177 -1.4671126 0.1445661
Treatment_bisSmart:RegionLuxembourg2 Mixt_smart -0.3918523 0.1157621 141.41941 -3.3849784 0.0009215
Infos_TT_pupation_AE <- "

Le traitement Mixt-smart en région luxembourgoise est significativement plus lent que l'effet de la région luxembourgeoise et du traitement mixt-smart additionné sauf quand on le compare au traitement full où là, la région luxembourg est elle même significativement plus lent
Le traitement Smart en région luxembourgeoise est significativement plus rapide que l'effet de la région luxembourgeoise et du traitement smart additioné quand il est comparé au traitement full.
"
Infos_TT_pupation_AE
## [1] "\n\nLe traitement Mixt-smart en région luxembourgoise est significativement plus lent que l'effet de la région luxembourgeoise et du traitement mixt-smart additionné sauf quand on le compare au traitement full où là, la région luxembourg est elle même significativement plus lent\nLe traitement Smart en région luxembourgeoise est significativement plus rapide que l'effet de la région luxembourgeoise et du traitement smart additioné quand il est comparé au traitement full.\n"

6.7 Time_in_pupa OP

6.7.1 Test

LM_Time_in_pupa_OP <- lmer(Time_in_pupa ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_OP)
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## unable to evaluate scaled gradient
## Warning in checkConv(attr(opt, "derivs"), opt$par, ctrl = control$checkConv, :
## Model failed to converge: degenerate Hessian with 1 negative eigenvalues
## Warning: Model failed to converge with 1 negative eigenvalue: -1.5e+00
summary(LM_TT_pupation_OP)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: TT_pupation ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room)
##    Data: Data_OP
## 
## REML criterion at convergence: 610.8
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.3490 -0.5984 -0.1176  0.5181  2.6717 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 3.961    1.990   
##  Site     (Intercept) 0.000    0.000   
##  Room     (Intercept) 0.000    0.000   
##  Residual             4.092    2.023   
## Number of obs: 139, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                    Estimate Std. Error       df t value Pr(>|t|)    
## (Intercept)         14.8358     0.8848   9.9935  16.768  1.2e-08 ***
## Treatment_bisFull   -0.1726     0.3832 123.9073  -0.450   0.6533    
## Treatment_bisSmart   0.3867     0.5527 124.8872   0.700   0.4855    
## SexMale             -0.6684     0.3542 124.2542  -1.887   0.0615 .  
## RegionLuxembourg     0.3129     1.2146   8.9037   0.258   0.8025    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S SexMal
## Trtmnt_bsFl -0.151                     
## Trtmnt_bsSm -0.086  0.296              
## SexMale     -0.144 -0.134 -0.089       
## ReginLxmbrg -0.686 -0.014 -0.043  0.004
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Vérification de la normalité

qqnorm(resid(LM_Time_in_pupa_OP))
qqline(resid(LM_Time_in_pupa_OP))

Je pense que cela est suffisemment bon

Homogénité des variances

plot(LM_Time_in_pupa_OP)

Distance de cook

plot(cooks.distance(LM_Time_in_pupa_OP))

6.7.2 Simplification du modèle

drop1(LM_Time_in_pupa_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##                       Sum Sq  Mean Sq NumDF DenDF F value Pr(>F)
## Treatment_bis:Sex    0.30299 0.151496     2 105.6  0.1693 0.8445
## Treatment_bis:Region 0.15798 0.078991     2 104.1  0.0883 0.9156
LM_Time_in_pupa1_OP <- update(LM_Time_in_pupa_OP, . ~ . - Treatment_bis:Region)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Time_in_pupa1_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex
##                    Sum Sq Mean Sq NumDF   DenDF F value Pr(>F)
## Region            0.77601 0.77601     1   7.652  0.8840 0.3758
## Treatment_bis:Sex 0.26920 0.13460     2 107.238  0.1533 0.8580
LM_Time_in_pupa2_OP <- update(LM_Time_in_pupa1_OP, . ~ . - Treatment_bis:Sex)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Time_in_pupa2_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room)
##               Sum Sq Mean Sq NumDF  DenDF F value Pr(>F)  
## Treatment_bis 4.3408  2.1704     2 108.30  2.5110 0.0859 .
## Sex           5.3431  5.3431     1 110.65  6.1817 0.0144 *
## Region        0.7657  0.7657     1   7.79  0.8859 0.3748  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Nous n’avons plus d’interactions, nous nous arrêtons là.

Regardons si les simplifications étaient utiles

AIC(LM_Time_in_pupa2_OP)
## [1] 363.8339
AIC(LM_Time_in_pupa_OP)
## [1] 370.4407

Les simplifications étaient utiles

LM_Time_in_pupa_OP <- LM_Time_in_pupa2_OP

6.7.3 Treatment VS Treatment_bis

AIC(lmer(Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room), data = Data_OP))
## boundary (singular) fit: see help('isSingular')
## [1] 363.8339
AIC(lmer(Time_in_pupa ~ Treatment + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room), data = Data_OP))
## boundary (singular) fit: see help('isSingular')
## [1] 366.1591
summary(lmer(Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room), data = Data_OP))$coeff
## boundary (singular) fit: see help('isSingular')
##                      Estimate Std. Error         df    t value     Pr(>|t|)
## (Intercept)        13.1595521  0.2712871  10.642247 48.5078417 7.812250e-14
## Treatment_bisFull   0.1938076  0.1874238 107.589573  1.0340608 3.034265e-01
## Treatment_bisSmart -0.4176188  0.2714114 109.458784 -1.5386928 1.267652e-01
## SexMale             0.4377398  0.1760601 110.646314  2.4863097 1.440167e-02
## RegionLuxembourg   -0.3346356  0.3555258   7.790118 -0.9412416 3.748476e-01
summary(lmer(Time_in_pupa ~ Treatment + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room), data = Data_OP))$coeff
## boundary (singular) fit: see help('isSingular')
##                      Estimate Std. Error         df     t value     Pr(>|t|)
## (Intercept)      13.080301905  0.3050927  11.324364 42.87320555 6.853904e-14
## TreatmentFull     0.293937176  0.2106132 105.368043  1.39562577 1.657613e-01
## TreatmentSmart    0.003233417  0.2178996 106.724953  0.01483903 9.881883e-01
## SexMale           0.427762682  0.1770008 110.669123  2.41672675 1.729567e-02
## RegionLuxembourg -0.360048801  0.3489861   7.580957 -1.03169961 3.339998e-01

Selon les summary le choix de treatment ou treatment_bis est discutable mais on peut alors se pencher sur l’AIC qui nous encourage à prendre treatment_bis.

6.7.4 Résultats

Analysons les P-val

summary(LM_Time_in_pupa_OP)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room)
##    Data: Data_OP
## 
## REML criterion at convergence: 345.8
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.78449 -0.67249  0.02252  0.43274  3.10875 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 2.736e-01 5.231e-01
##  Site     (Intercept) 0.000e+00 0.000e+00
##  Room     (Intercept) 1.121e-09 3.349e-05
##  Residual             8.643e-01 9.297e-01
## Number of obs: 122, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                    Estimate Std. Error       df t value Pr(>|t|)    
## (Intercept)         13.1596     0.2713  10.6422  48.508 7.81e-14 ***
## Treatment_bisFull    0.1938     0.1874 107.5896   1.034   0.3034    
## Treatment_bisSmart  -0.4176     0.2714 109.4588  -1.539   0.1268    
## SexMale              0.4377     0.1761 110.6463   2.486   0.0144 *  
## RegionLuxembourg    -0.3346     0.3555   7.7901  -0.941   0.3748    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S SexMal
## Trtmnt_bsFl -0.227                     
## Trtmnt_bsSm -0.135  0.328              
## SexMale     -0.239 -0.172 -0.136       
## ReginLxmbrg -0.647 -0.048 -0.069  0.030
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room), data = Data_OP_ref_full))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room)
##    Data: Data_OP_ref_full
## 
## REML criterion at convergence: 345.8
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.78449 -0.67249  0.02252  0.43274  3.10875 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 2.736e-01 5.231e-01
##  Site     (Intercept) 0.000e+00 0.000e+00
##  Room     (Intercept) 1.121e-09 3.349e-05
##  Residual             8.643e-01 9.297e-01
## Number of obs: 122, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                    Estimate Std. Error       df t value Pr(>|t|)    
## (Intercept)         13.3534     0.2926  14.5443  45.629   <2e-16 ***
## Treatment_bisDark   -0.1938     0.1874 107.5896  -1.034   0.3034    
## Treatment_bisSmart  -0.6114     0.2746 108.2893  -2.227   0.0280 *  
## SexMale              0.4377     0.1761 110.6463   2.486   0.0144 *  
## RegionLuxembourg    -0.3346     0.3555   7.7901  -0.941   0.3748    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S SexMal
## Trtmnt_bsDr -0.430                     
## Trtmnt_bsSm -0.209  0.358              
## SexMale     -0.332  0.172 -0.017       
## ReginLxmbrg -0.631  0.048 -0.035  0.030
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) , data = Data_OP_ref_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room)
##    Data: Data_OP_ref_smart
## 
## REML criterion at convergence: 345.8
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.78449 -0.67249  0.02252  0.43274  3.10875 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 2.736e-01 5.231e-01
##  Site     (Intercept) 0.000e+00 0.000e+00
##  Room     (Intercept) 1.121e-09 3.349e-05
##  Residual             8.643e-01 9.297e-01
## Number of obs: 122, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                   Estimate Std. Error       df t value Pr(>|t|)    
## (Intercept)        12.7419     0.3570  29.1673  35.696   <2e-16 ***
## Treatment_bisDark   0.4176     0.2714 109.4587   1.539   0.1268    
## Treatment_bisFull   0.6114     0.2746 108.2893   2.227   0.0280 *  
## SexMale             0.4377     0.1761 110.6463   2.486   0.0144 *  
## RegionLuxembourg   -0.3346     0.3555   7.7901  -0.941   0.3748    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F SexMal
## Trtmnt_bsDr -0.658                     
## Trtmnt_bsFl -0.598  0.764              
## SexMale     -0.285  0.136  0.017       
## ReginLxmbrg -0.544  0.069  0.035  0.030
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
test1 <- data.frame(Reference = "Dark", as.data.frame(( summary(LM_Time_in_pupa_OP)$coeff)[,]))

test2 <- data.frame(Reference = "Smart", as.data.frame(( summary(lmer(Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) , data = Data_OP_ref_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test3 <- data.frame(Reference = "Full", as.data.frame(( summary(lmer(Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room), data = Data_OP_ref_full))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
Results_Time_in_pupa_OP <- rbind(test1,test2,test3)

colnames(Results_Time_in_pupa_OP ) <- c("Reference","Estimate", "Std. Error", "df", "t.value", "Pr(>|z|)")

write.csv2( Results_Time_in_pupa_OP , file = "output/Results_Time_in_pupa_OP.csv" )

kable(Results_Time_in_pupa_OP , caption = " Temps en chrysalide OP ", padding = 1 )
Temps en chrysalide OP
Reference Estimate Std. Error df t.value Pr(>|z|)
(Intercept) Dark 13.1595521 0.2712871 10.642247 48.5078417 0.0000000
Treatment_bisFull Dark 0.1938076 0.1874238 107.589573 1.0340608 0.3034265
Treatment_bisSmart Dark -0.4176188 0.2714114 109.458784 -1.5386928 0.1267652
SexMale Dark 0.4377398 0.1760601 110.646314 2.4863097 0.0144017
RegionLuxembourg Dark -0.3346356 0.3555258 7.790118 -0.9412416 0.3748476
(Intercept)1 Smart 12.7419333 0.3569619 29.167327 35.6955006 0.0000000
Treatment_bisDark Smart 0.4176188 0.2714114 109.458746 1.5386928 0.1267652
Treatment_bisFull1 Smart 0.6114264 0.2745973 108.289262 2.2266295 0.0280420
SexMale1 Smart 0.4377398 0.1760601 110.646314 2.4863097 0.0144017
RegionLuxembourg1 Smart -0.3346356 0.3555258 7.790118 -0.9412416 0.3748476
(Intercept)2 Full 13.3533597 0.2926481 14.544267 45.6294128 0.0000000
Treatment_bisDark1 Full -0.1938076 0.1874238 107.589572 -1.0340608 0.3034265
Treatment_bisSmart1 Full -0.6114264 0.2745973 108.289262 -2.2266295 0.0280420
SexMale2 Full 0.4377398 0.1760601 110.646314 2.4863097 0.0144017
RegionLuxembourg2 Full -0.3346356 0.3555258 7.790118 -0.9412416 0.3748476
Info_time_in_pupa_OP <- "
Les mâmes passent significativement (0.0144) plus de temps (0.44 jours) en chrysaldie
Les individus du traitement Smart passent significativement (0.0280) moins de temps (0.61 jours) en chrysalide que les individus du traitement Full.
"
Info_time_in_pupa_OP
## [1] "\nLes mâmes passent significativement (0.0144) plus de temps (0.44 jours) en chrysaldie\nLes individus du traitement Smart passent significativement (0.0280) moins de temps (0.61 jours) en chrysalide que les individus du traitement Full.\n"

6.8 Time_in_pupa AE

6.8.1 Test

LM_Time_in_pupa_AE <- lmer(Time_in_pupa ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_AE)
## boundary (singular) fit: see help('isSingular')
summary(LM_TT_pupation_AE)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(TT_pupation) ~ Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_AE
## 
## REML criterion at convergence: 20.6
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.7966 -0.7170 -0.1319  0.4654  3.4962 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.004651 0.0682  
##  Site     (Intercept) 0.016315 0.1277  
##  Room     (Intercept) 0.000000 0.0000  
##  Residual             0.048352 0.2199  
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                                3.730223   0.072678  15.927558
## Treatment_bisFull                         -0.025347   0.057426 141.055825
## Treatment_bisSmart                        -0.071770   0.070289 140.342406
## Treatment_bisMixt_smart                   -0.055765   0.068962 142.481416
## SexMale                                    0.004833   0.036243 147.534799
## RegionLuxembourg                           0.141065   0.101426  17.484790
## Treatment_bisFull:RegionLuxembourg         0.083329   0.088995 144.914259
## Treatment_bisSmart:RegionLuxembourg       -0.156871   0.101294 140.771354
## Treatment_bisMixt_smart:RegionLuxembourg   0.234982   0.105533 144.897884
##                                          t value Pr(>|t|)    
## (Intercept)                               51.325   <2e-16 ***
## Treatment_bisFull                         -0.441   0.6596    
## Treatment_bisSmart                        -1.021   0.3090    
## Treatment_bisMixt_smart                   -0.809   0.4201    
## SexMale                                    0.133   0.8941    
## RegionLuxembourg                           1.391   0.1817    
## Treatment_bisFull:RegionLuxembourg         0.936   0.3507    
## Treatment_bisSmart:RegionLuxembourg       -1.549   0.1237    
## Treatment_bisMixt_smart:RegionLuxembourg   2.227   0.0275 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_F:RL T_S:RL
## Trtmnt_bsFl -0.391                                                 
## Trtmnt_bsSm -0.323  0.411                                          
## Trtmnt_bsM_ -0.335  0.425  0.345                                   
## SexMale     -0.198 -0.047  0.035 -0.021                            
## ReginLxmbrg -0.684  0.288  0.226  0.244 -0.024                     
## Trtmnt_F:RL  0.255 -0.645 -0.266 -0.274  0.018 -0.447              
## Trtmnt_S:RL  0.219 -0.287 -0.693 -0.240  0.001 -0.382  0.445       
## Trtmn_M_:RL  0.225 -0.277 -0.226 -0.653 -0.016 -0.376  0.446  0.374
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Vérification de la normalité

qqnorm(resid(LM_Time_in_pupa_AE))
qqline(resid(LM_Time_in_pupa_AE))

Ca a vraiment l’air nickel

Homogénité des variances

plot(LM_Time_in_pupa_AE)

Distance de cook

plot(cooks.distance(LM_Time_in_pupa_AE))

6.8.2 Simplification du modèle

drop1(LM_Time_in_pupa_AE)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##                       Sum Sq Mean Sq NumDF  DenDF F value   Pr(>F)   
## Treatment_bis:Sex     0.0656  0.0219     3 124.14  0.0299 0.993017   
## Treatment_bis:Region 12.3671  4.1224     3 115.36  5.6310 0.001227 **
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Time_in_pupa1_AE <- update(LM_Time_in_pupa_AE, . ~ . - Treatment_bis:Sex)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Time_in_pupa1_AE)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region
##                       Sum Sq Mean Sq NumDF  DenDF F value    Pr(>F)    
## Sex                   8.2058  8.2058     1 125.37  11.457 0.0009512 ***
## Treatment_bis:Region 12.4191  4.1397     3 118.37   5.780 0.0010082 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Le reste est significatif, nous devrions nous arrêter là

Regardons si les simplifications étaient utiles

AIC(LM_Time_in_pupa1_AE)
## [1] 398.363
AIC(LM_Time_in_pupa_AE)
## [1] 404.4193

Les simplifications étaient utiles

LM_Time_in_pupa_AE <- LM_Time_in_pupa1_AE

6.8.3 Treatment VS Treatment_bis

AIC(lmer(Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE))
## boundary (singular) fit: see help('isSingular')
## [1] 398.363
AIC(lmer(Time_in_pupa ~ Treatment + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment:Region, data = Data_AE))
## boundary (singular) fit: see help('isSingular')
## [1] 408.0205
summary(lmer(Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE))$coeff
## boundary (singular) fit: see help('isSingular')
##                                            Estimate Std. Error         df
## (Intercept)                              13.2970982  0.5286168   1.288974
## Treatment_bisFull                         0.6459053  0.2428622 115.687832
## Treatment_bisSmart                        0.5220222  0.3019492 112.881842
## Treatment_bisMixt_smart                   0.3398202  0.2925367 122.350649
## SexMale                                   0.5061546  0.1495354 125.374447
## RegionLuxembourg                          0.3184147  0.2917477  59.901894
## Treatment_bisFull:RegionLuxembourg       -0.7260823  0.3781777 119.272967
## Treatment_bisSmart:RegionLuxembourg      -0.6232444  0.4115138 113.785957
## Treatment_bisMixt_smart:RegionLuxembourg  0.9440774  0.4263108 122.436231
##                                            t value     Pr(>|t|)
## (Intercept)                              25.154512 0.0108038334
## Treatment_bisFull                         2.659554 0.0089340385
## Treatment_bisSmart                        1.728841 0.0865715601
## Treatment_bisMixt_smart                   1.161633 0.2476456996
## SexMale                                   3.384849 0.0009511929
## RegionLuxembourg                          1.091404 0.2794655434
## Treatment_bisFull:RegionLuxembourg       -1.919950 0.0572523089
## Treatment_bisSmart:RegionLuxembourg      -1.514516 0.1326678341
## Treatment_bisMixt_smart:RegionLuxembourg  2.214528 0.0286431504
summary(lmer(Time_in_pupa ~ Treatment + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment:Region, data = Data_AE))$coeff
## boundary (singular) fit: see help('isSingular')
##                                    Estimate Std. Error         df   t value
## (Intercept)                     13.29467258  0.6281464   1.232235 21.164927
## TreatmentFull                    0.63627573  0.2544695 117.358321  2.500401
## TreatmentSmart                   0.40212521  0.2425852 117.534382  1.657666
## SexMale                          0.52225754  0.1561309 128.237643  3.344998
## RegionLuxembourg                 0.35161587  0.3005669  61.537701  1.169842
## TreatmentFull:RegionLuxembourg  -0.72968955  0.3962549 121.447563 -1.841465
## TreatmentSmart:RegionLuxembourg  0.05641089  0.3615016 119.679804  0.156046
##                                    Pr(>|t|)
## (Intercept)                     0.015730646
## TreatmentFull                   0.013785737
## TreatmentSmart                  0.100051653
## SexMale                         0.001079446
## RegionLuxembourg                0.246575418
## TreatmentFull:RegionLuxembourg  0.067993527
## TreatmentSmart:RegionLuxembourg 0.876259651

Il faut garder treatment_bis

6.8.4 Résultats

Analysons les P-val

summary(LM_Time_in_pupa_AE)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_AE
## 
## REML criterion at convergence: 372.4
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.4901 -0.6944 -0.1294  0.7102  2.8173 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.1034   0.3216  
##  Site     (Intercept) 0.0000   0.0000  
##  Room     (Intercept) 0.4739   0.6884  
##  Residual             0.7162   0.8463  
## Number of obs: 141, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                          Estimate Std. Error       df t value
## (Intercept)                               13.2971     0.5286   1.2890  25.155
## Treatment_bisFull                          0.6459     0.2429 115.6878   2.660
## Treatment_bisSmart                         0.5220     0.3019 112.8818   1.729
## Treatment_bisMixt_smart                    0.3398     0.2925 122.3506   1.162
## SexMale                                    0.5062     0.1495 125.3744   3.385
## RegionLuxembourg                           0.3184     0.2917  59.9019   1.091
## Treatment_bisFull:RegionLuxembourg        -0.7261     0.3782 119.2730  -1.920
## Treatment_bisSmart:RegionLuxembourg       -0.6232     0.4115 113.7860  -1.515
## Treatment_bisMixt_smart:RegionLuxembourg   0.9441     0.4263 122.4362   2.215
##                                          Pr(>|t|)    
## (Intercept)                              0.010804 *  
## Treatment_bisFull                        0.008934 ** 
## Treatment_bisSmart                       0.086572 .  
## Treatment_bisMixt_smart                  0.247646    
## SexMale                                  0.000951 ***
## RegionLuxembourg                         0.279466    
## Treatment_bisFull:RegionLuxembourg       0.057252 .  
## Treatment_bisSmart:RegionLuxembourg      0.132668    
## Treatment_bisMixt_smart:RegionLuxembourg 0.028643 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_F:RL T_S:RL
## Trtmnt_bsFl -0.215                                                 
## Trtmnt_bsSm -0.176  0.364                                          
## Trtmnt_bsM_ -0.188  0.422  0.214                                   
## SexMale     -0.123 -0.050  0.059 -0.015                            
## ReginLxmbrg -0.245  0.397  0.335  0.305 -0.009                     
## Trtmnt_F:RL  0.141 -0.640 -0.241 -0.264  0.004 -0.582              
## Trtmnt_S:RL  0.128 -0.275 -0.689 -0.212 -0.020 -0.543  0.416       
## Trtmn_M_:RL  0.127 -0.277 -0.231 -0.582 -0.012 -0.536  0.415  0.374
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE_ref_full))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_AE_ref_full
## 
## REML criterion at convergence: 372.4
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.4901 -0.6944 -0.1294  0.7102  2.8173 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.1034   0.3216  
##  Site     (Intercept) 0.0000   0.0000  
##  Room     (Intercept) 0.4739   0.6884  
##  Residual             0.7162   0.8463  
## Number of obs: 141, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                          Estimate Std. Error       df t value
## (Intercept)                               13.9430     0.5322   1.3244  26.198
## Treatment_bisDark                         -0.6459     0.2429 115.6878  -2.660
## Treatment_bisSmart                        -0.1239     0.3110 116.4622  -0.398
## Treatment_bisMixt_smart                   -0.3061     0.2909 115.4662  -1.052
## SexMale                                    0.5062     0.1495 125.3744   3.385
## RegionLuxembourg                          -0.4077     0.3159  64.9282  -1.291
## Treatment_bisDark:RegionLuxembourg         0.7261     0.3782 119.2730   1.920
## Treatment_bisSmart:RegionLuxembourg        0.1028     0.4276 117.2077   0.241
## Treatment_bisMixt_smart:RegionLuxembourg   1.6702     0.4369 118.2461   3.823
##                                          Pr(>|t|)    
## (Intercept)                              0.009254 ** 
## Treatment_bisDark                        0.008934 ** 
## Treatment_bisSmart                       0.691105    
## Treatment_bisMixt_smart                  0.294963    
## SexMale                                  0.000951 ***
## RegionLuxembourg                         0.201414    
## Treatment_bisDark:RegionLuxembourg       0.057252 .  
## Treatment_bisSmart:RegionLuxembourg      0.810349    
## Treatment_bisMixt_smart:RegionLuxembourg 0.000212 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S Trt_M_ SexMal RgnLxm T_D:RL T_S:RL
## Trtmnt_bsDr -0.243                                                 
## Trtmnt_bsSm -0.198  0.427                                          
## Trtmnt_bsM_ -0.197  0.411  0.234                                   
## SexMale     -0.145  0.050  0.096  0.027                            
## ReginLxmbrg -0.240  0.400  0.333  0.300 -0.004                     
## Trtmnt_D:RL  0.152 -0.640 -0.266 -0.269 -0.004 -0.660              
## Trtmnt_S:RL  0.136 -0.302 -0.672 -0.222 -0.023 -0.587  0.484       
## Trtmn_M_:RL  0.132 -0.284 -0.238 -0.579 -0.015 -0.570  0.460  0.412
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE_ref_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_AE_ref_smart
## 
## REML criterion at convergence: 372.4
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.4901 -0.6944 -0.1294  0.7102  2.8173 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.1034   0.3216  
##  Site     (Intercept) 0.0000   0.0000  
##  Room     (Intercept) 0.4739   0.6884  
##  Residual             0.7162   0.8463  
## Number of obs: 141, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                          Estimate Std. Error       df t value
## (Intercept)                               13.8191     0.5609   1.6286  24.639
## Treatment_bisDark                         -0.5220     0.3019 112.8818  -1.729
## Treatment_bisFull                          0.1239     0.3110 116.4622   0.398
## Treatment_bisMixt_smart                   -0.1822     0.3729 120.4413  -0.489
## SexMale                                    0.5062     0.1495 125.3744   3.385
## RegionLuxembourg                          -0.3048     0.3522  96.9262  -0.865
## Treatment_bisDark:RegionLuxembourg         0.6232     0.4115 113.7860   1.515
## Treatment_bisFull:RegionLuxembourg        -0.1028     0.4276 117.2077  -0.241
## Treatment_bisMixt_smart:RegionLuxembourg   1.5673     0.4689 119.0301   3.343
##                                          Pr(>|t|)    
## (Intercept)                              0.004344 ** 
## Treatment_bisDark                        0.086572 .  
## Treatment_bisFull                        0.691105    
## Treatment_bisMixt_smart                  0.625973    
## SexMale                                  0.000951 ***
## RegionLuxembourg                         0.388932    
## Treatment_bisDark:RegionLuxembourg       0.132668    
## Treatment_bisFull:RegionLuxembourg       0.810349    
## Treatment_bisMixt_smart:RegionLuxembourg 0.001110 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trt_M_ SexMal RgnLxm T_D:RL T_F:RL
## Trtmnt_bsDr -0.373                                                 
## Trtmnt_bsFl -0.367  0.686                                          
## Trtmnt_bsM_ -0.351  0.642  0.652                                   
## SexMale     -0.084 -0.059 -0.096 -0.059                            
## ReginLxmbrg -0.334  0.527  0.517  0.431 -0.031                     
## Trtmnt_D:RL  0.250 -0.689 -0.454 -0.392  0.020 -0.719              
## Trtmnt_F:RL  0.243 -0.449 -0.672 -0.387  0.023 -0.688  0.594       
## Trtmn_M_:RL  0.215 -0.394 -0.391 -0.589  0.007 -0.637  0.538  0.528
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE_ref_mixt_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_AE_ref_mixt_smart
## 
## REML criterion at convergence: 372.4
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.4901 -0.6944 -0.1294  0.7102  2.8173 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.1034   0.3216  
##  Site     (Intercept) 0.0000   0.0000  
##  Room     (Intercept) 0.4739   0.6884  
##  Residual             0.7162   0.8463  
## Number of obs: 141, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                     Estimate Std. Error       df t value
## (Intercept)                          13.6369     0.5540   1.5497  24.617
## Treatment_bisDark                    -0.3398     0.2925 122.3506  -1.162
## Treatment_bisFull                     0.3061     0.2909 115.4662   1.052
## Treatment_bisSmart                    0.1822     0.3729 120.4413   0.489
## SexMale                               0.5062     0.1495 125.3744   3.385
## RegionLuxembourg                      1.2625     0.3653  95.3078   3.456
## Treatment_bisDark:RegionLuxembourg   -0.9441     0.4263 122.4362  -2.215
## Treatment_bisFull:RegionLuxembourg   -1.6702     0.4369 118.2461  -3.823
## Treatment_bisSmart:RegionLuxembourg  -1.5673     0.4689 119.0301  -3.343
##                                     Pr(>|t|)    
## (Intercept)                         0.005385 ** 
## Treatment_bisDark                   0.247646    
## Treatment_bisFull                   0.294963    
## Treatment_bisSmart                  0.625973    
## SexMale                             0.000951 ***
## RegionLuxembourg                    0.000820 ***
## Treatment_bisDark:RegionLuxembourg  0.028643 *  
## Treatment_bisFull:RegionLuxembourg  0.000212 ***
## Treatment_bisSmart:RegionLuxembourg 0.001110 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trtm_S SexMal RgnLxm T_D:RL T_F:RL
## Trtmnt_bsDr -0.349                                                 
## Trtmnt_bsFl -0.336  0.654                                          
## Trtmnt_bsSm -0.318  0.612  0.585                                   
## SexMale     -0.125  0.015 -0.027  0.059                            
## ReginLxmbrg -0.275  0.436  0.433  0.341 -0.021                     
## Trtmnt_D:RL  0.186 -0.582 -0.355 -0.270  0.012 -0.739              
## Trtmnt_F:RL  0.178 -0.340 -0.579 -0.253  0.015 -0.703  0.616       
## Trtmnt_S:RL  0.179 -0.344 -0.337 -0.589 -0.007 -0.669  0.581  0.556
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
test1 <- data.frame(Reference = "Dark", as.data.frame(( summary(LM_Time_in_pupa_AE)$coeff)[,]))

test2 <- data.frame(Reference = "Smart", as.data.frame(( summary(lmer(Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE_ref_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test3 <- data.frame(Reference = "Full", as.data.frame(( summary(lmer(Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE_ref_full))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test4 <- data.frame(Reference = "Mixt_smart", as.data.frame(( summary(lmer(Time_in_pupa ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE_ref_mixt_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
Results_Time_in_pupa_AE <- rbind(test1,test2,test3,test4)

colnames(Results_Time_in_pupa_AE ) <- c("Reference","Estimate", "Std. Error", "df", "t.value", "Pr(>|z|)")

write.csv2( Results_Time_in_pupa_AE , file = "output/Results_Time_in_pupa_AE.csv" )

kable(Results_Time_in_pupa_AE , caption = " Temps en chrysalide AE ", padding = 1 )
Temps en chrysalide AE
Reference Estimate Std. Error df t.value Pr(>|z|)
(Intercept) Dark 13.2970982 0.5286168 1.288974 25.1545117 0.0108038
Treatment_bisFull Dark 0.6459053 0.2428622 115.687832 2.6595543 0.0089340
Treatment_bisSmart Dark 0.5220222 0.3019492 112.881842 1.7288410 0.0865716
Treatment_bisMixt_smart Dark 0.3398202 0.2925367 122.350649 1.1616330 0.2476457
SexMale Dark 0.5061546 0.1495354 125.374447 3.3848491 0.0009512
RegionLuxembourg Dark 0.3184147 0.2917477 59.901894 1.0914042 0.2794655
Treatment_bisFull:RegionLuxembourg Dark -0.7260823 0.3781777 119.272967 -1.9199500 0.0572523
Treatment_bisSmart:RegionLuxembourg Dark -0.6232444 0.4115138 113.785957 -1.5145164 0.1326678
Treatment_bisMixt_smart:RegionLuxembourg Dark 0.9440774 0.4263108 122.436231 2.2145285 0.0286432
(Intercept)1 Smart 13.8191204 0.5608617 1.628619 24.6390891 0.0043440
Treatment_bisDark Smart -0.5220222 0.3019492 112.881842 -1.7288410 0.0865716
Treatment_bisFull1 Smart 0.1238831 0.3109943 116.462188 0.3983453 0.6911050
Treatment_bisMixt_smart1 Smart -0.1822019 0.3728628 120.441316 -0.4886568 0.6259733
SexMale1 Smart 0.5061546 0.1495354 125.374447 3.3848491 0.0009512
RegionLuxembourg1 Smart -0.3048297 0.3522236 96.926205 -0.8654435 0.3889324
Treatment_bisDark:RegionLuxembourg Smart 0.6232444 0.4115138 113.785957 1.5145164 0.1326678
Treatment_bisFull:RegionLuxembourg1 Smart -0.1028380 0.4275699 117.207725 -0.2405173 0.8103494
Treatment_bisMixt_smart:RegionLuxembourg1 Smart 1.5673217 0.4688945 119.030103 3.3425890 0.0011098
(Intercept)2 Full 13.9430035 0.5322099 1.324387 26.1983164 0.0092543
Treatment_bisDark1 Full -0.6459053 0.2428622 115.687832 -2.6595543 0.0089340
Treatment_bisSmart1 Full -0.1238831 0.3109943 116.462188 -0.3983453 0.6911050
Treatment_bisMixt_smart2 Full -0.3060851 0.2909353 115.466175 -1.0520726 0.2949630
SexMale2 Full 0.5061546 0.1495354 125.374447 3.3848491 0.0009512
RegionLuxembourg2 Full -0.4076676 0.3158706 64.928238 -1.2906160 0.2014139
Treatment_bisDark:RegionLuxembourg1 Full 0.7260823 0.3781777 119.272967 1.9199500 0.0572523
Treatment_bisSmart:RegionLuxembourg1 Full 0.1028380 0.4275699 117.207725 0.2405173 0.8103494
Treatment_bisMixt_smart:RegionLuxembourg2 Full 1.6701597 0.4368948 118.246138 3.8227964 0.0002120
(Intercept)3 Mixt_smart 13.6369185 0.5539699 1.549681 24.6167153 0.0053847
Treatment_bisDark2 Mixt_smart -0.3398202 0.2925367 122.350649 -1.1616330 0.2476457
Treatment_bisFull2 Mixt_smart 0.3060851 0.2909353 115.466175 1.0520726 0.2949630
Treatment_bisSmart2 Mixt_smart 0.1822019 0.3728628 120.441316 0.4886568 0.6259733
SexMale3 Mixt_smart 0.5061546 0.1495354 125.374447 3.3848491 0.0009512
RegionLuxembourg3 Mixt_smart 1.2624920 0.3652747 95.307810 3.4562809 0.0008197
Treatment_bisDark:RegionLuxembourg2 Mixt_smart -0.9440774 0.4263108 122.436231 -2.2145285 0.0286432
Treatment_bisFull:RegionLuxembourg2 Mixt_smart -1.6701597 0.4368948 118.246138 -3.8227964 0.0002120
Treatment_bisSmart:RegionLuxembourg2 Mixt_smart -1.5673217 0.4688945 119.030103 -3.3425890 0.0011098
Info_time_in_pupa_AE <- "
les individus du traitement Full passent significativement (p-val = 0.008934) plus de temps (0.6459 jours) en chrysalides que les individus du traitement Dark.
Les mâles passent significativement (p-val = 0.000951) plus de temps (0.51 jours) en chrysalides.
Les individus du traitement Mixt-smart en région luxembourgoise passe significativement plus de temps en chrysalide que l'effet de la région luxembourgeoise et du traitement mixt-smart additionnés.
"
Info_time_in_pupa_AE
## [1] "\nles individus du traitement Full passent significativement (p-val = 0.008934) plus de temps (0.6459 jours) en chrysalides que les individus du traitement Dark.\nLes mâles passent significativement (p-val = 0.000951) plus de temps (0.51 jours) en chrysalides.\nLes individus du traitement Mixt-smart en région luxembourgoise passe significativement plus de temps en chrysalide que l'effet de la région luxembourgeoise et du traitement mixt-smart additionnés.\n"

6.9 TT_emerge OP

6.9.1 Test

LM_TT_emerge_OP <- lmer(TT_emerge ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_OP)
## boundary (singular) fit: see help('isSingular')
summary(LM_TT_pupation_OP)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: TT_pupation ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room)
##    Data: Data_OP
## 
## REML criterion at convergence: 610.8
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.3490 -0.5984 -0.1176  0.5181  2.6717 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 3.961    1.990   
##  Site     (Intercept) 0.000    0.000   
##  Room     (Intercept) 0.000    0.000   
##  Residual             4.092    2.023   
## Number of obs: 139, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                    Estimate Std. Error       df t value Pr(>|t|)    
## (Intercept)         14.8358     0.8848   9.9935  16.768  1.2e-08 ***
## Treatment_bisFull   -0.1726     0.3832 123.9073  -0.450   0.6533    
## Treatment_bisSmart   0.3867     0.5527 124.8872   0.700   0.4855    
## SexMale             -0.6684     0.3542 124.2542  -1.887   0.0615 .  
## RegionLuxembourg     0.3129     1.2146   8.9037   0.258   0.8025    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S SexMal
## Trtmnt_bsFl -0.151                     
## Trtmnt_bsSm -0.086  0.296              
## SexMale     -0.144 -0.134 -0.089       
## ReginLxmbrg -0.686 -0.014 -0.043  0.004
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Vérification de la normalité

qqnorm(resid(LM_TT_emerge_OP))
qqline(resid(LM_TT_emerge_OP))

Homogénité des variances

plot(LM_TT_emerge_OP)

Distance de cook

plot(cooks.distance(LM_TT_emerge_OP))

6.9.2 Simplification du modèle

drop1(LM_TT_emerge_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## TT_emerge ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##                      Sum Sq Mean Sq NumDF  DenDF F value Pr(>F)
## Treatment_bis:Sex    1.6583 0.82915     2 103.74  0.1503 0.8607
## Treatment_bis:Region 1.6593 0.82963     2 101.61  0.1503 0.8606
LM_TT_emerge1_OP <- update(LM_TT_emerge_OP, . ~ . - Treatment_bis:Sex)
## boundary (singular) fit: see help('isSingular')
drop1(LM_TT_emerge1_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## TT_emerge ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region
##                       Sum Sq Mean Sq NumDF  DenDF F value Pr(>F)
## Sex                  0.22805 0.22805     1 107.50  0.0419 0.8381
## Treatment_bis:Region 1.59297 0.79649     2 103.62  0.1464 0.8640
LM_TT_emerge2_OP <- update(LM_TT_emerge1_OP, . ~ . - Treatment_bis:Region)
## boundary (singular) fit: see help('isSingular')
drop1(LM_TT_emerge2_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## TT_emerge ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room)
##                Sum Sq  Mean Sq NumDF   DenDF F value Pr(>F)
## Treatment_bis 0.38304 0.191518     2  62.312  0.0358 0.9648
## Sex           0.21350 0.213497     1 109.226  0.0400 0.8419
## Region        0.00328 0.003276     1   8.025  0.0006 0.9808

Nous n’avons plus d’interactions, nous pouvons nous arrêter ici

Regardons si les simplifications étaient utiles

AIC(LM_TT_emerge_OP)
## [1] 581.3082
AIC(LM_TT_emerge1_OP)
## [1] 581.7585
AIC(LM_TT_emerge2_OP)
## [1] 582.1286

Les simplifications n’ont pas étées utiles

6.9.3 Treatment VS Treatment_bis

AIC(lmer(TT_emerge ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_OP))
## boundary (singular) fit: see help('isSingular')
## [1] 581.3082
AIC(lmer(TT_emerge ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment:Sex + Treatment:Region, data = Data_OP))
## boundary (singular) fit: see help('isSingular')
## [1] 579.298
summary(lmer(TT_emerge ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_OP))$coeff
## boundary (singular) fit: see help('isSingular')
##                                        Estimate Std. Error         df
## (Intercept)                         27.87557948  0.9030303   9.784419
## Treatment_bisFull                    0.08411044  0.8444907 102.980079
## Treatment_bisSmart                  -0.42992325  1.2894288  91.591569
## SexMale                              0.15250938  0.6486508 102.797281
## RegionLuxembourg                    -0.21574895  1.2042976  10.476720
## Treatment_bisFull:SexMale           -0.53129757  0.9699534 103.582246
## Treatment_bisSmart:SexMale          -0.27600600  1.3954280 104.066126
## Treatment_bisFull:RegionLuxembourg   0.32577994  0.9399401 101.045726
## Treatment_bisSmart:RegionLuxembourg  0.71090868  1.3994221 102.090842
##                                         t value     Pr(>|t|)
## (Intercept)                         30.86892901 4.441528e-11
## Treatment_bisFull                    0.09959901 9.208563e-01
## Treatment_bisSmart                  -0.33342146 7.395783e-01
## SexMale                              0.23511783 8.145850e-01
## RegionLuxembourg                    -0.17914920 8.612380e-01
## Treatment_bisFull:SexMale           -0.54775574 5.850381e-01
## Treatment_bisSmart:SexMale          -0.19779308 8.435928e-01
## Treatment_bisFull:RegionLuxembourg   0.34659648 7.296152e-01
## Treatment_bisSmart:RegionLuxembourg  0.50800163 6.125481e-01
summary(lmer(TT_emerge ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment:Sex + Treatment:Region, data = Data_OP))$coeff
## boundary (singular) fit: see help('isSingular')
##                                   Estimate Std. Error        df    t value
## (Intercept)                     27.5589015  1.0112227  13.96590 27.2530479
## TreatmentFull                    0.4432732  0.9089710 101.34304  0.4876649
## TreatmentSmart                   0.4384482  0.8804013 102.88955  0.4980095
## SexMale                          1.1827119  0.8089739 104.00154  1.4619902
## RegionLuxembourg                -0.7805045  1.3431321  14.06289 -0.5811078
## TreatmentFull:SexMale           -1.6165231  1.0907931 104.18586 -1.4819703
## TreatmentSmart:SexMale          -1.8886943  1.1044772 101.30492 -1.7100347
## TreatmentFull:RegionLuxembourg   0.9070555  1.0462572 100.79839  0.8669527
## TreatmentSmart:RegionLuxembourg  1.1224347  1.0822820 101.85066  1.0371001
##                                     Pr(>|t|)
## (Intercept)                     1.651104e-13
## TreatmentFull                   6.268406e-01
## TreatmentSmart                  6.195402e-01
## SexMale                         1.467590e-01
## RegionLuxembourg                5.703647e-01
## TreatmentFull:SexMale           1.413665e-01
## TreatmentSmart:SexMale          9.032062e-02
## TreatmentFull:RegionLuxembourg  3.880270e-01
## TreatmentSmart:RegionLuxembourg 3.021452e-01

Treatment serait à privilégier au vu des AIC

6.9.4 Résultats

Analysons les P-val

summary(LM_TT_emerge_OP)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: TT_emerge ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data_OP
## 
## REML criterion at convergence: 555.3
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -1.86427 -0.52797 -0.02408  0.59660  3.01729 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 3.05194  1.7470  
##  Site     (Intercept) 0.00000  0.0000  
##  Room     (Intercept) 0.09577  0.3095  
##  Residual             5.51833  2.3491  
## Number of obs: 122, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                                      Estimate Std. Error        df t value
## (Intercept)                          27.87558    0.90303   9.78442  30.869
## Treatment_bisFull                     0.08411    0.84449 102.98008   0.100
## Treatment_bisSmart                   -0.42992    1.28943  91.59157  -0.333
## SexMale                               0.15251    0.64865 102.79728   0.235
## RegionLuxembourg                     -0.21575    1.20430  10.47672  -0.179
## Treatment_bisFull:SexMale            -0.53130    0.96995 103.58225  -0.548
## Treatment_bisSmart:SexMale           -0.27601    1.39543 104.06613  -0.198
## Treatment_bisFull:RegionLuxembourg    0.32578    0.93994 101.04573   0.347
## Treatment_bisSmart:RegionLuxembourg   0.71091    1.39942 102.09084   0.508
##                                     Pr(>|t|)    
## (Intercept)                         4.44e-11 ***
## Treatment_bisFull                      0.921    
## Treatment_bisSmart                     0.740    
## SexMale                                0.815    
## RegionLuxembourg                       0.861    
## Treatment_bisFull:SexMale              0.585    
## Treatment_bisSmart:SexMale             0.844    
## Treatment_bisFull:RegionLuxembourg     0.730    
## Treatment_bisSmart:RegionLuxembourg    0.613    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S SexMal RgnLxm T_F:SM T_S:SM T_F:RL
## Trtmnt_bsFl -0.322                                                 
## Trtmnt_bsSm -0.212  0.232                                          
## SexMale     -0.263  0.267  0.218                                   
## ReginLxmbrg -0.646  0.166  0.091 -0.018                            
## Trtmnt_F:SM  0.183 -0.569 -0.143 -0.661  0.026                     
## Trtmnt_S:SM  0.123 -0.127 -0.526 -0.482  0.034  0.324              
## Trtmnt_F:RL  0.207 -0.610 -0.133  0.040 -0.342  0.027 -0.028       
## Trtmnt_S:RL  0.131 -0.134 -0.589  0.017 -0.235 -0.033 -0.091  0.294
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(TT_emerge ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment:Sex + Treatment:Region, data = Data_OP_ref_full))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: TT_emerge ~ Treatment + Sex + Region + (1 | Mother) + (1 | Site) +  
##     (1 | Room) + Treatment:Sex + Treatment:Region
##    Data: Data_OP_ref_full
## 
## REML criterion at convergence: 553.3
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -1.87514 -0.58549 -0.06971  0.55940  2.74663 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 3.434e+00 1.853e+00
##  Site     (Intercept) 1.248e-09 3.532e-05
##  Room     (Intercept) 1.271e-01 3.565e-01
##  Residual             5.282e+00 2.298e+00
## Number of obs: 122, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                                   Estimate Std. Error         df t value
## (Intercept)                      28.002175   1.047210  16.111424  26.740
## TreatmentDark                    -0.443273   0.908971 101.343037  -0.488
## TreatmentSmart                   -0.004825   0.927026 103.820955  -0.005
## SexMale                          -0.433811   0.712715 103.125540  -0.609
## RegionLuxembourg                  0.126551   1.290239  12.010919   0.098
## TreatmentDark:SexMale             1.616523   1.090793 104.185860   1.482
## TreatmentSmart:SexMale           -0.272171   1.027290 102.041561  -0.265
## TreatmentDark:RegionLuxembourg   -0.907055   1.046257 100.798393  -0.867
## TreatmentSmart:RegionLuxembourg   0.215379   1.020885 102.098748   0.211
##                                 Pr(>|t|)    
## (Intercept)                     8.89e-15 ***
## TreatmentDark                      0.627    
## TreatmentSmart                     0.996    
## SexMale                            0.544    
## RegionLuxembourg                   0.923    
## TreatmentDark:SexMale              0.141    
## TreatmentSmart:SexMale             0.792    
## TreatmentDark:RegionLuxembourg     0.388    
## TreatmentSmart:RegionLuxembourg    0.833    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TrtmnD TrtmnS SexMal RgnLxm TrD:SM TrS:SM TrD:RL
## TreatmntDrk -0.473                                                 
## TretmntSmrt -0.458  0.540                                          
## SexMale     -0.403  0.483  0.460                                   
## ReginLxmbrg -0.660  0.257  0.248  0.068                            
## TrtmntDr:SM  0.269 -0.561 -0.301 -0.671 -0.039                     
## TrtmntSm:SM  0.265 -0.321 -0.562 -0.671 -0.033  0.457              
## TrtmntDr:RL  0.266 -0.561 -0.307 -0.058 -0.354 -0.066  0.033       
## TrtmntSm:RL  0.282 -0.329 -0.657 -0.081 -0.363  0.043  0.077  0.452
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(TT_emerge ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment:Sex + Treatment:Region, data = Data_OP_ref_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: TT_emerge ~ Treatment + Sex + Region + (1 | Mother) + (1 | Site) +  
##     (1 | Room) + Treatment:Sex + Treatment:Region
##    Data: Data_OP_ref_smart
## 
## REML criterion at convergence: 553.3
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -1.87514 -0.58549 -0.06971  0.55940  2.74663 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 3.434e+00 1.853e+00
##  Site     (Intercept) 1.248e-09 3.532e-05
##  Room     (Intercept) 1.271e-01 3.565e-01
##  Residual             5.282e+00 2.298e+00
## Number of obs: 122, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                                  Estimate Std. Error         df t value
## (Intercept)                     27.997350   1.033172  14.548382  27.098
## TreatmentDark                   -0.438448   0.880401 102.889551  -0.498
## TreatmentFull                    0.004825   0.927026 103.820955   0.005
## SexMale                         -0.705982   0.762476 102.738009  -0.926
## RegionLuxembourg                 0.341930   1.323532  13.090840   0.258
## TreatmentDark:SexMale            1.888694   1.104477 101.304916   1.710
## TreatmentFull:SexMale            0.272171   1.027290 102.041561   0.265
## TreatmentDark:RegionLuxembourg  -1.122435   1.082282 101.850655  -1.037
## TreatmentFull:RegionLuxembourg  -0.215379   1.020885 102.098748  -0.211
##                                Pr(>|t|)    
## (Intercept)                    7.35e-14 ***
## TreatmentDark                    0.6195    
## TreatmentFull                    0.9959    
## SexMale                          0.3567    
## RegionLuxembourg                 0.8002    
## TreatmentDark:SexMale            0.0903 .  
## TreatmentFull:SexMale            0.7916    
## TreatmentDark:RegionLuxembourg   0.3021    
## TreatmentFull:RegionLuxembourg   0.8333    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TrtmnD TrtmnF SexMal RgnLxm TrD:SM TrF:SM TrD:RL
## TreatmntDrk -0.451                                                 
## TreatmntFll -0.433  0.495                                          
## SexMale     -0.314  0.365  0.328                                   
## ReginLxmbrg -0.670  0.275  0.265  0.041                            
## TrtmntDr:SM  0.222 -0.501 -0.225 -0.681 -0.029                     
## TrtmntFl:SM  0.236 -0.261 -0.562 -0.721 -0.027  0.478              
## TrtmntDr:RL  0.280 -0.579 -0.322 -0.036 -0.391 -0.066  0.040       
## TrtmntFl:RL  0.304 -0.352 -0.657 -0.028 -0.418  0.029  0.077  0.506
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
test1 <- data.frame(Reference = "Dark", as.data.frame(( summary(LM_TT_emerge_OP)$coeff)[,]))

test2 <- data.frame(Reference = "Smart", as.data.frame(( summary(lmer(TT_emerge ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment:Sex + Treatment:Region, data = Data_OP_ref_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test3 <- data.frame(Reference = "Full", as.data.frame(( summary(lmer(TT_emerge ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment:Sex + Treatment:Region, data = Data_OP_ref_full))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
Results_TT_emerge_OP <- rbind(test1,test2,test3)

colnames(Results_TT_emerge_OP ) <- c("Reference","Estimate", "Std. Error", "df", "t.value", "Pr(>|z|)")

write.csv2( Results_TT_emerge_OP , file = "output/Results_TT_emerge_OP.csv" )

kable(Results_TT_emerge_OP, caption = " Temps pour sortir de chrysalide OP ", padding = 1 )
Temps pour sortir de chrysalide OP
Reference Estimate Std. Error df t.value Pr(>|z|)
(Intercept) Dark 27.8755795 0.9030303 9.784419 30.8689290 0.0000000
Treatment_bisFull Dark 0.0841104 0.8444907 102.980079 0.0995990 0.9208563
Treatment_bisSmart Dark -0.4299232 1.2894288 91.591569 -0.3334215 0.7395783
SexMale Dark 0.1525094 0.6486508 102.797281 0.2351178 0.8145850
RegionLuxembourg Dark -0.2157489 1.2042976 10.476720 -0.1791492 0.8612380
Treatment_bisFull:SexMale Dark -0.5312976 0.9699534 103.582246 -0.5477557 0.5850381
Treatment_bisSmart:SexMale Dark -0.2760060 1.3954280 104.066125 -0.1977931 0.8435928
Treatment_bisFull:RegionLuxembourg Dark 0.3257799 0.9399401 101.045726 0.3465965 0.7296152
Treatment_bisSmart:RegionLuxembourg Dark 0.7109087 1.3994221 102.090842 0.5080016 0.6125481
(Intercept)1 Smart 27.9973497 1.0331725 14.548382 27.0984273 0.0000000
TreatmentDark Smart -0.4384482 0.8804013 102.889551 -0.4980095 0.6195402
TreatmentFull Smart 0.0048250 0.9270259 103.820955 0.0052048 0.9958571
SexMale1 Smart -0.7059824 0.7624760 102.738009 -0.9259078 0.3566638
RegionLuxembourg1 Smart 0.3419302 1.3235316 13.090840 0.2583468 0.8001565
TreatmentDark:SexMale Smart 1.8886943 1.1044772 101.304917 1.7100347 0.0903206
TreatmentFull:SexMale Smart 0.2721713 1.0272899 102.041561 0.2649410 0.7915893
TreatmentDark:RegionLuxembourg Smart -1.1224347 1.0822820 101.850655 -1.0371001 0.3021452
TreatmentFull:RegionLuxembourg Smart -0.2153793 1.0208849 102.098748 -0.2109731 0.8333288
(Intercept)2 Full 28.0021747 1.0472095 16.111424 26.7398008 0.0000000
TreatmentDark1 Full -0.4432732 0.9089710 101.343037 -0.4876649 0.6268406
TreatmentSmart Full -0.0048250 0.9270259 103.820955 -0.0052048 0.9958571
SexMale2 Full -0.4338112 0.7127152 103.125540 -0.6086740 0.5440790
RegionLuxembourg2 Full 0.1265509 1.2902387 12.010919 0.0980834 0.9234839
TreatmentDark:SexMale1 Full 1.6165231 1.0907931 104.185860 1.4819703 0.1413665
TreatmentSmart:SexMale Full -0.2721713 1.0272899 102.041561 -0.2649410 0.7915893
TreatmentDark:RegionLuxembourg1 Full -0.9070555 1.0462572 100.798393 -0.8669527 0.3880270
TreatmentSmart:RegionLuxembourg Full 0.2153793 1.0208849 102.098748 0.2109731 0.8333288
Infos_TT_emerge_OP <- "
RIEN DU TOUT de significatif
"
Infos_TT_emerge_OP
## [1] "\nRIEN DU TOUT de significatif\n"

6.10 TT_emerge AE

6.10.1 Test

LM_TT_emerge_AE <- lmer(TT_emerge ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_AE)
summary(LM_TT_pupation_AE)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(TT_pupation) ~ Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_AE
## 
## REML criterion at convergence: 20.6
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.7966 -0.7170 -0.1319  0.4654  3.4962 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.004651 0.0682  
##  Site     (Intercept) 0.016315 0.1277  
##  Room     (Intercept) 0.000000 0.0000  
##  Residual             0.048352 0.2199  
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                                3.730223   0.072678  15.927558
## Treatment_bisFull                         -0.025347   0.057426 141.055825
## Treatment_bisSmart                        -0.071770   0.070289 140.342406
## Treatment_bisMixt_smart                   -0.055765   0.068962 142.481416
## SexMale                                    0.004833   0.036243 147.534799
## RegionLuxembourg                           0.141065   0.101426  17.484790
## Treatment_bisFull:RegionLuxembourg         0.083329   0.088995 144.914259
## Treatment_bisSmart:RegionLuxembourg       -0.156871   0.101294 140.771354
## Treatment_bisMixt_smart:RegionLuxembourg   0.234982   0.105533 144.897884
##                                          t value Pr(>|t|)    
## (Intercept)                               51.325   <2e-16 ***
## Treatment_bisFull                         -0.441   0.6596    
## Treatment_bisSmart                        -1.021   0.3090    
## Treatment_bisMixt_smart                   -0.809   0.4201    
## SexMale                                    0.133   0.8941    
## RegionLuxembourg                           1.391   0.1817    
## Treatment_bisFull:RegionLuxembourg         0.936   0.3507    
## Treatment_bisSmart:RegionLuxembourg       -1.549   0.1237    
## Treatment_bisMixt_smart:RegionLuxembourg   2.227   0.0275 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_F:RL T_S:RL
## Trtmnt_bsFl -0.391                                                 
## Trtmnt_bsSm -0.323  0.411                                          
## Trtmnt_bsM_ -0.335  0.425  0.345                                   
## SexMale     -0.198 -0.047  0.035 -0.021                            
## ReginLxmbrg -0.684  0.288  0.226  0.244 -0.024                     
## Trtmnt_F:RL  0.255 -0.645 -0.266 -0.274  0.018 -0.447              
## Trtmnt_S:RL  0.219 -0.287 -0.693 -0.240  0.001 -0.382  0.445       
## Trtmn_M_:RL  0.225 -0.277 -0.226 -0.653 -0.016 -0.376  0.446  0.374
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Vérification de la normalité

qqnorm(resid(LM_TT_emerge_AE))
qqline(resid(LM_TT_emerge_AE))

Cela pourrait encore aller peut-être mais on peut tenter en faisant des modifications

LM_TT_emerge_AE <- lmer(log(TT_emerge) ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_AE)

Vérification de la normalité

qqnorm(resid(LM_TT_emerge_AE))
qqline(resid(LM_TT_emerge_AE))

C’est déjà beaucoup mieux

Homogénité des variances

plot(LM_TT_emerge_AE)

Distance de cook

plot(cooks.distance(LM_TT_emerge_AE))

Je pense que je vais retirer le point outlier

Data_TT_emerge_AE <- (Data_AE %>% filter(TT_emerge != "NA"))[unname(cooks.distance(LM_TT_emerge_AE) != max(cooks.distance(LM_TT_emerge_AE))),]

Data_TT_emerge_AE_ref_smart <- Data_TT_emerge_AE
Data_TT_emerge_AE_ref_smart$Treatment_bis <- relevel(Data_TT_emerge_AE$Treatment_bis, ref = "Smart")

Data_TT_emerge_AE_ref_full <- Data_TT_emerge_AE
Data_TT_emerge_AE_ref_full$Treatment_bis <- relevel(Data_TT_emerge_AE$Treatment_bis, ref = "Full")

Data_TT_emerge_AE_ref_mixt_smart <- Data_TT_emerge_AE
Data_TT_emerge_AE_ref_mixt_smart$Treatment_bis <- relevel(Data_TT_emerge_AE$Treatment_bis, ref = "Mixt_smart")
LM_TT_emerge_AE <- lmer(log(TT_emerge) ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_TT_emerge_AE)

Vérification de la normalité

qqnorm(resid(LM_TT_emerge_AE))
qqline(resid(LM_TT_emerge_AE))

Homogénité des variances

plot(LM_TT_emerge_AE)

Distance de cook

plot(cooks.distance(LM_TT_emerge_AE))

6.10.2 Simplification du modèle

drop1(LM_TT_emerge_AE)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(TT_emerge) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##                        Sum Sq  Mean Sq NumDF  DenDF F value   Pr(>F)   
## Treatment_bis:Sex    0.044494 0.014831     3 119.83  0.8600 0.463986   
## Treatment_bis:Region 0.214083 0.071361     3 114.15  4.1378 0.007971 **
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_TT_emerge1_AE <- update(LM_TT_emerge_AE, . ~ . - Treatment_bis:Sex)
drop1(LM_TT_emerge1_AE)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(TT_emerge) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region
##                        Sum Sq  Mean Sq NumDF  DenDF F value   Pr(>F)   
## Sex                  0.042638 0.042638     1 120.64  2.4921 0.117040   
## Treatment_bis:Region 0.208287 0.069429     3 116.98  4.0580 0.008764 **
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Nous n’avons plus d’interactions non significatives, nous pouvons nous arrêter ici

Regardons si les simplifications étaient utiles

AIC(LM_TT_emerge_AE)
## [1] -70.3028
AIC(LM_TT_emerge1_AE)
## [1] -85.00483

Les simplifications ont étées utiles

6.10.3 Treatment VS Treatment_bis

AIC(lmer(log(TT_emerge) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_TT_emerge_AE))
## [1] -85.00483
AIC(lmer(log(TT_emerge) ~ Treatment + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment:Region, data = Data_TT_emerge_AE))
## [1] -79.83351
summary(lmer(log(TT_emerge) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_TT_emerge_AE))$coeff
##                                              Estimate Std. Error         df
## (Intercept)                               3.937831986 0.05372966   6.667809
## Treatment_bisFull                         0.019440282 0.03779753 114.687830
## Treatment_bisSmart                        0.005527079 0.04643601 112.131751
## Treatment_bisMixt_smart                   0.008068429 0.04509883 112.949573
## SexMale                                   0.037320542 0.02364111 120.643665
## RegionLuxembourg                          0.113469549 0.06359356  18.246683
## Treatment_bisFull:RegionLuxembourg        0.045158762 0.05915378 116.783455
## Treatment_bisSmart:RegionLuxembourg      -0.103791097 0.06412734 113.990567
## Treatment_bisMixt_smart:RegionLuxembourg  0.146465280 0.06692477 119.669046
##                                             t value     Pr(>|t|)
## (Intercept)                              73.2897210 6.073881e-11
## Treatment_bisFull                         0.5143268 6.080132e-01
## Treatment_bisSmart                        0.1190257 9.054680e-01
## Treatment_bisMixt_smart                   0.1789055 8.583324e-01
## SexMale                                   1.5786291 1.170396e-01
## RegionLuxembourg                          1.7842931 9.101423e-02
## Treatment_bisFull:RegionLuxembourg        0.7634129 4.467567e-01
## Treatment_bisSmart:RegionLuxembourg      -1.6185156 1.083152e-01
## Treatment_bisMixt_smart:RegionLuxembourg  2.1885062 3.057481e-02
summary(lmer(log(TT_emerge) ~ Treatment + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment:Region, data = Data_TT_emerge_AE))$coeff
##                                     Estimate Std. Error         df     t value
## (Intercept)                      3.936687035 0.06868135   3.108999 57.31813673
## TreatmentFull                    0.017837237 0.03974452 115.152611  0.44879743
## TreatmentSmart                   0.003287872 0.03788359 116.458328  0.08678883
## SexMale                          0.042133206 0.02483477 121.849161  1.69654067
## RegionLuxembourg                 0.119150273 0.06540721  19.413236  1.82166876
## TreatmentFull:RegionLuxembourg   0.042732448 0.06227982 117.757038  0.68613640
## TreatmentSmart:RegionLuxembourg -0.001941170 0.05688847 117.471008 -0.03412238
##                                     Pr(>|t|)
## (Intercept)                     8.317383e-06
## TreatmentFull                   6.544212e-01
## TreatmentSmart                  9.309884e-01
## SexMale                         9.233677e-02
## RegionLuxembourg                8.395123e-02
## TreatmentFull:RegionLuxembourg  4.939758e-01
## TreatmentSmart:RegionLuxembourg 9.728375e-01

Treatment_bis serait à privilégier au vu des AIC

6.10.4 Résultats

Analysons les P-val

summary(lmer(log(TT_emerge) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_TT_emerge_AE))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(TT_emerge) ~ Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_TT_emerge_AE
## 
## REML criterion at convergence: -111
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.17988 -0.69424 -0.08191  0.51398  2.39915 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.002616 0.05115 
##  Site     (Intercept) 0.005481 0.07403 
##  Room     (Intercept) 0.001508 0.03884 
##  Residual             0.017109 0.13080 
## Number of obs: 140, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                                3.937832   0.053730   6.667809
## Treatment_bisFull                          0.019440   0.037798 114.687830
## Treatment_bisSmart                         0.005527   0.046436 112.131751
## Treatment_bisMixt_smart                    0.008068   0.045099 112.949573
## SexMale                                    0.037321   0.023641 120.643665
## RegionLuxembourg                           0.113470   0.063594  18.246683
## Treatment_bisFull:RegionLuxembourg         0.045159   0.059154 116.783455
## Treatment_bisSmart:RegionLuxembourg       -0.103791   0.064127 113.990567
## Treatment_bisMixt_smart:RegionLuxembourg   0.146465   0.066925 119.669046
##                                          t value Pr(>|t|)    
## (Intercept)                               73.290 6.07e-11 ***
## Treatment_bisFull                          0.514   0.6080    
## Treatment_bisSmart                         0.119   0.9055    
## Treatment_bisMixt_smart                    0.179   0.8583    
## SexMale                                    1.579   0.1170    
## RegionLuxembourg                           1.784   0.0910 .  
## Treatment_bisFull:RegionLuxembourg         0.763   0.4468    
## Treatment_bisSmart:RegionLuxembourg       -1.619   0.1083    
## Treatment_bisMixt_smart:RegionLuxembourg   2.189   0.0306 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_F:RL T_S:RL
## Trtmnt_bsFl -0.346                                                 
## Trtmnt_bsSm -0.269  0.368                                          
## Trtmnt_bsM_ -0.314  0.432  0.237                                   
## SexMale     -0.199 -0.050  0.052 -0.005                            
## ReginLxmbrg -0.590  0.299  0.234  0.247  0.004                     
## Trtmnt_F:RL  0.229 -0.637 -0.239 -0.273 -0.010 -0.434              
## Trtmnt_S:RL  0.195 -0.273 -0.686 -0.218 -0.023 -0.396  0.421       
## Trtmn_M_:RL  0.213 -0.280 -0.226 -0.593 -0.033 -0.398  0.424  0.375
summary(lmer(log(TT_emerge) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_TT_emerge_AE_ref_smart))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(TT_emerge) ~ Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_TT_emerge_AE_ref_smart
## 
## REML criterion at convergence: -111
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.17988 -0.69424 -0.08191  0.51398  2.39915 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.002616 0.05115 
##  Site     (Intercept) 0.005481 0.07403 
##  Room     (Intercept) 0.001508 0.03884 
##  Residual             0.017109 0.13080 
## Number of obs: 140, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                                3.943359   0.060840  10.061802
## Treatment_bisDark                         -0.005527   0.046436 112.131751
## Treatment_bisFull                          0.013913   0.047889 112.461609
## Treatment_bisMixt_smart                    0.002541   0.056538  84.869958
## SexMale                                    0.037321   0.023641 120.643665
## RegionLuxembourg                           0.009678   0.070178  26.669949
## Treatment_bisDark:RegionLuxembourg         0.103791   0.064127 113.990567
## Treatment_bisFull:RegionLuxembourg         0.148950   0.066449 116.966510
## Treatment_bisMixt_smart:RegionLuxembourg   0.250256   0.073270 117.544237
##                                          t value Pr(>|t|)    
## (Intercept)                               64.815 1.59e-14 ***
## Treatment_bisDark                         -0.119 0.905468    
## Treatment_bisFull                          0.291 0.771944    
## Treatment_bisMixt_smart                    0.045 0.964253    
## SexMale                                    1.579 0.117040    
## RegionLuxembourg                           0.138 0.891345    
## Treatment_bisDark:RegionLuxembourg         1.619 0.108315    
## Treatment_bisFull:RegionLuxembourg         2.242 0.026876 *  
## Treatment_bisMixt_smart:RegionLuxembourg   3.416 0.000875 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trt_M_ SexMal RgnLxm T_D:RL T_F:RL
## Trtmnt_bsDr -0.526                                                 
## Trtmnt_bsFl -0.530  0.679                                          
## Trtmnt_bsM_ -0.509  0.632  0.646                                   
## SexMale     -0.136 -0.052 -0.090 -0.047                            
## ReginLxmbrg -0.631  0.415  0.419  0.359 -0.017                     
## Trtmnt_D:RL  0.351 -0.686 -0.450 -0.389  0.023 -0.555              
## Trtmnt_F:RL  0.357 -0.449 -0.675 -0.395  0.013 -0.543  0.590       
## Trtmn_M_:RL  0.321 -0.394 -0.395 -0.603 -0.010 -0.501  0.532  0.531
summary(lmer(log(TT_emerge) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_TT_emerge_AE_ref_full))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(TT_emerge) ~ Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_TT_emerge_AE_ref_full
## 
## REML criterion at convergence: -111
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.17988 -0.69424 -0.08191  0.51398  2.39915 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.002616 0.05115 
##  Site     (Intercept) 0.005481 0.07403 
##  Room     (Intercept) 0.001508 0.03884 
##  Residual             0.017109 0.13080 
## Number of obs: 140, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                           Estimate Std. Error        df t value
## (Intercept)                                3.95727    0.05393   6.87689  73.380
## Treatment_bisDark                         -0.01944    0.03780 114.68783  -0.514
## Treatment_bisSmart                        -0.01391    0.04789 112.46161  -0.291
## Treatment_bisMixt_smart                   -0.01137    0.04460 112.05571  -0.255
## SexMale                                    0.03732    0.02364 120.64366   1.579
## RegionLuxembourg                           0.15863    0.06542  20.90884   2.425
## Treatment_bisDark:RegionLuxembourg        -0.04516    0.05915 116.78346  -0.763
## Treatment_bisSmart:RegionLuxembourg       -0.14895    0.06645 116.96651  -2.242
## Treatment_bisMixt_smart:RegionLuxembourg   0.10131    0.06795 117.18579   1.491
##                                          Pr(>|t|)    
## (Intercept)                              3.28e-11 ***
## Treatment_bisDark                          0.6080    
## Treatment_bisSmart                         0.7719    
## Treatment_bisMixt_smart                    0.7992    
## SexMale                                    0.1170    
## RegionLuxembourg                           0.0245 *  
## Treatment_bisDark:RegionLuxembourg         0.4468    
## Treatment_bisSmart:RegionLuxembourg        0.0269 *  
## Treatment_bisMixt_smart:RegionLuxembourg   0.1387    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S Trt_M_ SexMal RgnLxm T_D:RL T_S:RL
## Trtmnt_bsDr -0.356                                                 
## Trtmnt_bsSm -0.290  0.432                                          
## Trtmnt_bsM_ -0.312  0.410  0.254                                   
## SexMale     -0.233  0.050  0.090  0.037                            
## ReginLxmbrg -0.565  0.285  0.236  0.234 -0.005                     
## Trtmnt_D:RL  0.218 -0.637 -0.270 -0.263  0.010 -0.483              
## Trtmnt_S:RL  0.197 -0.303 -0.675 -0.224 -0.013 -0.434  0.484       
## Trtmn_M_:RL  0.205 -0.279 -0.234 -0.586 -0.024 -0.423  0.453  0.406
summary(lmer(log(TT_emerge) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_TT_emerge_AE_ref_mixt_smart))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(TT_emerge) ~ Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_TT_emerge_AE_ref_mixt_smart
## 
## REML criterion at convergence: -111
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.17988 -0.69424 -0.08191  0.51398  2.39915 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.002616 0.05115 
##  Site     (Intercept) 0.005481 0.07403 
##  Room     (Intercept) 0.001508 0.03884 
##  Residual             0.017109 0.13080 
## Number of obs: 140, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                       Estimate Std. Error         df t value
## (Intercept)                           3.945900   0.058291   8.667662  67.693
## Treatment_bisDark                    -0.008068   0.045099 112.949573  -0.179
## Treatment_bisFull                     0.011372   0.044602 112.055707   0.255
## Treatment_bisSmart                   -0.002541   0.056538  84.869958  -0.045
## SexMale                               0.037321   0.023641 120.643665   1.579
## RegionLuxembourg                      0.259935   0.071678  28.774745   3.626
## Treatment_bisDark:RegionLuxembourg   -0.146465   0.066925 119.669046  -2.189
## Treatment_bisFull:RegionLuxembourg   -0.101307   0.067954 117.185793  -1.491
## Treatment_bisSmart:RegionLuxembourg  -0.250256   0.073270 117.544237  -3.416
##                                     Pr(>|t|)    
## (Intercept)                         4.13e-13 ***
## Treatment_bisDark                   0.858332    
## Treatment_bisFull                   0.799217    
## Treatment_bisSmart                  0.964253    
## SexMale                             0.117040    
## RegionLuxembourg                    0.001101 ** 
## Treatment_bisDark:RegionLuxembourg  0.030575 *  
## Treatment_bisFull:RegionLuxembourg  0.138701    
## Treatment_bisSmart:RegionLuxembourg 0.000875 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trtm_S SexMal RgnLxm T_D:RL T_F:RL
## Trtmnt_bsDr -0.484                                                 
## Trtmnt_bsFl -0.477  0.645                                          
## Trtmnt_bsSm -0.439  0.603  0.574                                   
## SexMale     -0.187  0.005 -0.037  0.047                            
## ReginLxmbrg -0.559  0.335  0.342  0.265 -0.027                     
## Trtmnt_D:RL  0.263 -0.593 -0.363 -0.287  0.033 -0.581              
## Trtmnt_F:RL  0.259 -0.346 -0.586 -0.264  0.024 -0.562  0.615       
## Trtmnt_S:RL  0.250 -0.350 -0.340 -0.603  0.010 -0.531  0.585  0.559
test1 <- data.frame(Reference = "Dark", as.data.frame(( summary(lmer(log(TT_emerge) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_TT_emerge_AE))$coeff)[,]))

test2 <- data.frame(Reference = "Smart", as.data.frame(( summary(lmer(log(TT_emerge) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_TT_emerge_AE_ref_smart))$coeff)[,]))

test3 <- data.frame(Reference = "Full", as.data.frame(( summary(lmer(log(TT_emerge) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_TT_emerge_AE_ref_full))$coeff)[,]))

test4 <- data.frame(Reference = "Mixt_smart", as.data.frame(( summary(lmer(log(TT_emerge) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_TT_emerge_AE_ref_mixt_smart))$coeff)[,]))

Results_TT_emerge_AE <- rbind(test1,test2,test3,test4)

colnames(Results_TT_emerge_AE ) <- c("Reference","Estimate", "Std. Error", "df", "t.value", "Pr(>|z|)")

write.csv2( Results_TT_emerge_AE , file = "output/Results_TT_emerge_AE.csv" )

kable(Results_TT_emerge_AE , caption = " Temps pour sortir de chrysalide AE ", padding = 1 )
Temps pour sortir de chrysalide AE
Reference Estimate Std. Error df t.value Pr(>|z|)
(Intercept) Dark 3.9378320 0.0537297 6.667809 73.2897210 0.0000000
Treatment_bisFull Dark 0.0194403 0.0377975 114.687830 0.5143268 0.6080132
Treatment_bisSmart Dark 0.0055271 0.0464360 112.131751 0.1190257 0.9054680
Treatment_bisMixt_smart Dark 0.0080684 0.0450988 112.949573 0.1789055 0.8583324
SexMale Dark 0.0373205 0.0236411 120.643665 1.5786291 0.1170396
RegionLuxembourg Dark 0.1134695 0.0635936 18.246682 1.7842931 0.0910142
Treatment_bisFull:RegionLuxembourg Dark 0.0451588 0.0591538 116.783455 0.7634129 0.4467567
Treatment_bisSmart:RegionLuxembourg Dark -0.1037911 0.0641273 113.990567 -1.6185156 0.1083152
Treatment_bisMixt_smart:RegionLuxembourg Dark 0.1464653 0.0669248 119.669046 2.1885062 0.0305748
(Intercept)1 Smart 3.9433591 0.0608399 10.061802 64.8153565 0.0000000
Treatment_bisDark Smart -0.0055271 0.0464360 112.131751 -0.1190257 0.9054680
Treatment_bisFull1 Smart 0.0139132 0.0478887 112.461609 0.2905323 0.7719441
Treatment_bisMixt_smart1 Smart 0.0025413 0.0565384 84.869958 0.0449491 0.9642535
SexMale1 Smart 0.0373205 0.0236411 120.643665 1.5786291 0.1170396
RegionLuxembourg1 Smart 0.0096785 0.0701777 26.669949 0.1379135 0.8913448
Treatment_bisDark:RegionLuxembourg Smart 0.1037911 0.0641273 113.990567 1.6185156 0.1083152
Treatment_bisFull:RegionLuxembourg1 Smart 0.1489499 0.0664491 116.966510 2.2415643 0.0268758
Treatment_bisMixt_smart:RegionLuxembourg1 Smart 0.2502564 0.0732697 117.544237 3.4155500 0.0008746
(Intercept)2 Full 3.9572723 0.0539287 6.876888 73.3797668 0.0000000
Treatment_bisDark1 Full -0.0194403 0.0377975 114.687830 -0.5143268 0.6080132
Treatment_bisSmart1 Full -0.0139132 0.0478887 112.461609 -0.2905323 0.7719441
Treatment_bisMixt_smart2 Full -0.0113719 0.0446016 112.055707 -0.2549652 0.7992174
SexMale2 Full 0.0373205 0.0236411 120.643665 1.5786291 0.1170396
RegionLuxembourg2 Full 0.1586283 0.0654200 20.908844 2.4247693 0.0244662
Treatment_bisDark:RegionLuxembourg1 Full -0.0451588 0.0591538 116.783455 -0.7634129 0.4467567
Treatment_bisSmart:RegionLuxembourg1 Full -0.1489499 0.0664491 116.966510 -2.2415643 0.0268758
Treatment_bisMixt_smart:RegionLuxembourg2 Full 0.1013065 0.0679544 117.185793 1.4908013 0.1387006
(Intercept)3 Mixt_smart 3.9459004 0.0582909 8.667662 67.6932828 0.0000000
Treatment_bisDark2 Mixt_smart -0.0080684 0.0450988 112.949573 -0.1789055 0.8583324
Treatment_bisFull2 Mixt_smart 0.0113719 0.0446016 112.055707 0.2549652 0.7992174
Treatment_bisSmart2 Mixt_smart -0.0025413 0.0565384 84.869958 -0.0449491 0.9642535
SexMale3 Mixt_smart 0.0373205 0.0236411 120.643665 1.5786291 0.1170396
RegionLuxembourg3 Mixt_smart 0.2599348 0.0716780 28.774745 3.6264258 0.0011006
Treatment_bisDark:RegionLuxembourg2 Mixt_smart -0.1464653 0.0669248 119.669046 -2.1885062 0.0305748
Treatment_bisFull:RegionLuxembourg2 Mixt_smart -0.1013065 0.0679544 117.185793 -1.4908013 0.1387006
Treatment_bisSmart:RegionLuxembourg2 Mixt_smart -0.2502564 0.0732697 117.544237 -3.4155500 0.0008746
Infos_TT_emerge_AE <- "
Le traitement mixt-smart en région luxembourgoise est significativement plus lent que l'effet de la région luxembourgeoise et du traitement mixt-smart additionné sauf quand on le compare au traitement full où là, la région luxembourg est elle même significativement plus lente.
Les individus du traitement full mettent significativements (p-val = 0.0245) plus de temps (1.17 jours) à atteindre le stade adulte si ils descendent d'une mère qui provient du luxembourg.
Le traitement full en région luxembourgoise est significativement plus lent que l'effet de la région luxembourgeoise et du traitement full additionné qaund ils sont comparés au traitement smart.
"
Infos_TT_emerge_AE
## [1] "\nLe traitement mixt-smart en région luxembourgoise est significativement plus lent que l'effet de la région luxembourgeoise et du traitement mixt-smart additionné sauf quand on le compare au traitement full où là, la région luxembourg est elle même significativement plus lente.\nLes individus du traitement full mettent significativements (p-val = 0.0245) plus de temps (1.17 jours) à atteindre le stade adulte si ils descendent d'une mère qui provient du luxembourg.\nLe traitement full en région luxembourgoise est significativement plus lent que l'effet de la région luxembourgeoise et du traitement full additionné qaund ils sont comparés au traitement smart.\n"

6.11 Pupa_mass OP

6.11.1 Test

LM_Pupa_mass_OP <- lmer(Pupa_mass ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_OP)
## boundary (singular) fit: see help('isSingular')
summary(LM_Pupa_mass_OP)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Pupa_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data_OP
## 
## REML criterion at convergence: -613.1
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.68459 -0.51981 -0.03472  0.58713  2.23727 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 1.924e-04 0.013871
##  Site     (Intercept) 0.000e+00 0.000000
##  Room     (Intercept) 1.742e-05 0.004173
##  Residual             2.196e-04 0.014820
## Number of obs: 127, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                                       Estimate Std. Error         df t value
## (Intercept)                          1.537e-01  7.083e-03  9.633e+00  21.705
## Treatment_bisFull                    6.617e-03  4.990e-03  1.093e+02   1.326
## Treatment_bisSmart                  -1.545e-03  7.544e-03  1.107e+02  -0.205
## SexMale                             -1.263e-03  3.811e-03  1.106e+02  -0.331
## RegionLuxembourg                    -4.800e-03  9.179e-03  1.221e+01  -0.523
## Treatment_bisFull:SexMale           -3.901e-03  5.950e-03  1.098e+02  -0.656
## Treatment_bisSmart:SexMale           2.254e-02  8.942e-03  1.136e+02   2.520
## Treatment_bisFull:RegionLuxembourg  -6.839e-04  5.870e-03  1.094e+02  -0.117
## Treatment_bisSmart:RegionLuxembourg -5.974e-03  8.843e-03  1.128e+02  -0.676
##                                     Pr(>|t|)    
## (Intercept)                         1.67e-09 ***
## Treatment_bisFull                     0.1876    
## Treatment_bisSmart                    0.8381    
## SexMale                               0.7410    
## RegionLuxembourg                      0.6103    
## Treatment_bisFull:SexMale             0.5134    
## Treatment_bisSmart:SexMale            0.0131 *  
## Treatment_bisFull:RegionLuxembourg    0.9075    
## Treatment_bisSmart:RegionLuxembourg   0.5007    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S SexMal RgnLxm T_F:SM T_S:SM T_F:RL
## Trtmnt_bsFl -0.249                                                 
## Trtmnt_bsSm -0.162  0.252                                          
## SexMale     -0.203  0.295  0.240                                   
## ReginLxmbrg -0.592  0.114  0.036 -0.063                            
## Trtmnt_F:SM  0.139 -0.588 -0.164 -0.642  0.051                     
## Trtmnt_S:SM  0.082 -0.136 -0.516 -0.448  0.084  0.301              
## Trtmnt_F:RL  0.140 -0.525 -0.103  0.062 -0.274 -0.038 -0.053       
## Trtmnt_S:RL  0.086 -0.116 -0.495  0.041 -0.208 -0.048 -0.177  0.297
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Vérification des hypothèses

qqnorm(resid(LM_Pupa_mass_OP))
qqline(resid(LM_Pupa_mass_OP))

Homogénité des variances

plot(LM_Pupa_mass_OP)

Distance de cook

plot(cooks.distance(LM_Pupa_mass_OP))

6.11.2 Simplification du modèle

drop1(LM_Pupa_mass_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Pupa_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##                          Sum Sq    Mean Sq NumDF DenDF F value  Pr(>F)  
## Treatment_bis:Sex    0.00187894 0.00093947     2 111.5  4.2775 0.01622 *
## Treatment_bis:Region 0.00010196 0.00005098     2 110.9  0.2321 0.79323  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Pupa_mass1_OP <- update(LM_Pupa_mass_OP, . ~ . - Treatment_bis:Region)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Pupa_mass1_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Pupa_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex
##                       Sum Sq    Mean Sq NumDF   DenDF F value  Pr(>F)  
## Region            0.00010102 0.00010102     1  10.197  0.4656 0.51024  
## Treatment_bis:Sex 0.00178994 0.00089497     2 113.059  4.1247 0.01866 *
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Il n’y a plus aucune interaction non significative, nous arrêtons la simplification du modèle

Regardons si les simplifications étaient utiles

AIC(LM_Pupa_mass1_OP)
## [1] -606.8376
AIC(LM_Pupa_mass_OP)
## [1] -587.1425

Elle l’a été

LM_Pupa_mass <- LM_Pupa_mass1_OP

6.11.3 Treatment VS Treatment_bis

AIC(lmer(Pupa_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Sex, data = Data_OP))
## boundary (singular) fit: see help('isSingular')
## [1] -606.8376
AIC(lmer(Pupa_mass ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment:Sex, data = Data_OP))
## boundary (singular) fit: see help('isSingular')
## [1] -608.3169
summary(lmer(Pupa_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Sex, data = Data_OP))$coeff
## boundary (singular) fit: see help('isSingular')
##                                Estimate  Std. Error         df    t value
## (Intercept)                 0.154060690 0.006944391   9.198834 22.1849084
## Treatment_bisFull           0.006456355 0.004216502 111.784885  1.5312110
## Treatment_bisSmart         -0.004095014 0.006506692 115.348376 -0.6293542
## SexMale                    -0.001174378 0.003779701 112.697540 -0.3107067
## RegionLuxembourg           -0.005899060 0.008645588  10.197294 -0.6823202
## Treatment_bisFull:SexMale  -0.004085283 0.005905066 111.790778 -0.6918269
## Treatment_bisSmart:SexMale  0.021472735 0.008746241 114.718190  2.4550814
##                                Pr(>|t|)
## (Intercept)                2.661037e-09
## Treatment_bisFull          1.285424e-01
## Treatment_bisSmart         5.303617e-01
## SexMale                    7.565975e-01
## RegionLuxembourg           5.102381e-01
## Treatment_bisFull:SexMale  4.904804e-01
## Treatment_bisSmart:SexMale 1.558609e-02
summary(lmer(Pupa_mass ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment:Sex, data = Data_OP))$coeff
## boundary (singular) fit: see help('isSingular')
##                            Estimate  Std. Error        df    t value
## (Intercept)             0.151867449 0.006893828  13.59328 22.0294804
## TreatmentFull           0.008451858 0.004585248 111.14771  1.8432717
## TreatmentSmart          0.003882641 0.004424789 112.44766  0.8774748
## SexMale                -0.002138311 0.004517490 112.73565 -0.4733405
## RegionLuxembourg       -0.005874209 0.008869863  10.24985 -0.6622661
## TreatmentFull:SexMale  -0.002890346 0.006435103 112.30863 -0.4491530
## TreatmentSmart:SexMale  0.012373029 0.006717551 111.55568  1.8418958
##                            Pr(>|t|)
## (Intercept)            4.988168e-12
## TreatmentFull          6.795368e-02
## TreatmentSmart         3.820997e-01
## SexMale                6.368855e-01
## RegionLuxembourg       5.224121e-01
## TreatmentFull:SexMale  6.541868e-01
## TreatmentSmart:SexMale 6.814661e-02

Treatment à l’air d’être meilleur

6.11.4 Résultats

Analyse des p-val

summary(lmer(Pupa_mass ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment:Sex, data = Data_OP))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Pupa_mass ~ Treatment + Sex + Region + (1 | Mother) + (1 | Site) +  
##     (1 | Room) + Treatment:Sex
##    Data: Data_OP
## 
## REML criterion at convergence: -630.3
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.5331 -0.5876 -0.0413  0.7036  2.3827 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 2.002e-04 0.014151
##  Site     (Intercept) 0.000e+00 0.000000
##  Room     (Intercept) 5.938e-06 0.002437
##  Residual             2.124e-04 0.014573
## Number of obs: 127, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                          Estimate Std. Error         df t value Pr(>|t|)    
## (Intercept)              0.151867   0.006894  13.593281  22.029 4.99e-12 ***
## TreatmentFull            0.008452   0.004585 111.147714   1.843   0.0680 .  
## TreatmentSmart           0.003883   0.004425 112.447660   0.877   0.3821    
## SexMale                 -0.002138   0.004517 112.735651  -0.473   0.6369    
## RegionLuxembourg        -0.005874   0.008870  10.249851  -0.662   0.5224    
## TreatmentFull:SexMale   -0.002890   0.006435 112.308634  -0.449   0.6542    
## TreatmentSmart:SexMale   0.012373   0.006718 111.555678   1.842   0.0681 .  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TrtmnF TrtmnS SexMal RgnLxm TrF:SM
## TreatmntFll -0.299                                   
## TretmntSmrt -0.296  0.496                            
## SexMale     -0.284  0.476  0.480                     
## ReginLxmbrg -0.597 -0.034 -0.049 -0.058              
## TrtmntFl:SM  0.213 -0.727 -0.362 -0.717  0.048       
## TrtmntSm:SM  0.196 -0.343 -0.664 -0.674  0.057  0.499
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(Pupa_mass ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment:Sex, data = Data_OP_ref_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Pupa_mass ~ Treatment + Sex + Region + (1 | Mother) + (1 | Site) +  
##     (1 | Room) + Treatment:Sex
##    Data: Data_OP_ref_smart
## 
## REML criterion at convergence: -630.3
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.5331 -0.5876 -0.0413  0.7036  2.3827 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 2.002e-04 0.014151
##  Site     (Intercept) 0.000e+00 0.000000
##  Room     (Intercept) 5.938e-06 0.002437
##  Residual             2.124e-04 0.014573
## Number of obs: 127, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                         Estimate Std. Error         df t value Pr(>|t|)    
## (Intercept)             0.155750   0.007003  14.260607  22.239 1.79e-12 ***
## TreatmentDark          -0.003883   0.004425 112.447660  -0.877   0.3821    
## TreatmentFull           0.004569   0.004523 111.573392   1.010   0.3146    
## SexMale                 0.010235   0.004961 112.329307   2.063   0.0414 *  
## RegionLuxembourg       -0.005874   0.008870  10.249851  -0.662   0.5224    
## TreatmentDark:SexMale  -0.012373   0.006718 111.555678  -1.842   0.0681 .  
## TreatmentFull:SexMale  -0.015263   0.006586 110.955659  -2.318   0.0223 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TrtmnD TrtmnF SexMal RgnLxm TrD:SM
## TreatmntDrk -0.340                                   
## TreatmntFll -0.314  0.475                            
## SexMale     -0.285  0.462  0.421                     
## ReginLxmbrg -0.618  0.049  0.013  0.024              
## TrtmntDr:SM  0.226 -0.664 -0.302 -0.740 -0.057       
## TrtmntFl:SM  0.212 -0.324 -0.682 -0.733 -0.011  0.532
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(Pupa_mass ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment:Sex, data = Data_OP_ref_full))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Pupa_mass ~ Treatment + Sex + Region + (1 | Mother) + (1 | Site) +  
##     (1 | Room) + Treatment:Sex
##    Data: Data_OP_ref_full
## 
## REML criterion at convergence: -630.3
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.5331 -0.5876 -0.0413  0.7036  2.3827 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 2.002e-04 0.014151
##  Site     (Intercept) 0.000e+00 0.000000
##  Room     (Intercept) 5.938e-06 0.002437
##  Residual             2.124e-04 0.014573
## Number of obs: 127, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                          Estimate Std. Error         df t value Pr(>|t|)    
## (Intercept)              0.160319   0.007044  14.818028  22.760 6.13e-13 ***
## TreatmentDark           -0.008452   0.004585 111.147714  -1.843   0.0680 .  
## TreatmentSmart          -0.004569   0.004523 111.573392  -1.010   0.3146    
## SexMale                 -0.005029   0.004485 111.265633  -1.121   0.2646    
## RegionLuxembourg        -0.005874   0.008870  10.249851  -0.662   0.5224    
## TreatmentDark:SexMale    0.002890   0.006435 112.308634   0.449   0.6542    
## TreatmentSmart:SexMale   0.015263   0.006586 110.955659   2.318   0.0223 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TrtmnD TrtmnS SexMal RgnLxm TrD:SM
## TreatmntDrk -0.358                                   
## TretmntSmrt -0.330  0.528                            
## SexMale     -0.348  0.563  0.536                     
## ReginLxmbrg -0.606  0.034 -0.013  0.011              
## TrtmntDr:SM  0.265 -0.727 -0.382 -0.712 -0.048       
## TrtmntSm:SM  0.227 -0.360 -0.682 -0.658  0.011  0.468
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
test1 <- data.frame(Reference = "Dark", as.data.frame(( summary(lmer(Pupa_mass ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment:Sex, data = Data_OP))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test2 <- data.frame(Reference = "Smart", as.data.frame(( summary(lmer(Pupa_mass ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment:Sex, data = Data_OP_ref_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test3 <- data.frame(Reference = "Full", as.data.frame(( summary(lmer(Pupa_mass ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment:Sex, data = Data_OP_ref_full))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
Results_Pupa_mass_OP <- rbind(test1,test2,test3)

colnames(Results_Pupa_mass_OP ) <- c("Reference","Estimate", "Std. Error", "df", "t.value", "Pr(>|z|)")

write.csv2( Results_Pupa_mass_OP , file = "output/Results_Pupa_mass_OP.csv" )

kable(Results_Pupa_mass_OP , caption = " Poids des chrysalides OP ", padding = 1 )
Poids des chrysalides OP
Reference Estimate Std. Error df t.value Pr(>|z|)
(Intercept) Dark 0.1518674 0.0068938 13.59328 22.0294804 0.0000000
TreatmentFull Dark 0.0084519 0.0045852 111.14771 1.8432717 0.0679537
TreatmentSmart Dark 0.0038826 0.0044248 112.44766 0.8774748 0.3820997
SexMale Dark -0.0021383 0.0045175 112.73565 -0.4733405 0.6368855
RegionLuxembourg Dark -0.0058742 0.0088699 10.24985 -0.6622661 0.5224121
TreatmentFull:SexMale Dark -0.0028903 0.0064351 112.30863 -0.4491530 0.6541868
TreatmentSmart:SexMale Dark 0.0123730 0.0067176 111.55568 1.8418958 0.0681466
(Intercept)1 Smart 0.1557501 0.0070034 14.26061 22.2390888 0.0000000
TreatmentDark Smart -0.0038826 0.0044248 112.44766 -0.8774748 0.3820997
TreatmentFull1 Smart 0.0045692 0.0045230 111.57339 1.0102160 0.3145776
SexMale1 Smart 0.0102347 0.0049607 112.32931 2.0631748 0.0414011
RegionLuxembourg1 Smart -0.0058742 0.0088699 10.24985 -0.6622661 0.5224121
TreatmentDark:SexMale Smart -0.0123730 0.0067176 111.55568 -1.8418958 0.0681466
TreatmentFull:SexMale1 Smart -0.0152634 0.0065856 110.95566 -2.3176776 0.0223008
(Intercept)2 Full 0.1603193 0.0070438 14.81803 22.7602580 0.0000000
TreatmentDark1 Full -0.0084519 0.0045852 111.14771 -1.8432717 0.0679537
TreatmentSmart1 Full -0.0045692 0.0045230 111.57339 -1.0102160 0.3145776
SexMale2 Full -0.0050287 0.0044845 111.26563 -1.1213405 0.2645572
RegionLuxembourg2 Full -0.0058742 0.0088699 10.24985 -0.6622661 0.5224121
TreatmentDark:SexMale1 Full 0.0028903 0.0064351 112.30863 0.4491530 0.6541868
TreatmentSmart:SexMale1 Full 0.0152634 0.0065856 110.95566 2.3176776 0.0223008
Info_Pupa_mass_OP <- "
Les chrysalides du traitement Full sont quasiment significativement (p-val = 0.0680) plus légères (0.0085 g)  que celels du traitement Dark.
Les chrysalides des individus mâles du traitement Smart sont significativement (p-val = 0.0223) plus lourdes (0.015 g) que l'effet de mâle et du traitement Smart additioné comparé au traitement Full.
Les mâles sont significativements (p-val = 0.041) plus lourd (0.010 g) que les femelles dans le traitement Smart.
"
Info_Pupa_mass_OP
## [1] "\nLes chrysalides du traitement Full sont quasiment significativement (p-val = 0.0680) plus légères (0.0085 g)  que celels du traitement Dark.\nLes chrysalides des individus mâles du traitement Smart sont significativement (p-val = 0.0223) plus lourdes (0.015 g) que l'effet de mâle et du traitement Smart additioné comparé au traitement Full.\nLes mâles sont significativements (p-val = 0.041) plus lourd (0.010 g) que les femelles dans le traitement Smart.\n"

6.12 Pupa_mass AE

6.12.1 Test

LM_Pupa_mass_AE <- lmer(Pupa_mass ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_AE)
## boundary (singular) fit: see help('isSingular')
summary(LM_Pupa_mass_AE)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Pupa_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data_AE
## 
## REML criterion at convergence: -371.9
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.3033 -0.6809 -0.1277  0.6045  2.4322 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0004491 0.02119 
##  Site     (Intercept) 0.0009460 0.03076 
##  Room     (Intercept) 0.0000000 0.00000 
##  Residual             0.0033237 0.05765 
## Number of obs: 161, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                                0.325002   0.019798  19.931133
## Treatment_bisFull                          0.013028   0.018470 135.678533
## Treatment_bisSmart                         0.012277   0.021295 135.491562
## Treatment_bisMixt_smart                    0.057756   0.021882 136.517747
## SexMale                                    0.028060   0.017182 139.948127
## RegionLuxembourg                           0.003959   0.026362  18.609779
## Treatment_bisFull:SexMale                 -0.001725   0.023850 138.111303
## Treatment_bisSmart:SexMale                -0.057238   0.028821 143.074150
## Treatment_bisMixt_smart:SexMale           -0.065912   0.028524 140.043272
## Treatment_bisFull:RegionLuxembourg         0.018949   0.023788 136.126736
## Treatment_bisSmart:RegionLuxembourg        0.015090   0.026825 133.114322
## Treatment_bisMixt_smart:RegionLuxembourg   0.050850   0.027983 138.087984
##                                          t value Pr(>|t|)    
## (Intercept)                               16.416  4.8e-13 ***
## Treatment_bisFull                          0.705  0.48179    
## Treatment_bisSmart                         0.577  0.56523    
## Treatment_bisMixt_smart                    2.639  0.00927 ** 
## SexMale                                    1.633  0.10469    
## RegionLuxembourg                           0.150  0.88223    
## Treatment_bisFull:SexMale                 -0.072  0.94244    
## Treatment_bisSmart:SexMale                -1.986  0.04894 *  
## Treatment_bisMixt_smart:SexMale           -2.311  0.02231 *  
## Treatment_bisFull:RegionLuxembourg         0.797  0.42709    
## Treatment_bisSmart:RegionLuxembourg        0.563  0.57470    
## Treatment_bisMixt_smart:RegionLuxembourg   1.817  0.07136 .  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_F:SM T_S:SM T_M_:S
## Trtmnt_bsFl -0.462                                                        
## Trtmnt_bsSm -0.403  0.431                                                 
## Trtmnt_bsM_ -0.394  0.421  0.371                                          
## SexMale     -0.356  0.380  0.334  0.331                                   
## ReginLxmbrg -0.640  0.233  0.198  0.192 -0.046                            
## Trtmnt_F:SM  0.248 -0.569 -0.239 -0.240 -0.716  0.031                     
## Trtmnt_S:SM  0.226 -0.234 -0.491 -0.215 -0.602  0.019  0.431              
## Trtmn_M_:SM  0.201 -0.227 -0.205 -0.553 -0.611  0.041  0.440  0.384       
## Trtmnt_F:RL  0.247 -0.511 -0.224 -0.213  0.030 -0.459 -0.025 -0.020 -0.032
## Trtmnt_S:RL  0.206 -0.224 -0.575 -0.186  0.041 -0.403 -0.029 -0.050 -0.033
## Trtmn_M_:RL  0.211 -0.219 -0.178 -0.511  0.036 -0.396 -0.026 -0.046 -0.057
##             T_F:RL T_S:RL
## Trtmnt_bsFl              
## Trtmnt_bsSm              
## Trtmnt_bsM_              
## SexMale                  
## ReginLxmbrg              
## Trtmnt_F:SM              
## Trtmnt_S:SM              
## Trtmn_M_:SM              
## Trtmnt_F:RL              
## Trtmnt_S:RL  0.447       
## Trtmn_M_:RL  0.446  0.386
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Vérification des hypothèses

qqnorm(resid(LM_Pupa_mass_AE))
qqline(resid(LM_Pupa_mass_AE))

Homogénité des variances

plot(LM_Pupa_mass_AE)

Distance de cook

plot(cooks.distance(LM_Pupa_mass_AE))

6.12.2 Simplification du modèle

drop1(LM_Pupa_mass_AE)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Pupa_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##                        Sum Sq   Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Sex    0.029970 0.0099900     3 140.26  3.0057 0.03251 *
## Treatment_bis:Region 0.011055 0.0036849     3 135.03  1.1087 0.34794  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Pupa_mass1_AE <- update(LM_Pupa_mass_AE, . ~ . - Treatment_bis:Region)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Pupa_mass1_AE)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Pupa_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex
##                      Sum Sq   Mean Sq NumDF   DenDF F value  Pr(>F)  
## Region            0.0034995 0.0034995     1   9.672  1.0424 0.33211  
## Treatment_bis:Sex 0.0279772 0.0093257     3 143.934  2.7780 0.04341 *
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Il n’y a plus aucune interaction non significative, nous arrêtons la simplification du modèle

Regardons si les simplifications étaient utiles

AIC(LM_Pupa_mass1_AE)
## [1] -359.5025
AIC(LM_Pupa_mass_AE)
## [1] -339.9384

Elle l’a été

LM_Pupa_mass <- LM_Pupa_mass1_AE

6.12.3 Treatment VS Treatment_bis

AIC(lmer(Pupa_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Sex, data = Data_AE))
## boundary (singular) fit: see help('isSingular')
## [1] -359.5025
AIC(lmer(Pupa_mass ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment:Sex, data = Data_AE))
## [1] -365.9949
summary(lmer(Pupa_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Sex, data = Data_AE))$coeff
## boundary (singular) fit: see help('isSingular')
##                                      Estimate Std. Error         df     t value
## (Intercept)                      0.3176877678 0.01867902  17.465600 17.00773048
## Treatment_bisFull                0.0202478780 0.01594034 139.663529  1.27022903
## Treatment_bisSmart               0.0173217169 0.01744408 141.721782  0.99298516
## Treatment_bisMixt_smart          0.0780836889 0.01887122 142.688894  4.13771246
## SexMale                          0.0269688312 0.01722325 143.882597  1.56583867
## RegionLuxembourg                 0.0221783122 0.02172206   9.672011  1.02100416
## Treatment_bisFull:SexMale       -0.0004494336 0.02392421 141.913220 -0.01878572
## Treatment_bisSmart:SexMale      -0.0545609755 0.02884039 146.305545 -1.89182534
## Treatment_bisMixt_smart:SexMale -0.0627545333 0.02857574 143.939336 -2.19607694
##                                     Pr(>|t|)
## (Intercept)                     2.614820e-12
## Treatment_bisFull               2.061151e-01
## Treatment_bisSmart              3.224096e-01
## Treatment_bisMixt_smart         5.967512e-05
## SexMale                         1.195831e-01
## RegionLuxembourg                3.321110e-01
## Treatment_bisFull:SexMale       9.850384e-01
## Treatment_bisSmart:SexMale      6.049034e-02
## Treatment_bisMixt_smart:SexMale 2.968718e-02
summary(lmer(Pupa_mass ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment:Sex, data = Data_AE))$coeff
##                            Estimate Std. Error         df    t value
## (Intercept)             0.321391127 0.02258020   6.286076 14.2333174
## TreatmentFull           0.014566306 0.01633438 141.411446  0.8917577
## TreatmentSmart          0.041384586 0.01545358 144.527372  2.6779938
## SexMale                 0.023161649 0.01758617 145.440882  1.3170375
## RegionLuxembourg        0.022531502 0.02155884   9.489238  1.0451166
## TreatmentFull:SexMale   0.009449579 0.02461249 144.079375  0.3839342
## TreatmentSmart:SexMale -0.051189438 0.02418489 147.588893 -2.1165874
##                            Pr(>|t|)
## (Intercept)            5.110065e-06
## TreatmentFull          3.740377e-01
## TreatmentSmart         8.264155e-03
## SexMale                1.898974e-01
## RegionLuxembourg       3.218609e-01
## TreatmentFull:SexMale  7.015932e-01
## TreatmentSmart:SexMale 3.597253e-02

Treatment à l’air d’être meilleur pour expliquer les données (AIc) mais le traitement Mixt Smart est fort significatif donc je préfère garder Treatment_bis

6.12.4 Résultats

Analyse des p-val

summary(lmer(Pupa_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Sex, data = Data_AE))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Pupa_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex
##    Data: Data_AE
## 
## REML criterion at convergence: -385.5
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.29190 -0.55172 -0.09124  0.58741  2.52972 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0003927 0.01982 
##  Site     (Intercept) 0.0009053 0.03009 
##  Room     (Intercept) 0.0000000 0.00000 
##  Residual             0.0033570 0.05794 
## Number of obs: 161, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                   Estimate Std. Error         df t value
## (Intercept)                      3.177e-01  1.868e-02  1.747e+01  17.008
## Treatment_bisFull                2.025e-02  1.594e-02  1.397e+02   1.270
## Treatment_bisSmart               1.732e-02  1.744e-02  1.417e+02   0.993
## Treatment_bisMixt_smart          7.808e-02  1.887e-02  1.427e+02   4.138
## SexMale                          2.697e-02  1.722e-02  1.439e+02   1.566
## RegionLuxembourg                 2.218e-02  2.172e-02  9.672e+00   1.021
## Treatment_bisFull:SexMale       -4.494e-04  2.392e-02  1.419e+02  -0.019
## Treatment_bisSmart:SexMale      -5.456e-02  2.884e-02  1.463e+02  -1.892
## Treatment_bisMixt_smart:SexMale -6.275e-02  2.858e-02  1.439e+02  -2.196
##                                 Pr(>|t|)    
## (Intercept)                     2.61e-12 ***
## Treatment_bisFull                 0.2061    
## Treatment_bisSmart                0.3224    
## Treatment_bisMixt_smart         5.97e-05 ***
## SexMale                           0.1196    
## RegionLuxembourg                  0.3321    
## Treatment_bisFull:SexMale         0.9850    
## Treatment_bisSmart:SexMale        0.0605 .  
## Treatment_bisMixt_smart:SexMale   0.0297 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_F:SM T_S:SM
## Trtmnt_bsFl -0.418                                                 
## Trtmnt_bsSm -0.383  0.455                                          
## Trtmnt_bsM_ -0.359  0.429  0.408                                   
## SexMale     -0.392  0.460  0.437  0.407                            
## ReginLxmbrg -0.597  0.002 -0.023 -0.006 -0.026                     
## Trtmnt_F:SM  0.274 -0.676 -0.311 -0.294 -0.715  0.014              
## Trtmnt_S:SM  0.254 -0.284 -0.636 -0.277 -0.602 -0.008  0.430       
## Trtmn_M_:SM  0.230 -0.282 -0.271 -0.678 -0.610  0.017  0.439  0.382
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(Pupa_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Sex, data = Data_AE_ref_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Pupa_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex
##    Data: Data_AE_ref_smart
## 
## REML criterion at convergence: -385.5
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.29190 -0.55172 -0.09124  0.58741  2.52972 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0003927 0.01982 
##  Site     (Intercept) 0.0009053 0.03009 
##  Room     (Intercept) 0.0000000 0.00000 
##  Residual             0.0033570 0.05794 
## Number of obs: 161, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                   Estimate Std. Error         df t value
## (Intercept)                       0.335009   0.020083  23.820039  16.681
## Treatment_bisDark                -0.017322   0.017444 141.721782  -0.993
## Treatment_bisFull                 0.002926   0.017482 140.618688   0.167
## Treatment_bisMixt_smart           0.060762   0.019801 138.188503   3.069
## SexMale                          -0.027592   0.023038 146.896488  -1.198
## RegionLuxembourg                  0.022178   0.021722   9.672011   1.021
## Treatment_bisDark:SexMale         0.054561   0.028840 146.305545   1.892
## Treatment_bisFull:SexMale         0.054112   0.028477 145.207243   1.900
## Treatment_bisMixt_smart:SexMale  -0.008194   0.031910 143.692041  -0.257
##                                 Pr(>|t|)    
## (Intercept)                     1.22e-14 ***
## Treatment_bisDark                0.32241    
## Treatment_bisFull                0.86731    
## Treatment_bisMixt_smart          0.00259 ** 
## SexMale                          0.23296    
## RegionLuxembourg                 0.33211    
## Treatment_bisDark:SexMale        0.06049 .  
## Treatment_bisFull:SexMale        0.05939 .  
## Treatment_bisMixt_smart:SexMale  0.79772    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trt_M_ SexMal RgnLxm T_D:SM T_F:SM
## Trtmnt_bsDr -0.512                                                 
## Trtmnt_bsFl -0.506  0.583                                          
## Trtmnt_bsM_ -0.432  0.493  0.499                                   
## SexMale     -0.384  0.469  0.458  0.373                            
## ReginLxmbrg -0.575  0.023  0.024  0.015 -0.029                     
## Trtmnt_D:SM  0.316 -0.636 -0.376 -0.296 -0.802  0.008              
## Trtmnt_F:SM  0.307 -0.383 -0.638 -0.306 -0.809  0.020  0.652       
## Trtmn_M_:SM  0.266 -0.332 -0.328 -0.633 -0.705  0.022  0.561  0.573
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(Pupa_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Sex, data = Data_AE_ref_full))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Pupa_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex
##    Data: Data_AE_ref_full
## 
## REML criterion at convergence: -385.5
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.29190 -0.55172 -0.09124  0.58741  2.52972 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0003927 0.01982 
##  Site     (Intercept) 0.0009053 0.03009 
##  Room     (Intercept) 0.0000000 0.00000 
##  Residual             0.0033570 0.05794 
## Number of obs: 161, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                   Estimate Std. Error         df t value
## (Intercept)                      3.379e-01  1.881e-02  1.828e+01  17.963
## Treatment_bisDark               -2.025e-02  1.594e-02  1.397e+02  -1.270
## Treatment_bisSmart              -2.926e-03  1.748e-02  1.406e+02  -0.167
## Treatment_bisMixt_smart          5.784e-02  1.877e-02  1.401e+02   3.082
## SexMale                          2.652e-02  1.673e-02  1.403e+02   1.586
## RegionLuxembourg                 2.218e-02  2.172e-02  9.672e+00   1.021
## Treatment_bisDark:SexMale        4.494e-04  2.392e-02  1.419e+02   0.019
## Treatment_bisSmart:SexMale      -5.411e-02  2.848e-02  1.452e+02  -1.900
## Treatment_bisMixt_smart:SexMale -6.231e-02  2.808e-02  1.412e+02  -2.219
##                                 Pr(>|t|)    
## (Intercept)                     4.57e-13 ***
## Treatment_bisDark                0.20612    
## Treatment_bisSmart               0.86731    
## Treatment_bisMixt_smart          0.00248 ** 
## SexMale                          0.11510    
## RegionLuxembourg                 0.33211    
## Treatment_bisDark:SexMale        0.98504    
## Treatment_bisSmart:SexMale       0.05939 .  
## Treatment_bisMixt_smart:SexMale  0.02809 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S Trt_M_ SexMal RgnLxm T_D:SM T_S:SM
## Trtmnt_bsDr -0.432                                                 
## Trtmnt_bsSm -0.390  0.458                                          
## Trtmnt_bsM_ -0.361  0.418  0.405                                   
## SexMale     -0.430  0.494  0.455  0.417                            
## ReginLxmbrg -0.592 -0.002 -0.024 -0.007 -0.006                     
## Trtmnt_D:SM  0.301 -0.676 -0.306 -0.278 -0.694 -0.014              
## Trtmnt_S:SM  0.265 -0.280 -0.638 -0.271 -0.588 -0.020  0.405       
## Trtmn_M_:SM  0.245 -0.289 -0.274 -0.687 -0.591  0.005  0.405  0.363
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(Pupa_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Sex, data = Data_AE_ref_mixt_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Pupa_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex
##    Data: Data_AE_ref_mixt_smart
## 
## REML criterion at convergence: -385.5
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.29190 -0.55172 -0.09124  0.58741  2.52972 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0003927 0.01982 
##  Site     (Intercept) 0.0009053 0.03009 
##  Room     (Intercept) 0.0000000 0.00000 
##  Residual             0.0033570 0.05794 
## Number of obs: 161, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                              Estimate Std. Error         df t value Pr(>|t|)
## (Intercept)                  0.395771   0.021251  28.473561  18.624  < 2e-16
## Treatment_bisDark           -0.078084   0.018871 142.688894  -4.138 5.97e-05
## Treatment_bisFull           -0.057836   0.018769 140.139050  -3.082  0.00248
## Treatment_bisSmart          -0.060762   0.019801 138.188503  -3.069  0.00259
## SexMale                     -0.035786   0.022648 143.319886  -1.580  0.11630
## RegionLuxembourg             0.022178   0.021722   9.672011   1.021  0.33211
## Treatment_bisDark:SexMale    0.062755   0.028576 143.939336   2.196  0.02969
## Treatment_bisFull:SexMale    0.062305   0.028079 141.212963   2.219  0.02809
## Treatment_bisSmart:SexMale   0.008194   0.031910 143.692041   0.257  0.79772
##                               
## (Intercept)                ***
## Treatment_bisDark          ***
## Treatment_bisFull          ** 
## Treatment_bisSmart         ** 
## SexMale                       
## RegionLuxembourg              
## Treatment_bisDark:SexMale  *  
## Treatment_bisFull:SexMale  *  
## Treatment_bisSmart:SexMale    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trtm_S SexMal RgnLxm T_D:SM T_F:SM
## Trtmnt_bsDr -0.572                                                 
## Trtmnt_bsFl -0.564  0.641                                          
## Trtmnt_bsSm -0.523  0.594  0.590                                   
## SexMale     -0.492  0.546  0.543  0.512                            
## ReginLxmbrg -0.530  0.006  0.007 -0.015  0.002                     
## Trtmnt_D:SM  0.400 -0.678 -0.442 -0.407 -0.798 -0.017              
## Trtmnt_F:SM  0.390 -0.439 -0.687 -0.409 -0.803 -0.005  0.643       
## Trtmnt_S:SM  0.338 -0.357 -0.362 -0.633 -0.692 -0.022  0.550  0.556
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
test1 <- data.frame(Reference = "Dark", as.data.frame(( summary(lmer(Pupa_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Sex, data = Data_AE))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test2 <- data.frame(Reference = "Smart", as.data.frame(( summary(lmer(Pupa_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Sex, data = Data_AE_ref_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test3 <- data.frame(Reference = "Full", as.data.frame(( summary(lmer(Pupa_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Sex, data = Data_AE_ref_full))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test4 <- data.frame(Reference = "Mixt_smart", as.data.frame(( summary(lmer(Pupa_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Sex, data = Data_AE_ref_mixt_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
Results_Pupa_mass_AE <- rbind(test1,test2,test3,test4)

colnames(Results_Pupa_mass_AE ) <- c("Reference","Estimate", "Std. Error", "df", "t.value", "Pr(>|z|)")

write.csv2( Results_Pupa_mass_AE , file = "output/Results_Pupa_mass_AE.csv" )

kable(Results_Pupa_mass_AE , caption = " Poids des chrysalides AE ", padding = 1 )
Poids des chrysalides AE
Reference Estimate Std. Error df t.value Pr(>|z|)
(Intercept) Dark 0.3176878 0.0186790 17.465600 17.0077305 0.0000000
Treatment_bisFull Dark 0.0202479 0.0159403 139.663529 1.2702290 0.2061151
Treatment_bisSmart Dark 0.0173217 0.0174441 141.721782 0.9929852 0.3224096
Treatment_bisMixt_smart Dark 0.0780837 0.0188712 142.688894 4.1377125 0.0000597
SexMale Dark 0.0269688 0.0172233 143.882597 1.5658387 0.1195831
RegionLuxembourg Dark 0.0221783 0.0217221 9.672011 1.0210042 0.3321110
Treatment_bisFull:SexMale Dark -0.0004494 0.0239242 141.913220 -0.0187857 0.9850384
Treatment_bisSmart:SexMale Dark -0.0545610 0.0288404 146.305545 -1.8918253 0.0604903
Treatment_bisMixt_smart:SexMale Dark -0.0627545 0.0285757 143.939336 -2.1960769 0.0296872
(Intercept)1 Smart 0.3350095 0.0200830 23.820039 16.6812224 0.0000000
Treatment_bisDark Smart -0.0173217 0.0174441 141.721782 -0.9929852 0.3224096
Treatment_bisFull1 Smart 0.0029262 0.0174816 140.618688 0.1673856 0.8673072
Treatment_bisMixt_smart1 Smart 0.0607620 0.0198012 138.188503 3.0685988 0.0025890
SexMale1 Smart -0.0275921 0.0230377 146.896488 -1.1976961 0.2329643
RegionLuxembourg1 Smart 0.0221783 0.0217221 9.672011 1.0210042 0.3321110
Treatment_bisDark:SexMale Smart 0.0545610 0.0288404 146.305545 1.8918253 0.0604903
Treatment_bisFull:SexMale1 Smart 0.0541115 0.0284773 145.207243 1.9001668 0.0593935
Treatment_bisMixt_smart:SexMale1 Smart -0.0081936 0.0319098 143.692041 -0.2567722 0.7977219
(Intercept)2 Full 0.3379356 0.0188129 18.283861 17.9629383 0.0000000
Treatment_bisDark1 Full -0.0202479 0.0159403 139.663529 -1.2702290 0.2061151
Treatment_bisSmart1 Full -0.0029262 0.0174816 140.618688 -0.1673856 0.8673072
Treatment_bisMixt_smart2 Full 0.0578358 0.0187687 140.139050 3.0815079 0.0024800
SexMale2 Full 0.0265194 0.0167261 140.309076 1.5855137 0.1151009
RegionLuxembourg2 Full 0.0221783 0.0217221 9.672011 1.0210042 0.3321110
Treatment_bisDark:SexMale1 Full 0.0004494 0.0239242 141.913220 0.0187857 0.9850384
Treatment_bisSmart:SexMale1 Full -0.0541115 0.0284773 145.207243 -1.9001668 0.0593935
Treatment_bisMixt_smart:SexMale2 Full -0.0623051 0.0280787 141.212963 -2.2189457 0.0280862
(Intercept)3 Mixt_smart 0.3957715 0.0212510 28.473561 18.6236682 0.0000000
Treatment_bisDark2 Mixt_smart -0.0780837 0.0188712 142.688894 -4.1377125 0.0000597
Treatment_bisFull2 Mixt_smart -0.0578358 0.0187687 140.139050 -3.0815079 0.0024800
Treatment_bisSmart2 Mixt_smart -0.0607620 0.0198012 138.188503 -3.0685988 0.0025890
SexMale3 Mixt_smart -0.0357857 0.0226485 143.319886 -1.5800490 0.1163001
RegionLuxembourg3 Mixt_smart 0.0221783 0.0217221 9.672011 1.0210042 0.3321110
Treatment_bisDark:SexMale2 Mixt_smart 0.0627545 0.0285757 143.939335 2.1960769 0.0296872
Treatment_bisFull:SexMale2 Mixt_smart 0.0623051 0.0280787 141.212963 2.2189457 0.0280862
Treatment_bisSmart:SexMale2 Mixt_smart 0.0081936 0.0319098 143.692041 0.2567722 0.7977219
Info_Pupa_mass_AE <- "
Les individus du traitement Mixt-smart sont significfativement (p-val = 5.97e-05) plus lourds (0.078 g) que ceux du traitement Dark mais les mâles (toujours comparé au traitement Dark) le sont significativvement (p-val = 0.0297) moins  que les femelles (0.063 g).
Les chrysalides des individus du traitement Mixt smart sont significativements (p-val = 0.00259) plus lourd (0.061 g) que celles du traitement Smart.
Les chrysalides du traitement Mixt-smart sont significfativements (p-val = 0.00248) plus lourdes (0.058 g) que celles du traitement Full mais les mâles le sont significativvement (p-val = 0.02809) moins (0.062 g) que les femelles.
"
Info_Pupa_mass_AE
## [1] "\nLes individus du traitement Mixt-smart sont significfativement (p-val = 5.97e-05) plus lourds (0.078 g) que ceux du traitement Dark mais les mâles (toujours comparé au traitement Dark) le sont significativvement (p-val = 0.0297) moins  que les femelles (0.063 g).\nLes chrysalides des individus du traitement Mixt smart sont significativements (p-val = 0.00259) plus lourd (0.061 g) que celles du traitement Smart.\nLes chrysalides du traitement Mixt-smart sont significfativements (p-val = 0.00248) plus lourdes (0.058 g) que celles du traitement Full mais les mâles le sont significativvement (p-val = 0.02809) moins (0.062 g) que les femelles.\n"

6.13 Adult_mass OP

6.13.1 Test

LM_Adult_mass_OP <- lmer(Adult_mass ~ Treatment_bis + Sex  + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_OP)
## boundary (singular) fit: see help('isSingular')
summary(LM_Adult_mass_OP)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Adult_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data_OP
## 
## REML criterion at convergence: -639
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.27013 -0.67303 -0.03053  0.59709  2.14744 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 1.062e-05 0.003259
##  Site     (Intercept) 0.000e+00 0.000000
##  Room     (Intercept) 4.081e-06 0.002020
##  Residual             1.760e-04 0.013267
## Number of obs: 124, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                                       Estimate Std. Error         df t value
## (Intercept)                          9.058e-02  3.357e-03  6.257e+00  26.981
## Treatment_bisFull                    7.122e-03  4.693e-03  1.107e+02   1.518
## Treatment_bisSmart                  -9.629e-04  7.156e-03  1.002e+02  -0.135
## SexMale                             -1.526e-02  3.540e-03  1.132e+02  -4.309
## RegionLuxembourg                    -2.841e-03  3.952e-03  2.062e+01  -0.719
## Treatment_bisFull:SexMale           -5.211e-04  5.362e-03  1.140e+02  -0.097
## Treatment_bisSmart:SexMale           1.269e-02  7.702e-03  1.140e+02   1.648
## Treatment_bisFull:RegionLuxembourg  -2.176e-03  5.233e-03  1.082e+02  -0.416
## Treatment_bisSmart:RegionLuxembourg -2.187e-03  7.752e-03  1.112e+02  -0.282
##                                     Pr(>|t|)    
## (Intercept)                         1.03e-07 ***
## Treatment_bisFull                      0.132    
## Treatment_bisSmart                     0.893    
## SexMale                             3.51e-05 ***
## RegionLuxembourg                       0.480    
## Treatment_bisFull:SexMale              0.923    
## Treatment_bisSmart:SexMale             0.102    
## Treatment_bisFull:RegionLuxembourg     0.678    
## Treatment_bisSmart:RegionLuxembourg    0.778    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S SexMal RgnLxm T_F:SM T_S:SM T_F:RL
## Trtmnt_bsFl -0.466                                                 
## Trtmnt_bsSm -0.321  0.233                                          
## SexMale     -0.392  0.276  0.208                                   
## ReginLxmbrg -0.529  0.268  0.163 -0.059                            
## Trtmnt_F:SM  0.267 -0.571 -0.139 -0.663  0.048                     
## Trtmnt_S:SM  0.183 -0.129 -0.520 -0.472  0.042  0.315              
## Trtmnt_F:RL  0.290 -0.607 -0.130  0.046 -0.561  0.025 -0.026       
## Trtmnt_S:RL  0.190 -0.134 -0.588  0.032 -0.382 -0.030 -0.093  0.287
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Vérification des hypothèses

qqnorm(resid(LM_Adult_mass_OP))
qqline(resid(LM_Adult_mass_OP))

Homogénité des variances

plot(LM_Adult_mass_OP)

Distance de cook

plot(cooks.distance(LM_Adult_mass_OP))

6.13.2 Simplification du modèle

drop1(LM_Adult_mass_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Adult_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##                          Sum Sq    Mean Sq NumDF  DenDF F value Pr(>F)
## Treatment_bis:Sex    0.00055209 2.7605e-04     2 113.34  1.5683 0.2129
## Treatment_bis:Region 0.00003552 1.7758e-05     2 109.68  0.1009 0.9041
LM_Adult_mass1_OP <- update(LM_Adult_mass_OP, . ~ . - Treatment_bis:Region)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Adult_mass1_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Adult_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex
##                       Sum Sq    Mean Sq NumDF  DenDF F value Pr(>F)
## Region            0.00027388 0.00027388     1   8.98  1.5808 0.2404
## Treatment_bis:Sex 0.00053783 0.00026891     2 115.36  1.5521 0.2162
LM_Adult_mass2_OP <- update(LM_Adult_mass1_OP, . ~ . - Treatment_bis:Sex)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Adult_mass2_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Adult_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room)
##                  Sum Sq   Mean Sq NumDF   DenDF F value   Pr(>F)    
## Treatment_bis 0.0008031 0.0004015     2  81.241  2.3105   0.1057    
## Sex           0.0054632 0.0054632     1 115.801 31.4368 1.42e-07 ***
## Region        0.0002609 0.0002609     1   9.082  1.5012   0.2513    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Nous n’avons plus d’interaction, nous arrêtons la simplification du modèle.

Est ce que la simplification a été utile ?

AIC(LM_Adult_mass2_OP)
## [1] -651.0048
AIC(LM_Adult_mass_OP)
## [1] -612.9728

Oui

LM_Adult_mass_OP <- LM_Adult_mass2_OP

6.13.3 Treatment VS Treatment_bis

AIC(lmer(Adult_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room), data = Data_OP))
## boundary (singular) fit: see help('isSingular')
## [1] -651.0048
AIC(lmer(Adult_mass ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room), data = Data_OP))
## boundary (singular) fit: see help('isSingular')
## [1] -649.7452
summary(lmer(Adult_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room), data = Data_OP))$coeff
## boundary (singular) fit: see help('isSingular')
##                        Estimate  Std. Error         df   t value     Pr(>|t|)
## (Intercept)         0.090445370 0.003144128   4.350699 28.766444 3.941422e-06
## Treatment_bisFull   0.005501308 0.002646817 112.218247  2.078462 3.994684e-02
## Treatment_bisSmart  0.004970301 0.004038420  63.579302  1.230754 2.229487e-01
## SexMale            -0.013680069 0.002439882 115.800568 -5.606856 1.420160e-07
## RegionLuxembourg   -0.003958525 0.003230779   9.082217 -1.225254 2.513039e-01
summary(lmer(Adult_mass ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room), data = Data_OP))$coeff
## boundary (singular) fit: see help('isSingular')
##                      Estimate  Std. Error         df    t value     Pr(>|t|)
## (Intercept)       0.090346601 0.003081258  30.294326 29.3213389 8.472131e-24
## TreatmentFull     0.005370691 0.002983401 111.919560  1.8001906 7.452427e-02
## TreatmentSmart    0.001977442 0.003044249 114.410902  0.6495665 5.172743e-01
## SexMale          -0.013576680 0.002435780 115.786226 -5.5738543 1.649671e-07
## RegionLuxembourg -0.003685080 0.003187152   9.096545 -1.1562298 2.770500e-01

On va continuer avec treatment_bis

6.13.4 Résultats

Analyse des P-val

summary(lmer(Adult_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room), data = Data_OP))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Adult_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room)
##    Data: Data_OP
## 
## REML criterion at convergence: -669
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.36138 -0.66854 -0.04749  0.65191  2.14515 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 1.249e-05 0.003534
##  Site     (Intercept) 0.000e+00 0.000000
##  Room     (Intercept) 4.830e-06 0.002198
##  Residual             1.738e-04 0.013183
## Number of obs: 124, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                      Estimate Std. Error         df t value Pr(>|t|)    
## (Intercept)          0.090445   0.003144   4.350699  28.766 3.94e-06 ***
## Treatment_bisFull    0.005501   0.002647 112.218247   2.078   0.0399 *  
## Treatment_bisSmart   0.004970   0.004038  63.579302   1.231   0.2229    
## SexMale             -0.013680   0.002440 115.800568  -5.607 1.42e-07 ***
## RegionLuxembourg    -0.003959   0.003231   9.082217  -1.225   0.2513    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S SexMal
## Trtmnt_bsFl -0.286                     
## Trtmnt_bsSm -0.206  0.344              
## SexMale     -0.304 -0.142 -0.085       
## ReginLxmbrg -0.492 -0.071 -0.087  0.008
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(Adult_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room), data = Data_OP_ref_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Adult_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room)
##    Data: Data_OP_ref_smart
## 
## REML criterion at convergence: -669
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.36138 -0.66854 -0.04749  0.65191  2.14515 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 1.249e-05 0.003534
##  Site     (Intercept) 0.000e+00 0.000000
##  Room     (Intercept) 4.830e-06 0.002198
##  Residual             1.738e-04 0.013183
## Number of obs: 124, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                     Estimate Std. Error         df t value Pr(>|t|)    
## (Intercept)         0.095416   0.004579  15.194148  20.840 1.36e-12 ***
## Treatment_bisDark  -0.004970   0.004038  63.579302  -1.231    0.223    
## Treatment_bisFull   0.000531   0.003994  96.473719   0.133    0.895    
## SexMale            -0.013680   0.002440 115.800568  -5.607 1.42e-07 ***
## RegionLuxembourg   -0.003959   0.003231   9.082217  -1.225    0.251    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F SexMal
## Trtmnt_bsDr -0.741                     
## Trtmnt_bsFl -0.678  0.783              
## SexMale     -0.283  0.085 -0.008       
## ReginLxmbrg -0.415  0.087  0.041  0.008
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(Adult_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room), data = Data_OP_ref_full))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Adult_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room)
##    Data: Data_OP_ref_full
## 
## REML criterion at convergence: -669
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.36138 -0.66854 -0.04749  0.65191  2.14515 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 1.249e-05 0.003534
##  Site     (Intercept) 0.000e+00 0.000000
##  Room     (Intercept) 4.830e-06 0.002198
##  Residual             1.738e-04 0.013183
## Number of obs: 124, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                      Estimate Std. Error         df t value Pr(>|t|)    
## (Intercept)          0.095947   0.003482   6.940186  27.557 2.39e-08 ***
## Treatment_bisDark   -0.005501   0.002647 112.218248  -2.078   0.0399 *  
## Treatment_bisSmart  -0.000531   0.003994  96.473719  -0.133   0.8945    
## SexMale             -0.013680   0.002440 115.800568  -5.607 1.42e-07 ***
## RegionLuxembourg    -0.003959   0.003231   9.082217  -1.225   0.2513    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S SexMal
## Trtmnt_bsDr -0.501                     
## Trtmnt_bsSm -0.256  0.315              
## SexMale     -0.382  0.142  0.008       
## ReginLxmbrg -0.498  0.071 -0.041  0.008
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
test1 <- data.frame(Reference = "Dark", as.data.frame(( summary(lmer(Adult_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room), data = Data_OP))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test2 <- data.frame(Reference = "Smart", as.data.frame(( summary(lmer(Adult_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room), data = Data_OP_ref_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test3 <- data.frame(Reference = "Full", as.data.frame(( summary(lmer(Adult_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room), data = Data_OP_ref_full))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
Results_Adult_mass_OP <- rbind(test1,test2,test3)

colnames(Results_Adult_mass_OP ) <- c("Reference","Estimate", "Std. Error", "df", "t.value", "Pr(>|z|)")

write.csv2( Results_Adult_mass_OP , file = "output/Results_Adult_mass_OP.csv" )

kable(Results_Adult_mass_OP , caption = " Poids des adultes OP ", padding = 1 )
Poids des adultes OP
Reference Estimate Std. Error df t.value Pr(>|z|)
(Intercept) Dark 0.0904454 0.0031441 4.350699 28.7664437 0.0000039
Treatment_bisFull Dark 0.0055013 0.0026468 112.218248 2.0784621 0.0399468
Treatment_bisSmart Dark 0.0049703 0.0040384 63.579302 1.2307539 0.2229487
SexMale Dark -0.0136801 0.0024399 115.800568 -5.6068558 0.0000001
RegionLuxembourg Dark -0.0039585 0.0032308 9.082217 -1.2252542 0.2513039
(Intercept)1 Smart 0.0954157 0.0045785 15.194148 20.8397696 0.0000000
Treatment_bisDark Smart -0.0049703 0.0040384 63.579302 -1.2307539 0.2229487
Treatment_bisFull1 Smart 0.0005310 0.0039942 96.473719 0.1329458 0.8945132
SexMale1 Smart -0.0136801 0.0024399 115.800568 -5.6068558 0.0000001
RegionLuxembourg1 Smart -0.0039585 0.0032308 9.082217 -1.2252542 0.2513039
(Intercept)2 Full 0.0959467 0.0034818 6.940186 27.5568391 0.0000000
Treatment_bisDark1 Full -0.0055013 0.0026468 112.218248 -2.0784621 0.0399468
Treatment_bisSmart1 Full -0.0005310 0.0039942 96.473719 -0.1329458 0.8945132
SexMale2 Full -0.0136801 0.0024399 115.800568 -5.6068558 0.0000001
RegionLuxembourg2 Full -0.0039585 0.0032308 9.082217 -1.2252542 0.2513039
Info_Adult_mass_OP <- "
Les adultes du traitement Full sont significativement plus lourd que ceux du traitement Dark.
Les mâles sont significativement plus légers que les femelles
"
Info_Adult_mass_OP
## [1] "\nLes adultes du traitement Full sont significativement plus lourd que ceux du traitement Dark.\nLes mâles sont significativement plus légers que les femelles\n"

6.14 Adult_mass AE

6.14.1 Test

LM_Adult_mass_AE <- lmer(Adult_mass ~ Treatment_bis + Sex  + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_AE)
summary(LM_Adult_mass_AE)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Adult_mass ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data_AE
## 
## REML criterion at convergence: -428.8
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.4461 -0.5775  0.0190  0.4564  3.2066 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 1.363e-04 0.011677
##  Site     (Intercept) 3.368e-04 0.018353
##  Room     (Intercept) 4.388e-05 0.006624
##  Residual             1.523e-03 0.039022
## Number of obs: 143, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                               1.918e-01  1.375e-02  1.202e+01
## Treatment_bisFull                         2.063e-02  1.361e-02  1.200e+02
## Treatment_bisSmart                        1.620e-02  1.554e-02  1.128e+02
## Treatment_bisMixt_smart                   4.187e-02  1.575e-02  1.052e+02
## SexMale                                  -1.758e-02  1.214e-02  1.237e+02
## RegionLuxembourg                          9.095e-03  1.694e-02  2.165e+01
## Treatment_bisFull:SexMale                 4.164e-03  1.736e-02  1.235e+02
## Treatment_bisSmart:SexMale               -1.817e-02  2.092e-02  1.254e+02
## Treatment_bisMixt_smart:SexMale          -4.214e-02  2.034e-02  1.253e+02
## Treatment_bisFull:RegionLuxembourg       -3.526e-04  1.717e-02  1.186e+02
## Treatment_bisSmart:RegionLuxembourg      -6.535e-03  1.939e-02  1.146e+02
## Treatment_bisMixt_smart:RegionLuxembourg  2.333e-02  1.978e-02  1.209e+02
##                                          t value Pr(>|t|)    
## (Intercept)                               13.950 8.75e-09 ***
## Treatment_bisFull                          1.516  0.13220    
## Treatment_bisSmart                         1.042  0.29964    
## Treatment_bisMixt_smart                    2.658  0.00908 ** 
## SexMale                                   -1.448  0.15006    
## RegionLuxembourg                           0.537  0.59677    
## Treatment_bisFull:SexMale                  0.240  0.81081    
## Treatment_bisSmart:SexMale                -0.868  0.38678    
## Treatment_bisMixt_smart:SexMale           -2.072  0.04033 *  
## Treatment_bisFull:RegionLuxembourg        -0.021  0.98365    
## Treatment_bisSmart:RegionLuxembourg       -0.337  0.73668    
## Treatment_bisMixt_smart:RegionLuxembourg   1.179  0.24073    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_F:SM T_S:SM T_M_:S
## Trtmnt_bsFl -0.458                                                        
## Trtmnt_bsSm -0.389  0.380                                                 
## Trtmnt_bsM_ -0.420  0.435  0.310                                          
## SexMale     -0.360  0.369  0.317  0.340                                   
## ReginLxmbrg -0.599  0.245  0.226  0.218 -0.035                            
## Trtmnt_F:SM  0.234 -0.586 -0.200 -0.259 -0.698  0.046                     
## Trtmnt_S:SM  0.214 -0.217 -0.418 -0.208 -0.584  0.009  0.403              
## Trtmn_M_:SM  0.206 -0.227 -0.200 -0.551 -0.615  0.031  0.438  0.375       
## Trtmnt_F:RL  0.265 -0.523 -0.222 -0.229  0.004 -0.486  0.009  0.001 -0.005
## Trtmnt_S:RL  0.213 -0.212 -0.596 -0.178  0.019 -0.423 -0.018 -0.102 -0.011
## Trtmn_M_:RL  0.234 -0.218 -0.187 -0.484  0.019 -0.436 -0.025 -0.026 -0.044
##             T_F:RL T_S:RL
## Trtmnt_bsFl              
## Trtmnt_bsSm              
## Trtmnt_bsM_              
## SexMale                  
## ReginLxmbrg              
## Trtmnt_F:SM              
## Trtmnt_S:SM              
## Trtmn_M_:SM              
## Trtmnt_F:RL              
## Trtmnt_S:RL  0.417       
## Trtmn_M_:RL  0.431  0.364

Vérification des hypothèses

qqnorm(resid(LM_Adult_mass_AE))
qqline(resid(LM_Adult_mass_AE))

On va insérer un logarythme dans les données quand même

LM_Adult_mass_AE <- lmer(log(Adult_mass) ~ Treatment_bis + Sex  + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_AE)

Vérification des hypothèses

qqnorm(resid(LM_Adult_mass_AE))
qqline(resid(LM_Adult_mass_AE))

Homogénité des variances

plot(LM_Adult_mass_AE)

Distance de cook

plot(cooks.distance(LM_Adult_mass_AE))

6.14.2 Simplification du modèle

drop1(LM_Adult_mass_AE)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Adult_mass) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##                        Sum Sq  Mean Sq NumDF  DenDF F value Pr(>F)
## Treatment_bis:Sex    0.185699 0.061900     3 121.91  1.5975 0.1935
## Treatment_bis:Region 0.093063 0.031021     3 117.82  0.8006 0.4959
LM_Adult_mass1_AE <- update(LM_Adult_mass_AE, . ~ . - Treatment_bis:Region)
drop1(LM_Adult_mass1_AE)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Adult_mass) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex
##                     Sum Sq  Mean Sq NumDF   DenDF F value Pr(>F)
## Region            0.039206 0.039206     1  10.226  1.0097 0.3382
## Treatment_bis:Sex 0.179712 0.059904     3 125.546  1.5427 0.2068

Nous n’avons plus d’interaction à retirer, nous arrêtons la simplification du modèle.

Est ce que la simplification a été utile ?

AIC(LM_Adult_mass1_AE)
## [1] 13.5903
AIC(LM_Adult_mass_AE)
## [1] 26.29923

Oui

LM_Adult_mass_AE <- LM_Adult_mass1_AE

6.14.3 Treatment VS Treatment_bis

AIC(lmer(log(Adult_mass) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room), data = Data_AE))
## boundary (singular) fit: see help('isSingular')
## [1] 3.161663
AIC(lmer(log(Adult_mass) ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room), data = Data_AE))
## [1] 1.791244
summary(lmer(log(Adult_mass) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room), data = Data_AE))$coeff
## boundary (singular) fit: see help('isSingular')
##                            Estimate Std. Error        df    t value
## (Intercept)             -1.68367188 0.05380158  17.99265 -31.294100
## Treatment_bisFull        0.13592965 0.04308590 126.39365   3.154853
## Treatment_bisSmart       0.03944971 0.04902320 122.04083   0.804715
## Treatment_bisMixt_smart  0.19144309 0.04947199 128.49503   3.869727
## SexMale                 -0.13503554 0.03528278 130.43816  -3.827237
## RegionLuxembourg         0.06481243 0.06265904  10.56742   1.034367
##                             Pr(>|t|)
## (Intercept)             3.843221e-17
## Treatment_bisFull       2.007076e-03
## Treatment_bisSmart      4.225490e-01
## Treatment_bisMixt_smart 1.724180e-04
## SexMale                 2.001719e-04
## RegionLuxembourg        3.240559e-01
summary(lmer(log(Adult_mass) ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room), data = Data_AE))$coeff
##                     Estimate Std. Error         df     t value     Pr(>|t|)
## (Intercept)      -1.67804327 0.06578375   5.726785 -25.5084752 4.064884e-07
## TreatmentFull     0.12971461 0.04329543 125.599733   2.9960348 3.296326e-03
## TreatmentSmart    0.10831693 0.04087224 124.131258   2.6501345 9.093434e-03
## SexMale          -0.12746733 0.03532718 129.602262  -3.6081948 4.389807e-04
## RegionLuxembourg  0.06155811 0.06392561  10.296531   0.9629648 3.576352e-01

On va continuer avec treatment_bis car même si l’AIC préfère le modèle Treatment , Mixt smart a un effet significatif avec Treatment_bis

6.14.4 Résultats

Analyse des P-val

summary(lmer(log(Adult_mass) ~ Treatment_bis + Sex + Region + Treatment_bis:Sex + (1 | Mother) + (1 |  Site) + (1 | Room), data = Data_AE))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Adult_mass) ~ Treatment_bis + Sex + Region + Treatment_bis:Sex +  
##     (1 | Mother) + (1 | Site) + (1 | Room)
##    Data: Data_AE
## 
## REML criterion at convergence: -12.4
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -3.1636 -0.5865  0.0686  0.5200  2.6310 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0032149 0.05670 
##  Site     (Intercept) 0.0072751 0.08529 
##  Room     (Intercept) 0.0002591 0.01610 
##  Residual             0.0388314 0.19706 
## Number of obs: 143, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                  Estimate Std. Error        df t value Pr(>|t|)
## (Intercept)                      -1.70140    0.06049  13.18179 -28.128 3.71e-13
## Treatment_bisFull                 0.12438    0.05823 120.58211   2.136 0.034705
## Treatment_bisSmart                0.07786    0.06214  92.49497   1.253 0.213415
## Treatment_bisMixt_smart           0.26692    0.06781  50.02743   3.936 0.000256
## SexMale                          -0.08843    0.06112 127.63335  -1.447 0.150407
## RegionLuxembourg                  0.06641    0.06609  10.22644   1.005 0.338170
## Treatment_bisFull:SexMale         0.01268    0.08696 122.87809   0.146 0.884270
## Treatment_bisSmart:SexMale       -0.09682    0.10472 129.28245  -0.925 0.356892
## Treatment_bisMixt_smart:SexMale  -0.18314    0.10232 129.07500  -1.790 0.075813
##                                    
## (Intercept)                     ***
## Treatment_bisFull               *  
## Treatment_bisSmart                 
## Treatment_bisMixt_smart         ***
## SexMale                            
## RegionLuxembourg                   
## Treatment_bisFull:SexMale          
## Treatment_bisSmart:SexMale         
## Treatment_bisMixt_smart:SexMale .  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_F:SM T_S:SM
## Trtmnt_bsFl -0.432                                                 
## Trtmnt_bsSm -0.396  0.414                                          
## Trtmnt_bsM_ -0.399  0.418  0.357                                   
## SexMale     -0.418  0.435  0.419  0.403                            
## ReginLxmbrg -0.560 -0.005 -0.024  0.007 -0.030                     
## Trtmnt_F:SM  0.271 -0.679 -0.284 -0.296 -0.699  0.045              
## Trtmnt_S:SM  0.262 -0.257 -0.609 -0.259 -0.586 -0.023  0.406       
## Trtmn_M_:SM  0.246 -0.270 -0.259 -0.668 -0.615  0.021  0.438  0.376
summary(lmer(log(Adult_mass) ~ Treatment_bis + Sex + Region + Treatment_bis:Sex + (1 | Mother) + (1 |  Site) + (1 | Room), data = Data_AE_ref_smart))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Adult_mass) ~ Treatment_bis + Sex + Region + Treatment_bis:Sex +  
##     (1 | Mother) + (1 | Site) + (1 | Room)
##    Data: Data_AE_ref_smart
## 
## REML criterion at convergence: -12.4
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -3.1636 -0.5865  0.0686  0.5200  2.6310 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0032149 0.05670 
##  Site     (Intercept) 0.0072751 0.08529 
##  Room     (Intercept) 0.0002591 0.01610 
##  Residual             0.0388314 0.19706 
## Number of obs: 143, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                  Estimate Std. Error        df t value Pr(>|t|)
## (Intercept)                      -1.62355    0.06741  12.87270 -24.084 4.34e-12
## Treatment_bisDark                -0.07786    0.06214  92.49497  -1.253   0.2134
## Treatment_bisFull                 0.04652    0.06526  39.67268   0.713   0.4801
## Treatment_bisMixt_smart           0.18906    0.07381  12.50088   2.561   0.0243
## SexMale                          -0.18525    0.08483 130.18960  -2.184   0.0308
## RegionLuxembourg                  0.06641    0.06609  10.22644   1.005   0.3382
## Treatment_bisDark:SexMale         0.09682    0.10472 129.28245   0.925   0.3569
## Treatment_bisFull:SexMale         0.10951    0.10556 128.54859   1.037   0.3015
## Treatment_bisMixt_smart:SexMale  -0.08632    0.11566 127.53174  -0.746   0.4569
##                                    
## (Intercept)                     ***
## Treatment_bisDark                  
## Treatment_bisFull                  
## Treatment_bisMixt_smart         *  
## SexMale                         *  
## RegionLuxembourg                   
## Treatment_bisDark:SexMale          
## Treatment_bisFull:SexMale          
## Treatment_bisMixt_smart:SexMale    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trt_M_ SexMal RgnLxm T_D:SM T_F:SM
## Trtmnt_bsDr -0.567                                                 
## Trtmnt_bsFl -0.545  0.583                                          
## Trtmnt_bsM_ -0.503  0.514  0.521                                   
## SexMale     -0.394  0.450  0.425  0.352                            
## ReginLxmbrg -0.524  0.024  0.018  0.026 -0.051                     
## Trtmnt_D:SM  0.326 -0.609 -0.351 -0.275 -0.812  0.023              
## Trtmnt_F:SM  0.308 -0.370 -0.625 -0.300 -0.808  0.060  0.658       
## Trtmn_M_:SM  0.279 -0.322 -0.313 -0.599 -0.717  0.040  0.573  0.585
summary(lmer(log(Adult_mass) ~ Treatment_bis + Sex + Region + Treatment_bis:Sex + (1 | Mother) + (1 |  Site) + (1 | Room), data = Data_AE_ref_full))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Adult_mass) ~ Treatment_bis + Sex + Region + Treatment_bis:Sex +  
##     (1 | Mother) + (1 | Site) + (1 | Room)
##    Data: Data_AE_ref_full
## 
## REML criterion at convergence: -12.4
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -3.1636 -0.5865  0.0686  0.5200  2.6310 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0032149 0.05670 
##  Site     (Intercept) 0.0072751 0.08529 
##  Room     (Intercept) 0.0002591 0.01610 
##  Residual             0.0388314 0.19706 
## Number of obs: 143, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                  Estimate Std. Error        df t value Pr(>|t|)
## (Intercept)                      -1.57703    0.06332  15.14825 -24.906 1.04e-13
## Treatment_bisDark                -0.12438    0.05823 120.58211  -2.136   0.0347
## Treatment_bisSmart               -0.04652    0.06526  39.67268  -0.713   0.4801
## Treatment_bisMixt_smart           0.14254    0.06847 107.59342   2.082   0.0397
## SexMale                          -0.07574    0.06221 117.90424  -1.217   0.2259
## RegionLuxembourg                  0.06641    0.06609  10.22644   1.005   0.3382
## Treatment_bisDark:SexMale        -0.01268    0.08696 122.87809  -0.146   0.8843
## Treatment_bisSmart:SexMale       -0.10951    0.10556 128.54859  -1.037   0.3015
## Treatment_bisMixt_smart:SexMale  -0.19582    0.10119 124.01958  -1.935   0.0552
##                                    
## (Intercept)                     ***
## Treatment_bisDark               *  
## Treatment_bisSmart                 
## Treatment_bisMixt_smart         *  
## SexMale                            
## RegionLuxembourg                   
## Treatment_bisDark:SexMale          
## Treatment_bisSmart:SexMale         
## Treatment_bisMixt_smart:SexMale .  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S Trt_M_ SexMal RgnLxm T_D:SM T_S:SM
## Trtmnt_bsDr -0.507                                                 
## Trtmnt_bsSm -0.451  0.498                                          
## Trtmnt_bsM_ -0.428  0.436  0.391                                   
## SexMale     -0.510  0.522  0.480  0.426                            
## ReginLxmbrg -0.539  0.005 -0.018  0.011  0.033                     
## Trtmnt_D:SM  0.366 -0.679 -0.336 -0.285 -0.711 -0.045              
## Trtmnt_S:SM  0.316 -0.305 -0.625 -0.272 -0.595 -0.060  0.422       
## Trtmn_M_:SM  0.300 -0.311 -0.294 -0.682 -0.603 -0.018  0.417  0.375
summary(lmer(log(Adult_mass) ~ Treatment_bis + Sex + Region + Treatment_bis:Sex + (1 | Mother) + (1 |  Site) + (1 | Room), data = Data_AE_ref_mixt_smart))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Adult_mass) ~ Treatment_bis + Sex + Region + Treatment_bis:Sex +  
##     (1 | Mother) + (1 | Site) + (1 | Room)
##    Data: Data_AE_ref_mixt_smart
## 
## REML criterion at convergence: -12.4
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -3.1636 -0.5865  0.0686  0.5200  2.6310 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0032149 0.05670 
##  Site     (Intercept) 0.0072751 0.08529 
##  Room     (Intercept) 0.0002591 0.01610 
##  Residual             0.0388314 0.19706 
## Number of obs: 143, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                             Estimate Std. Error        df t value Pr(>|t|)    
## (Intercept)                 -1.43448    0.07061  14.51590 -20.317 4.56e-12 ***
## Treatment_bisDark           -0.26692    0.06781  50.02743  -3.936 0.000256 ***
## Treatment_bisFull           -0.14254    0.06847 107.59342  -2.082 0.039735 *  
## Treatment_bisSmart          -0.18906    0.07381  12.50088  -2.561 0.024281 *  
## SexMale                     -0.27157    0.08070 127.31270  -3.365 0.001011 ** 
## RegionLuxembourg             0.06641    0.06609  10.22644   1.005 0.338170    
## Treatment_bisDark:SexMale    0.18314    0.10232 129.07500   1.790 0.075813 .  
## Treatment_bisFull:SexMale    0.19582    0.10119 124.01958   1.935 0.055244 .  
## Treatment_bisSmart:SexMale   0.08632    0.11566 127.53174   0.746 0.456864    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trtm_S SexMal RgnLxm T_D:SM T_F:SM
## Trtmnt_bsDr -0.619                                                 
## Trtmnt_bsFl -0.586  0.635                                          
## Trtmnt_bsSm -0.565  0.618  0.582                                   
## SexMale     -0.525  0.543  0.526  0.489                            
## ReginLxmbrg -0.473 -0.007 -0.011 -0.026  0.003                     
## Trtmnt_D:SM  0.431 -0.668 -0.432 -0.396 -0.802 -0.021              
## Trtmnt_F:SM  0.392 -0.422 -0.682 -0.372 -0.789  0.018  0.635       
## Trtmnt_S:SM  0.360 -0.357 -0.348 -0.599 -0.680 -0.040  0.544  0.533
test1 <- data.frame(Reference = "Dark", as.data.frame(( summary(lmer(log(Adult_mass) ~ Treatment_bis + Sex + Region + Treatment_bis:Sex + (1 | Mother) + (1 |  Site) + (1 | Room), data = Data_AE))$coeff)[,]))

test2 <- data.frame(Reference = "Smart", as.data.frame(( summary(lmer(log(Adult_mass) ~ Treatment_bis + Sex + Region + Treatment_bis:Sex + (1 | Mother) + (1 |  Site) + (1 | Room), data = Data_AE_ref_smart))$coeff)[,]))

test3 <- data.frame(Reference = "Full", as.data.frame(( summary(lmer(log(Adult_mass) ~ Treatment_bis + Sex + Region + Treatment_bis:Sex + (1 | Mother) + (1 |  Site) + (1 | Room), data = Data_AE_ref_full))$coeff)[,]))

test4 <- data.frame(Reference = "Mixt_smart", as.data.frame(( summary(lmer(log(Adult_mass) ~ Treatment_bis + Sex + Region + Treatment_bis:Sex + (1 | Mother) + (1 |  Site) + (1 | Room), data = Data_AE_ref_mixt_smart))$coeff)[,]))

Results_Adult_mass_AE <- rbind(test1,test2,test3,test4)

colnames(Results_Adult_mass_AE ) <- c("Reference","Estimate", "Std. Error", "df", "t.value", "Pr(>|z|)")

write.csv2( Results_Adult_mass_AE , file = "output/Results_Adult_mass_AE.csv" )

kable(Results_Adult_mass_AE , caption = " Poids des adultes AE ", padding = 1 )
Poids des adultes AE
Reference Estimate Std. Error df t.value Pr(>|z|)
(Intercept) Dark -1.7014022 0.0604881 13.18179 -28.1278797 0.0000000
Treatment_bisFull Dark 0.1243766 0.0582301 120.58211 2.1359503 0.0347052
Treatment_bisSmart Dark 0.0778551 0.0621420 92.49497 1.2528592 0.2134151
Treatment_bisMixt_smart Dark 0.2669182 0.0678116 50.02743 3.9361726 0.0002562
SexMale Dark -0.0884291 0.0611208 127.63335 -1.4467924 0.1504066
RegionLuxembourg Dark 0.0664067 0.0660886 10.22644 1.0048136 0.3381697
Treatment_bisFull:SexMale Dark 0.0126844 0.0869623 122.87809 0.1458614 0.8842698
Treatment_bisSmart:SexMale Dark -0.0968221 0.1047168 129.28245 -0.9246090 0.3568919
Treatment_bisMixt_smart:SexMale Dark -0.1831390 0.1023176 129.07500 -1.7899066 0.0758135
(Intercept)1 Smart -1.6235471 0.0674129 12.87270 -24.0836352 0.0000000
Treatment_bisDark Smart -0.0778551 0.0621420 92.49497 -1.2528592 0.2134151
Treatment_bisFull1 Smart 0.0465214 0.0652567 39.67268 0.7128989 0.4800807
Treatment_bisMixt_smart1 Smart 0.1890631 0.0738146 12.50088 2.5613230 0.0242814
SexMale1 Smart -0.1852512 0.0848312 130.18960 -2.1837634 0.0307716
RegionLuxembourg1 Smart 0.0664067 0.0660886 10.22644 1.0048136 0.3381697
Treatment_bisDark:SexMale Smart 0.0968221 0.1047168 129.28245 0.9246090 0.3568919
Treatment_bisFull:SexMale1 Smart 0.1095066 0.1055570 128.54859 1.0374165 0.3014893
Treatment_bisMixt_smart:SexMale1 Smart -0.0863169 0.1156610 127.53174 -0.7462922 0.4568644
(Intercept)2 Full -1.5770256 0.0633180 15.14825 -24.9064178 0.0000000
Treatment_bisDark1 Full -0.1243766 0.0582301 120.58211 -2.1359503 0.0347052
Treatment_bisSmart1 Full -0.0465214 0.0652567 39.67268 -0.7128989 0.4800807
Treatment_bisMixt_smart2 Full 0.1425416 0.0684711 107.59342 2.0817770 0.0397352
SexMale2 Full -0.0757447 0.0622145 117.90424 -1.2174758 0.2258543
RegionLuxembourg2 Full 0.0664067 0.0660886 10.22644 1.0048136 0.3381697
Treatment_bisDark:SexMale1 Full -0.0126844 0.0869623 122.87809 -0.1458614 0.8842698
Treatment_bisSmart:SexMale1 Full -0.1095066 0.1055570 128.54859 -1.0374165 0.3014893
Treatment_bisMixt_smart:SexMale2 Full -0.1958234 0.1011910 124.01958 -1.9351871 0.0552438
(Intercept)3 Mixt_smart -1.4344840 0.0706055 14.51590 -20.3169001 0.0000000
Treatment_bisDark2 Mixt_smart -0.2669182 0.0678116 50.02743 -3.9361726 0.0002562
Treatment_bisFull2 Mixt_smart -0.1425416 0.0684711 107.59342 -2.0817770 0.0397352
Treatment_bisSmart2 Mixt_smart -0.1890631 0.0738146 12.50088 -2.5613230 0.0242814
SexMale3 Mixt_smart -0.2715681 0.0806965 127.31270 -3.3653004 0.0010110
RegionLuxembourg3 Mixt_smart 0.0664067 0.0660886 10.22644 1.0048136 0.3381697
Treatment_bisDark:SexMale2 Mixt_smart 0.1831390 0.1023176 129.07500 1.7899066 0.0758135
Treatment_bisFull:SexMale2 Mixt_smart 0.1958234 0.1011910 124.01958 1.9351871 0.0552438
Treatment_bisSmart:SexMale2 Mixt_smart 0.0863169 0.1156610 127.53174 0.7462922 0.4568644
Info_Adult_mass_AE <- "
Les individus du traitement Full sont significativement plus lourds que ceux du traitement Dark.
Les individus du traitement Mixt-smart sont significativement plus lourd que ceux de n'importe quel autre traitement.
Les mâles significativement plus léger que les femelles dans le traitement Smart.
"
Info_Adult_mass_AE
## [1] "\nLes individus du traitement Full sont significativement plus lourds que ceux du traitement Dark.\nLes individus du traitement Mixt-smart sont significativement plus lourd que ceux de n'importe quel autre traitement.\nLes mâles significativement plus léger que les femelles dans le traitement Smart.\n"

6.15 M0 OP

6.15.1 Test

LM_M0_OP <- lmer(M0 ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_OP)
## boundary (singular) fit: see help('isSingular')
summary(LM_M0_OP)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: M0 ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) +  
##     (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data_OP
## 
## REML criterion at convergence: -726.9
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.7192 -0.6855 -0.1027  0.6434  3.5627 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 8.482e-05 0.00921 
##  Site     (Intercept) 0.000e+00 0.00000 
##  Room     (Intercept) 0.000e+00 0.00000 
##  Residual             1.567e-04 0.01252 
## Number of obs: 139, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                                       Estimate Std. Error         df t value
## (Intercept)                          3.569e-02  4.503e-03  1.090e+01   7.927
## Treatment_bisFull                    1.920e-03  4.103e-03  1.198e+02   0.468
## Treatment_bisSmart                  -9.400e-03  6.010e-03  1.203e+02  -1.564
## SexMale                             -1.093e-03  3.048e-03  1.188e+02  -0.359
## RegionLuxembourg                    -2.325e-03  6.224e-03  9.969e+00  -0.373
## Treatment_bisFull:SexMale            9.446e-04  4.796e-03  1.201e+02   0.197
## Treatment_bisSmart:SexMale           1.006e-02  6.945e-03  1.228e+02   1.448
## Treatment_bisFull:RegionLuxembourg  -4.604e-03  4.705e-03  1.191e+02  -0.978
## Treatment_bisSmart:RegionLuxembourg  1.544e-03  6.959e-03  1.209e+02   0.222
##                                     Pr(>|t|)    
## (Intercept)                         7.55e-06 ***
## Treatment_bisFull                      0.641    
## Treatment_bisSmart                     0.120    
## SexMale                                0.721    
## RegionLuxembourg                       0.717    
## Treatment_bisFull:SexMale              0.844    
## Treatment_bisSmart:SexMale             0.150    
## Treatment_bisFull:RegionLuxembourg     0.330    
## Treatment_bisSmart:RegionLuxembourg    0.825    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S SexMal RgnLxm T_F:SM T_S:SM T_F:RL
## Trtmnt_bsFl -0.310                                                 
## Trtmnt_bsSm -0.190  0.224                                          
## SexMale     -0.243  0.270  0.198                                   
## ReginLxmbrg -0.672  0.156  0.085 -0.034                            
## Trtmnt_F:SM  0.165 -0.568 -0.128 -0.635  0.032                     
## Trtmnt_S:SM  0.101 -0.123 -0.486 -0.457  0.046  0.297              
## Trtmnt_F:RL  0.199 -0.591 -0.140  0.038 -0.317  0.010 -0.021       
## Trtmnt_S:RL  0.121 -0.128 -0.598  0.030 -0.221 -0.038 -0.124  0.278
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Vérification des hypothèses

qqnorm(resid(LM_M0_OP))
qqline(resid(LM_M0_OP))

Je pense que ca va

Homogénité des variances

plot(LM_M0_OP)

Distance de cook

plot(cooks.distance(LM_M0_OP))

6.15.2 Simplification du modèle

drop1(LM_M0_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## M0 ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##                          Sum Sq    Mean Sq NumDF  DenDF F value Pr(>F)
## Treatment_bis:Sex    0.00033807 1.6904e-04     2 121.39  1.0786 0.3433
## Treatment_bis:Region 0.00019141 9.5704e-05     2 120.11  0.6107 0.5447
LM_M0_1_OP <- update(LM_M0_OP, . ~ . - Treatment_bis:Region)
## boundary (singular) fit: see help('isSingular')
drop1(LM_M0_1_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## M0 ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex
##                       Sum Sq    Mean Sq NumDF   DenDF F value Pr(>F)
## Region            0.00006655 6.6549e-05     1   7.754  0.4275 0.5321
## Treatment_bis:Sex 0.00035972 1.7986e-04     2 123.130  1.1554 0.3183

6.15.3 Résultats

summary(LM_M0_1_OP)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: M0 ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) +  
##     (1 | Room) + Treatment_bis:Sex
##    Data: Data_OP
## 
## REML criterion at convergence: -742.7
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.8514 -0.6524 -0.1601  0.5753  3.6332 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 8.538e-05 0.00924 
##  Site     (Intercept) 0.000e+00 0.00000 
##  Room     (Intercept) 0.000e+00 0.00000 
##  Residual             1.557e-04 0.01248 
## Number of obs: 139, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                              Estimate Std. Error         df t value Pr(>|t|)
## (Intercept)                 3.642e-02  4.409e-03  9.956e+00   8.260 9.14e-06
## Treatment_bisFull          -5.351e-04  3.295e-03  1.218e+02  -0.162   0.8713
## Treatment_bisSmart         -8.413e-03  4.801e-03  1.255e+02  -1.753   0.0821
## SexMale                    -1.009e-03  3.035e-03  1.206e+02  -0.332   0.7401
## RegionLuxembourg           -3.826e-03  5.852e-03  7.754e+00  -0.654   0.5321
## Treatment_bisFull:SexMale   1.097e-03  4.775e-03  1.220e+02   0.230   0.8186
## Treatment_bisSmart:SexMale  1.033e-02  6.868e-03  1.244e+02   1.504   0.1352
##                               
## (Intercept)                ***
## Treatment_bisFull             
## Treatment_bisSmart         .  
## SexMale                       
## RegionLuxembourg              
## Treatment_bisFull:SexMale     
## Treatment_bisSmart:SexMale    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S SexMal RgnLxm T_F:SM
## Trtmnt_bsFl -0.247                                   
## Trtmnt_bsSm -0.156  0.253                            
## SexMale     -0.256  0.362  0.268                     
## ReginLxmbrg -0.655 -0.035 -0.054 -0.021              
## Trtmnt_F:SM  0.169 -0.696 -0.190 -0.635  0.031       
## Trtmnt_S:SM  0.117 -0.164 -0.705 -0.457  0.024  0.295
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(M0 ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) +  (1 | Room) + Treatment_bis:Sex, data = Data_OP_ref_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: M0 ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) +  
##     (1 | Room) + Treatment_bis:Sex
##    Data: Data_OP_ref_smart
## 
## REML criterion at convergence: -742.7
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.8514 -0.6524 -0.1601  0.5753  3.6332 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 8.538e-05 9.240e-03
##  Site     (Intercept) 0.000e+00 0.000e+00
##  Room     (Intercept) 3.853e-21 6.207e-11
##  Residual             1.557e-04 1.248e-02
## Number of obs: 139, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                             Estimate Std. Error         df t value Pr(>|t|)    
## (Intercept)                 0.028005   0.005990  30.692049   4.675 5.55e-05 ***
## Treatment_bisDark           0.008413   0.004801 125.473009   1.753   0.0821 .  
## Treatment_bisFull           0.007878   0.005089 124.449688   1.548   0.1242    
## SexMale                     0.009318   0.006109 124.377624   1.525   0.1297    
## RegionLuxembourg           -0.003826   0.005852   7.753922  -0.654   0.5321    
## Treatment_bisDark:SexMale  -0.010327   0.006868 124.352313  -1.504   0.1352    
## Treatment_bisFull:SexMale  -0.009229   0.007115 123.630243  -1.297   0.1970    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F SexMal RgnLxm T_D:SM
## Trtmnt_bsDr -0.687                                   
## Trtmnt_bsFl -0.634  0.779                            
## SexMale     -0.526  0.660  0.619                     
## ReginLxmbrg -0.525  0.054  0.028  0.017              
## Trtmnt_D:SM  0.479 -0.705 -0.559 -0.897 -0.024       
## Trtmnt_F:SM  0.444 -0.554 -0.722 -0.855 -0.002  0.767
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(M0 ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) +  (1 | Room) + Treatment_bis:Sex, data = Data_OP_ref_full))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: M0 ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) +  
##     (1 | Room) + Treatment_bis:Sex
##    Data: Data_OP_ref_full
## 
## REML criterion at convergence: -742.7
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.8514 -0.6524 -0.1601  0.5753  3.6332 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 8.538e-05 9.240e-03
##  Site     (Intercept) 0.000e+00 0.000e+00
##  Room     (Intercept) 2.676e-21 5.173e-11
##  Residual             1.557e-04 1.248e-02
## Number of obs: 139, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                              Estimate Std. Error         df t value Pr(>|t|)
## (Intercept)                 3.588e-02  4.809e-03  1.419e+01   7.462 2.82e-06
## Treatment_bisDark           5.351e-04  3.295e-03  1.218e+02   0.162    0.871
## Treatment_bisSmart         -7.878e-03  5.089e-03  1.244e+02  -1.548    0.124
## SexMale                     8.828e-05  3.687e-03  1.231e+02   0.024    0.981
## RegionLuxembourg           -3.826e-03  5.852e-03  7.754e+00  -0.654    0.532
## Treatment_bisDark:SexMale  -1.097e-03  4.775e-03  1.220e+02  -0.230    0.819
## Treatment_bisSmart:SexMale  9.229e-03  7.115e-03  1.236e+02   1.297    0.197
##                               
## (Intercept)                ***
## Treatment_bisDark             
## Treatment_bisSmart            
## SexMale                       
## RegionLuxembourg              
## Treatment_bisDark:SexMale     
## Treatment_bisSmart:SexMale    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S SexMal RgnLxm T_D:SM
## Trtmnt_bsDr -0.459                                   
## Trtmnt_bsSm -0.268  0.409                            
## SexMale     -0.407  0.604  0.368                     
## ReginLxmbrg -0.624  0.035 -0.028  0.024              
## Trtmnt_D:SM  0.322 -0.696 -0.272 -0.772 -0.031       
## Trtmnt_S:SM  0.211 -0.309 -0.722 -0.513  0.002  0.386
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
test1 <- data.frame(Reference = "Dark", as.data.frame(( summary(LM_M0_1_OP)$coeff)[,]))

test2 <- data.frame(Reference = "Smart", as.data.frame(( summary(lmer(M0 ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) +  (1 | Room) + Treatment_bis:Sex, data = Data_OP_ref_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test3 <- data.frame(Reference = "Full", as.data.frame(( summary(lmer(M0 ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) +  (1 | Room) + Treatment_bis:Sex, data = Data_OP_ref_full))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
Results_M0_OP <- rbind(test1,test2,test3)

colnames(Results_M0_OP ) <- c("Reference","Estimate", "Std. Error", "df", "t.value", "Pr(>|z|)")

write.csv2( Results_M0_OP , file = "output/Results_M0_OP.csv" )

kable(Results_M0_OP , caption = " Poids initial OP ", padding = 1 )
Poids initial OP
Reference Estimate Std. Error df t.value Pr(>|z|)
(Intercept) Dark 0.0364184 0.0044089 9.955682 8.2601491 0.0000091
Treatment_bisFull Dark -0.0005351 0.0032952 121.757241 -0.1623803 0.8712756
Treatment_bisSmart Dark -0.0084130 0.0048005 125.473009 -1.7525267 0.0821260
SexMale Dark -0.0010091 0.0030352 120.636410 -0.3324473 0.7401285
RegionLuxembourg Dark -0.0038264 0.0058521 7.753922 -0.6538441 0.5321193
Treatment_bisFull:SexMale Dark 0.0010973 0.0047754 121.972295 0.2297892 0.8186405
Treatment_bisSmart:SexMale Dark 0.0103267 0.0068679 124.352313 1.5036232 0.1352139
(Intercept)1 Smart 0.0280054 0.0059903 30.692049 4.6751021 0.0000555
Treatment_bisDark Smart 0.0084130 0.0048005 125.473009 1.7525267 0.0821260
Treatment_bisFull1 Smart 0.0078780 0.0050890 124.449688 1.5480472 0.1241502
SexMale1 Smart 0.0093177 0.0061091 124.377624 1.5252227 0.1297424
RegionLuxembourg1 Smart -0.0038264 0.0058521 7.753922 -0.6538441 0.5321193
Treatment_bisDark:SexMale Smart -0.0103267 0.0068679 124.352313 -1.5036232 0.1352139
Treatment_bisFull:SexMale1 Smart -0.0092294 0.0071154 123.630244 -1.2970967 0.1970133
(Intercept)2 Full 0.0358833 0.0048090 14.187000 7.4616463 0.0000028
Treatment_bisDark1 Full 0.0005351 0.0032952 121.757241 0.1623803 0.8712756
Treatment_bisSmart1 Full -0.0078780 0.0050890 124.449688 -1.5480472 0.1241502
SexMale2 Full 0.0000883 0.0036875 123.086873 0.0239394 0.9809397
RegionLuxembourg2 Full -0.0038264 0.0058521 7.753922 -0.6538441 0.5321193
Treatment_bisDark:SexMale1 Full -0.0010973 0.0047754 121.972295 -0.2297892 0.8186405
Treatment_bisSmart:SexMale1 Full 0.0092294 0.0071154 123.630244 1.2970967 0.1970133

Aucune différence significative de poids initial en fonction des traitements ou région ou sexe

6.16 M0 AE

6.16.1 Test

LM_M0_AE <- lmer(M0 ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_AE)
summary(LM_M0_AE)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: M0 ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) +  
##     (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data_AE
## 
## REML criterion at convergence: -1077
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.0225 -0.6040 -0.1758  0.6000  2.7818 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 4.833e-06 0.0021985
##  Site     (Intercept) 7.789e-06 0.0027909
##  Room     (Intercept) 9.016e-07 0.0009495
##  Residual             3.571e-05 0.0059755
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                               1.398e-02  2.013e-03  1.319e+01
## Treatment_bisFull                        -1.788e-03  1.899e-03  1.422e+02
## Treatment_bisSmart                       -5.464e-04  2.216e-03  1.355e+02
## Treatment_bisMixt_smart                  -4.359e-04  2.309e-03  1.169e+02
## SexMale                                   1.663e-03  1.752e-03  1.451e+02
## RegionLuxembourg                         -1.691e-04  2.551e-03  2.511e+01
## Treatment_bisFull:SexMale                 1.930e-04  2.462e-03  1.402e+02
## Treatment_bisSmart:SexMale               -3.854e-03  2.961e-03  1.472e+02
## Treatment_bisMixt_smart:SexMale           9.994e-04  2.935e-03  1.444e+02
## Treatment_bisFull:RegionLuxembourg        5.616e-04  2.422e-03  1.416e+02
## Treatment_bisSmart:RegionLuxembourg       6.085e-04  2.758e-03  1.374e+02
## Treatment_bisMixt_smart:RegionLuxembourg -2.249e-03  2.875e-03  1.417e+02
##                                          t value Pr(>|t|)    
## (Intercept)                                6.946 9.36e-06 ***
## Treatment_bisFull                         -0.942    0.348    
## Treatment_bisSmart                        -0.247    0.806    
## Treatment_bisMixt_smart                   -0.189    0.851    
## SexMale                                    0.949    0.344    
## RegionLuxembourg                          -0.066    0.948    
## Treatment_bisFull:SexMale                  0.078    0.938    
## Treatment_bisSmart:SexMale                -1.302    0.195    
## Treatment_bisMixt_smart:SexMale            0.340    0.734    
## Treatment_bisFull:RegionLuxembourg         0.232    0.817    
## Treatment_bisSmart:RegionLuxembourg        0.221    0.826    
## Treatment_bisMixt_smart:RegionLuxembourg  -0.782    0.435    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_F:SM T_S:SM T_M_:S
## Trtmnt_bsFl -0.446                                                        
## Trtmnt_bsSm -0.370  0.392                                                 
## Trtmnt_bsM_ -0.373  0.423  0.302                                          
## SexMale     -0.338  0.373  0.302  0.327                                   
## ReginLxmbrg -0.593  0.231  0.205  0.178 -0.051                            
## Trtmnt_F:SM  0.240 -0.568 -0.198 -0.260 -0.717  0.040                     
## Trtmnt_S:SM  0.210 -0.225 -0.472 -0.203 -0.595  0.023  0.426              
## Trtmn_M_:SM  0.191 -0.220 -0.186 -0.541 -0.606  0.046  0.436  0.376       
## Trtmnt_F:RL  0.242 -0.528 -0.220 -0.206  0.027 -0.481 -0.004 -0.020 -0.032
## Trtmnt_S:RL  0.201 -0.219 -0.579 -0.171  0.036 -0.414 -0.030 -0.048 -0.031
## Trtmn_M_:RL  0.204 -0.213 -0.178 -0.496  0.032 -0.407 -0.028 -0.043 -0.055
##             T_F:RL T_S:RL
## Trtmnt_bsFl              
## Trtmnt_bsSm              
## Trtmnt_bsM_              
## SexMale                  
## ReginLxmbrg              
## Trtmnt_F:SM              
## Trtmnt_S:SM              
## Trtmn_M_:SM              
## Trtmnt_F:RL              
## Trtmnt_S:RL  0.446       
## Trtmn_M_:RL  0.446  0.376

Vérification des hypothèses

qqnorm(resid(LM_M0_AE))
qqline(resid(LM_M0_AE))

Je pense que ca va

Homogénité des variances

plot(LM_M0_AE)

Distance de cook

plot(cooks.distance(LM_M0_AE))

6.16.2 Simplification du modèle

drop1(LM_M0_AE)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## M0 ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##                          Sum Sq    Mean Sq NumDF  DenDF F value Pr(>F)
## Treatment_bis:Sex    9.5697e-05 3.1899e-05     3 144.28  0.8934 0.4463
## Treatment_bis:Region 4.1519e-05 1.3840e-05     3 139.00  0.3876 0.7621
LM_M0_1_AE <- update(LM_M0_AE, . ~ . - Treatment_bis:Region)
drop1(LM_M0_1_AE)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## M0 ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex
##                       Sum Sq    Mean Sq NumDF   DenDF F value Pr(>F)
## Region            5.1800e-07 5.1800e-07     1  12.597  0.0147 0.9053
## Treatment_bis:Sex 9.6857e-05 3.2286e-05     3 146.957  0.9189 0.4334

6.16.3 Résultats

summary(LM_M0_1_AE)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: M0 ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) +  
##     (1 | Room) + Treatment_bis:Sex
##    Data: Data_AE
## 
## REML criterion at convergence: -1106.4
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.0462 -0.6640 -0.1532  0.6146  2.9586 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 5.149e-06 0.002269
##  Site     (Intercept) 7.787e-06 0.002790
##  Room     (Intercept) 8.910e-07 0.000944
##  Residual             3.513e-05 0.005927
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                   Estimate Std. Error         df t value
## (Intercept)                      1.402e-02  1.934e-03  1.140e+01   7.247
## Treatment_bisFull               -1.515e-03  1.599e-03  1.447e+02  -0.947
## Treatment_bisSmart              -1.921e-04  1.789e-03  1.362e+02  -0.107
## Treatment_bisMixt_smart         -1.360e-03  1.989e-03  9.589e+01  -0.684
## SexMale                          1.678e-03  1.738e-03  1.481e+02   0.966
## RegionLuxembourg                -2.586e-04  2.130e-03  1.260e+01  -0.121
## Treatment_bisFull:SexMale        1.482e-04  2.442e-03  1.430e+02   0.061
## Treatment_bisSmart:SexMale      -3.943e-03  2.936e-03  1.500e+02  -1.343
## Treatment_bisMixt_smart:SexMale  8.966e-04  2.909e-03  1.472e+02   0.308
##                                 Pr(>|t|)    
## (Intercept)                     1.35e-05 ***
## Treatment_bisFull                  0.345    
## Treatment_bisSmart                 0.915    
## Treatment_bisMixt_smart            0.496    
## SexMale                            0.336    
## RegionLuxembourg                   0.905    
## Treatment_bisFull:SexMale          0.952    
## Treatment_bisSmart:SexMale         0.181    
## Treatment_bisMixt_smart:SexMale    0.758    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_F:SM T_S:SM
## Trtmnt_bsFl -0.391                                                 
## Trtmnt_bsSm -0.334  0.413                                          
## Trtmnt_bsM_ -0.328  0.442  0.316                                   
## SexMale     -0.360  0.456  0.396  0.395                            
## ReginLxmbrg -0.552 -0.021 -0.023 -0.023 -0.036                     
## Trtmnt_F:SM  0.254 -0.671 -0.264 -0.316 -0.717  0.033              
## Trtmnt_S:SM  0.230 -0.277 -0.614 -0.259 -0.594 -0.001  0.424       
## Trtmn_M_:SM  0.211 -0.278 -0.249 -0.656 -0.606  0.024  0.436  0.375
summary(lmer(M0 ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) +  (1 | Room) + Treatment_bis:Sex, data = Data_AE_ref_smart))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: M0 ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) +  
##     (1 | Room) + Treatment_bis:Sex
##    Data: Data_AE_ref_smart
## 
## REML criterion at convergence: -1106.4
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.0462 -0.6640 -0.1532  0.6146  2.9586 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 5.149e-06 0.002269
##  Site     (Intercept) 7.787e-06 0.002790
##  Room     (Intercept) 8.910e-07 0.000944
##  Residual             3.513e-05 0.005927
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                   Estimate Std. Error         df t value
## (Intercept)                      1.383e-02  2.152e-03  1.419e+01   6.426
## Treatment_bisDark                1.921e-04  1.789e-03  1.362e+02   0.107
## Treatment_bisFull               -1.323e-03  1.843e-03  8.697e+01  -0.718
## Treatment_bisMixt_smart         -1.168e-03  2.215e-03  4.146e+01  -0.527
## SexMale                         -2.265e-03  2.361e-03  1.508e+02  -0.959
## RegionLuxembourg                -2.586e-04  2.130e-03  1.260e+01  -0.121
## Treatment_bisDark:SexMale        3.943e-03  2.936e-03  1.500e+02   1.343
## Treatment_bisFull:SexMale        4.091e-03  2.915e-03  1.499e+02   1.403
## Treatment_bisMixt_smart:SexMale  4.839e-03  3.267e-03  1.467e+02   1.481
##                                 Pr(>|t|)    
## (Intercept)                     1.48e-05 ***
## Treatment_bisDark                  0.915    
## Treatment_bisFull                  0.475    
## Treatment_bisMixt_smart            0.601    
## SexMale                            0.339    
## RegionLuxembourg                   0.905    
## Treatment_bisDark:SexMale          0.181    
## Treatment_bisFull:SexMale          0.163    
## Treatment_bisMixt_smart:SexMale    0.141    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trt_M_ SexMal RgnLxm T_D:SM T_F:SM
## Trtmnt_bsDr -0.531                                                 
## Trtmnt_bsFl -0.523  0.612                                          
## Trtmnt_bsM_ -0.457  0.523  0.564                                   
## SexMale     -0.375  0.473  0.452  0.353                            
## ReginLxmbrg -0.515  0.023  0.003 -0.002 -0.028                     
## Trtmnt_D:SM  0.304 -0.614 -0.356 -0.263 -0.806  0.001              
## Trtmnt_F:SM  0.314 -0.397 -0.632 -0.324 -0.812  0.028  0.652       
## Trtmn_M_:SM  0.258 -0.331 -0.320 -0.582 -0.706  0.022  0.565  0.574
summary(lmer(M0 ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) +  (1 | Room) + Treatment_bis:Sex, data = Data_AE_ref_full))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: M0 ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) +  
##     (1 | Room) + Treatment_bis:Sex
##    Data: Data_AE_ref_full
## 
## REML criterion at convergence: -1106.4
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.0462 -0.6640 -0.1532  0.6146  2.9586 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 5.149e-06 0.002269
##  Site     (Intercept) 7.787e-06 0.002790
##  Room     (Intercept) 8.910e-07 0.000944
##  Residual             3.513e-05 0.005927
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                   Estimate Std. Error         df t value
## (Intercept)                      1.250e-02  1.970e-03  1.214e+01   6.347
## Treatment_bisDark                1.515e-03  1.599e-03  1.447e+02   0.947
## Treatment_bisSmart               1.323e-03  1.843e-03  8.697e+01   0.718
## Treatment_bisMixt_smart          1.554e-04  1.924e-03  1.354e+02   0.081
## SexMale                          1.826e-03  1.701e-03  1.425e+02   1.074
## RegionLuxembourg                -2.586e-04  2.130e-03  1.260e+01  -0.121
## Treatment_bisDark:SexMale       -1.482e-04  2.442e-03  1.430e+02  -0.061
## Treatment_bisSmart:SexMale      -4.091e-03  2.915e-03  1.499e+02  -1.403
## Treatment_bisMixt_smart:SexMale  7.484e-04  2.870e-03  1.449e+02   0.261
##                                 Pr(>|t|)    
## (Intercept)                     3.49e-05 ***
## Treatment_bisDark                  0.345    
## Treatment_bisSmart                 0.475    
## Treatment_bisMixt_smart            0.936    
## SexMale                            0.285    
## RegionLuxembourg                   0.905    
## Treatment_bisDark:SexMale          0.952    
## Treatment_bisSmart:SexMale         0.163    
## Treatment_bisMixt_smart:SexMale    0.795    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S Trt_M_ SexMal RgnLxm T_D:SM T_S:SM
## Trtmnt_bsDr -0.428                                                 
## Trtmnt_bsSm -0.365  0.467                                          
## Trtmnt_bsM_ -0.317  0.374  0.309                                   
## SexMale     -0.407  0.497  0.456  0.362                            
## ReginLxmbrg -0.559  0.021 -0.003 -0.006  0.011                     
## Trtmnt_D:SM  0.295 -0.671 -0.326 -0.232 -0.703 -0.033              
## Trtmnt_S:SM  0.248 -0.284 -0.632 -0.232 -0.587 -0.028  0.410       
## Trtmn_M_:SM  0.232 -0.289 -0.277 -0.650 -0.591 -0.004  0.409  0.362
summary(lmer(M0 ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) +  (1 | Room) + Treatment_bis:Sex, data = Data_AE_ref_mixt_smart))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: M0 ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) +  
##     (1 | Room) + Treatment_bis:Sex
##    Data: Data_AE_ref_mixt_smart
## 
## REML criterion at convergence: -1106.4
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.0462 -0.6640 -0.1532  0.6146  2.9586 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 5.149e-06 0.002269
##  Site     (Intercept) 7.787e-06 0.002790
##  Room     (Intercept) 8.910e-07 0.000944
##  Residual             3.513e-05 0.005927
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                              Estimate Std. Error         df t value Pr(>|t|)
## (Intercept)                 1.266e-02  2.275e-03  1.668e+01   5.565 3.67e-05
## Treatment_bisDark           1.360e-03  1.989e-03  9.589e+01   0.684    0.496
## Treatment_bisFull          -1.554e-04  1.924e-03  1.354e+02  -0.081    0.936
## Treatment_bisSmart          1.168e-03  2.215e-03  4.146e+01   0.527    0.601
## SexMale                     2.575e-03  2.315e-03  1.455e+02   1.112    0.268
## RegionLuxembourg           -2.586e-04  2.130e-03  1.260e+01  -0.121    0.905
## Treatment_bisDark:SexMale  -8.966e-04  2.909e-03  1.472e+02  -0.308    0.758
## Treatment_bisFull:SexMale  -7.484e-04  2.870e-03  1.449e+02  -0.261    0.795
## Treatment_bisSmart:SexMale -4.839e-03  3.267e-03  1.467e+02  -1.481    0.141
##                               
## (Intercept)                ***
## Treatment_bisDark             
## Treatment_bisFull             
## Treatment_bisSmart            
## SexMale                       
## RegionLuxembourg              
## Treatment_bisDark:SexMale     
## Treatment_bisFull:SexMale     
## Treatment_bisSmart:SexMale    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trtm_S SexMal RgnLxm T_D:SM T_F:SM
## Trtmnt_bsDr -0.596                                                 
## Trtmnt_bsFl -0.571  0.666                                          
## Trtmnt_bsSm -0.541  0.643  0.611                                   
## SexMale     -0.466  0.528  0.540  0.462                            
## ReginLxmbrg -0.490  0.023  0.006  0.002  0.003                     
## Trtmnt_D:SM  0.394 -0.656 -0.447 -0.388 -0.802 -0.024              
## Trtmnt_F:SM  0.349 -0.396 -0.650 -0.334 -0.805  0.004  0.643       
## Trtmnt_S:SM  0.323 -0.351 -0.364 -0.582 -0.691 -0.022  0.553  0.555
test1 <- data.frame(Reference = "Dark", as.data.frame(( summary(LM_M0_1_AE)$coeff)[,]))

test2 <- data.frame(Reference = "Smart", as.data.frame(( summary(lmer(M0 ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) +  (1 | Room) + Treatment_bis:Sex, data = Data_AE_ref_smart))$coeff)[,]))

test3 <- data.frame(Reference = "Full", as.data.frame(( summary(lmer(M0 ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) +  (1 | Room) + Treatment_bis:Sex, data = Data_AE_ref_full))$coeff)[,]))

test4 <- data.frame(Reference = "Mixt_smart", as.data.frame(( summary(lmer(M0 ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) +  (1 | Room) + Treatment_bis:Sex, data = Data_AE_ref_mixt_smart))$coeff)[,]))

Results_M0_AE <- rbind(test1,test2,test3,test4)

colnames(Results_M0_AE ) <- c("Reference","Estimate", "Std. Error", "df", "t.value", "Pr(>|z|)")

write.csv2( Results_M0_AE , file = "output/Results_M0_AE.csv" )

kable(Results_M0_AE , caption = " Poids inital AE ", padding = 1 )
Poids inital AE
Reference Estimate Std. Error df t.value Pr(>|z|)
(Intercept) Dark 0.0140190 0.0019344 11.40235 7.2472755 0.0000135
Treatment_bisFull Dark -0.0015153 0.0015994 144.67510 -0.9473976 0.3450159
Treatment_bisSmart Dark -0.0001921 0.0017889 136.15414 -0.1073595 0.9146619
Treatment_bisMixt_smart Dark -0.0013599 0.0019894 95.88649 -0.6835834 0.4958869
SexMale Dark 0.0016783 0.0017376 148.07944 0.9658657 0.3356861
RegionLuxembourg Dark -0.0002586 0.0021302 12.59660 -0.1214121 0.9052800
Treatment_bisFull:SexMale Dark 0.0001482 0.0024419 142.96874 0.0606870 0.9516933
Treatment_bisSmart:SexMale Dark -0.0039427 0.0029363 149.98292 -1.3427458 0.1813829
Treatment_bisMixt_smart:SexMale Dark 0.0008966 0.0029094 147.15856 0.3081664 0.7583915
(Intercept)1 Smart 0.0138269 0.0021517 14.19444 6.4260484 0.0000148
Treatment_bisDark Smart 0.0001921 0.0017889 136.15414 0.1073595 0.9146619
Treatment_bisFull1 Smart -0.0013232 0.0018430 86.96799 -0.7179751 0.4746969
Treatment_bisMixt_smart1 Smart -0.0011679 0.0022148 41.46048 -0.5272976 0.6007974
SexMale1 Smart -0.0022645 0.0023612 150.76195 -0.9590214 0.3390834
RegionLuxembourg1 Smart -0.0002586 0.0021302 12.59660 -0.1214121 0.9052800
Treatment_bisDark:SexMale Smart 0.0039427 0.0029363 149.98292 1.3427458 0.1813829
Treatment_bisFull:SexMale1 Smart 0.0040909 0.0029153 149.94530 1.4032438 0.1626116
Treatment_bisMixt_smart:SexMale1 Smart 0.0048393 0.0032674 146.68311 1.4810871 0.1407282
(Intercept)2 Full 0.0125037 0.0019699 12.14206 6.3473321 0.0000349
Treatment_bisDark1 Full 0.0015153 0.0015994 144.67510 0.9473976 0.3450159
Treatment_bisSmart1 Full 0.0013232 0.0018430 86.96799 0.7179751 0.4746969
Treatment_bisMixt_smart2 Full 0.0001554 0.0019236 135.43643 0.0807628 0.9357498
SexMale2 Full 0.0018265 0.0017013 142.48312 1.0735920 0.2848204
RegionLuxembourg2 Full -0.0002586 0.0021302 12.59660 -0.1214121 0.9052800
Treatment_bisDark:SexMale1 Full -0.0001482 0.0024419 142.96874 -0.0606870 0.9516933
Treatment_bisSmart:SexMale1 Full -0.0040909 0.0029153 149.94530 -1.4032438 0.1626116
Treatment_bisMixt_smart:SexMale2 Full 0.0007484 0.0028697 144.87347 0.2607928 0.7946226
(Intercept)3 Mixt_smart 0.0126591 0.0022748 16.68104 5.5648871 0.0000367
Treatment_bisDark2 Mixt_smart 0.0013599 0.0019894 95.88649 0.6835834 0.4958869
Treatment_bisFull2 Mixt_smart -0.0001554 0.0019236 135.43643 -0.0807628 0.9357498
Treatment_bisSmart2 Mixt_smart 0.0011679 0.0022148 41.46048 0.5272976 0.6007974
SexMale3 Mixt_smart 0.0025749 0.0023145 145.47190 1.1124769 0.2677682
RegionLuxembourg3 Mixt_smart -0.0002586 0.0021302 12.59660 -0.1214121 0.9052800
Treatment_bisDark:SexMale2 Mixt_smart -0.0008966 0.0029094 147.15856 -0.3081664 0.7583915
Treatment_bisFull:SexMale2 Mixt_smart -0.0007484 0.0028697 144.87347 -0.2607928 0.7946226
Treatment_bisSmart:SexMale2 Mixt_smart -0.0048393 0.0032674 146.68311 -1.4810871 0.1407282

Aucune différence significative de poids initial en fonction des traitements ou région ou sexe

6.17 Total_eaten OP

6.17.1 Test

LM_Total_eaten_OP <- lmer(Total_eaten ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_OP)
## boundary (singular) fit: see help('isSingular')
summary(LM_Total_eaten_OP)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Total_eaten ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data_OP
## 
## REML criterion at convergence: 718
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.24866 -0.69967 -0.09318  0.53341  2.88674 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept)  8.449   2.907   
##  Site     (Intercept)  0.000   0.000   
##  Room     (Intercept)  0.000   0.000   
##  Residual             10.237   3.200   
## Number of obs: 139, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                                      Estimate Std. Error        df t value
## (Intercept)                          18.15357    1.34723  11.01082  13.475
## Treatment_bisFull                    -0.06889    1.04989 120.14787  -0.066
## Treatment_bisSmart                    1.69339    1.53830 120.44026   1.101
## SexMale                              -1.32241    0.77954 119.40243  -1.696
## RegionLuxembourg                     -0.97306    1.87361  10.31823  -0.519
## Treatment_bisFull:SexMale             0.30329    1.22740 120.29875   0.247
## Treatment_bisSmart:SexMale           -0.05799    1.78031 122.24385  -0.033
## Treatment_bisFull:RegionLuxembourg    1.07805    1.20346 119.65951   0.896
## Treatment_bisSmart:RegionLuxembourg  -0.27879    1.78171 120.86496  -0.156
##                                     Pr(>|t|)    
## (Intercept)                         3.47e-08 ***
## Treatment_bisFull                     0.9478    
## Treatment_bisSmart                    0.2732    
## SexMale                               0.0924 .  
## RegionLuxembourg                      0.6145    
## Treatment_bisFull:SexMale             0.8053    
## Treatment_bisSmart:SexMale            0.9741    
## Treatment_bisFull:RegionLuxembourg    0.3722    
## Treatment_bisSmart:RegionLuxembourg   0.8759    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S SexMal RgnLxm T_F:SM T_S:SM T_F:RL
## Trtmnt_bsFl -0.267                                                 
## Trtmnt_bsSm -0.162  0.224                                          
## SexMale     -0.206  0.269  0.198                                   
## ReginLxmbrg -0.682  0.133  0.070 -0.030                            
## Trtmnt_F:SM  0.140 -0.568 -0.129 -0.634  0.029                     
## Trtmnt_S:SM  0.085 -0.123 -0.487 -0.456  0.042  0.298              
## Trtmnt_F:RL  0.171 -0.591 -0.140  0.038 -0.270  0.010 -0.022       
## Trtmnt_S:RL  0.103 -0.127 -0.595  0.031 -0.189 -0.040 -0.126  0.277
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Vérification des hypothèses

qqnorm(resid(LM_Total_eaten_OP))
qqline(resid(LM_Total_eaten_OP))

C’est très bon.

Homogénité des variances

plot(LM_Total_eaten_OP)

c’est correcte

Distance de cook

plot(cooks.distance(LM_Total_eaten_OP))

Un point semble énormément influencer le modèle, je pense qu’il est préférable de le retirer

Data_Total_eaten_OP <- (Data_OP %>% filter(Sex != "NA"))[unname(cooks.distance(LM_Total_eaten_OP) != max(cooks.distance(LM_Total_eaten_OP))),]

Data_Total_eaten_OP_ref_smart <- Data_Total_eaten_OP
Data_Total_eaten_OP_ref_smart$Treatment_bis <- relevel(Data_Total_eaten_OP$Treatment_bis, ref = "Smart")

Data_Total_eaten_OP_ref_full <- Data_Total_eaten_OP
Data_Total_eaten_OP_ref_full$Treatment_bis <- relevel(Data_Total_eaten_OP$Treatment_bis, ref = "Full")

et on refait les test

LM_Total_eaten_OP <- lmer(Total_eaten ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_Total_eaten_OP)
## boundary (singular) fit: see help('isSingular')

Vérification des hypothèses

qqnorm(resid(LM_Total_eaten_OP))
qqline(resid(LM_Total_eaten_OP))

C’est très bon.

Homogénité des variances

plot(LM_Total_eaten_OP)

c’est correcte

Distance de cook

plot(cooks.distance(LM_Total_eaten_OP))

6.17.2 Simplification du modèle

drop1(LM_Total_eaten_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Total_eaten ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##                      Sum Sq Mean Sq NumDF  DenDF F value Pr(>F)
## Treatment_bis:Sex     3.314  1.6570     2 119.70  0.1724 0.8418
## Treatment_bis:Region 17.383  8.6915     2 118.91  0.9045 0.4075
LM_Total_eaten1_OP <- update(LM_Total_eaten_OP, . ~ . - Treatment_bis:Sex)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Total_eaten1_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Total_eaten ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region
##                      Sum Sq Mean Sq NumDF  DenDF F value  Pr(>F)  
## Sex                  39.242  39.242     1 121.11  4.1325 0.04425 *
## Treatment_bis:Region 16.000   8.000     2 120.90  0.8425 0.43316  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Total_eaten2_OP <- update(LM_Total_eaten1_OP, . ~ . - Treatment_bis:Region)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Total_eaten2_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Total_eaten ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room)
##               Sum Sq Mean Sq NumDF   DenDF F value Pr(>F)  
## Treatment_bis 16.298   8.149     2 123.072  0.8574 0.4268  
## Sex           43.838  43.838     1 123.084  4.6126 0.0337 *
## Region         4.002   4.002     1   5.133  0.4211 0.5443  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

On arrête la simplification de modèle.

Est-ce qu’elle a été utile ?

AIC(LM_Total_eaten2_OP)
## [1] 731.8259
AIC(LM_Total_eaten_OP)
## [1] 727.7808

Non

6.17.3 Treatment VS Treatment_bis

AIC(lmer(Total_eaten ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_Total_eaten_OP))
## boundary (singular) fit: see help('isSingular')
## [1] 727.7808
AIC(lmer(Total_eaten ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment:Sex + Treatment:Region, data = Data_Total_eaten_OP))
## boundary (singular) fit: see help('isSingular')
## [1] 727.7255
summary(lmer(Total_eaten ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_Total_eaten_OP))$coeff
## boundary (singular) fit: see help('isSingular')
##                                        Estimate Std. Error        df
## (Intercept)                         18.12733331  1.1619093  11.04065
## Treatment_bisFull                   -0.03363087  1.0163663 119.06383
## Treatment_bisSmart                   1.19332307  1.4962120 119.11142
## SexMale                             -1.31715659  0.7549267 118.12777
## RegionLuxembourg                    -1.14003702  1.6094219  10.17740
## Treatment_bisFull:SexMale            0.25236977  1.1881265 119.34712
## Treatment_bisSmart:SexMale           1.02761472  1.7549765 120.24537
## Treatment_bisFull:RegionLuxembourg   1.00691238  1.1653922 118.42889
## Treatment_bisSmart:RegionLuxembourg -1.32092535  1.7534389 119.29191
##                                         t value     Pr(>|t|)
## (Intercept)                         15.60133184 7.191011e-09
## Treatment_bisFull                   -0.03308932 9.736588e-01
## Treatment_bisSmart                   0.79756280 4.267114e-01
## SexMale                             -1.74474768 8.362955e-02
## RegionLuxembourg                    -0.70835188 4.946308e-01
## Treatment_bisFull:SexMale            0.21240985 8.321497e-01
## Treatment_bisSmart:SexMale           0.58554330 5.592798e-01
## Treatment_bisFull:RegionLuxembourg   0.86401163 3.893281e-01
## Treatment_bisSmart:RegionLuxembourg -0.75333412 4.527334e-01
summary(lmer(Total_eaten ~ Treatment + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment:Sex + Treatment:Region, data = Data_Total_eaten_OP))$coeff
## boundary (singular) fit: see help('isSingular')
##                                     Estimate Std. Error         df      t value
## (Intercept)                     18.971512683  1.2007564  10.330774 15.799634397
## TreatmentFull                   -0.919164001  1.1104822 118.825677 -0.827716090
## TreatmentSmart                  -1.636353887  1.0711662 119.013783 -1.527637718
## SexMale                         -1.036123613  0.9343839 118.358743 -1.108884238
## RegionLuxembourg                -2.439095317  1.6491080   8.200123 -1.479039133
## TreatmentFull:SexMale           -0.030326341  1.3198484 119.903849 -0.022977140
## TreatmentSmart:SexMale          -0.005207723  1.3571577 118.632932 -0.003837227
## TreatmentFull:RegionLuxembourg   2.269954540  1.2923172 117.918351  1.756499504
## TreatmentSmart:RegionLuxembourg  2.360201515  1.3366530 118.335528  1.765754840
##                                     Pr(>|t|)
## (Intercept)                     1.432869e-08
## TreatmentFull                   4.094906e-01
## TreatmentSmart                  1.292559e-01
## SexMale                         2.697282e-01
## RegionLuxembourg                1.764858e-01
## TreatmentFull:SexMale           9.817067e-01
## TreatmentSmart:SexMale          9.969448e-01
## TreatmentFull:RegionLuxembourg  8.159913e-02
## TreatmentSmart:RegionLuxembourg 8.001608e-02

Aucun des 2 ne se justifie tellement par rapport à l’autre donc je vais continuer avec treatment_bis qui est plus fréquemment repris dans les autres modèles et plus rigoureux scientifiquement parlant.

6.17.4 Résultats

Analyse des P-val

summary(lmer(Total_eaten ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_Total_eaten_OP))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Total_eaten ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data_Total_eaten_OP
## 
## REML criterion at convergence: 701.8
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.3037 -0.7174 -0.0551  0.5424  2.5491 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 5.833e+00 2.4151344
##  Site     (Intercept) 1.966e-07 0.0004434
##  Room     (Intercept) 0.000e+00 0.0000000
##  Residual             9.609e+00 3.0998386
## Number of obs: 138, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                                      Estimate Std. Error        df t value
## (Intercept)                          18.12733    1.16191  11.04065  15.601
## Treatment_bisFull                    -0.03363    1.01637 119.06383  -0.033
## Treatment_bisSmart                    1.19332    1.49621 119.11142   0.798
## SexMale                              -1.31716    0.75493 118.12777  -1.745
## RegionLuxembourg                     -1.14004    1.60942  10.17740  -0.708
## Treatment_bisFull:SexMale             0.25237    1.18813 119.34712   0.212
## Treatment_bisSmart:SexMale            1.02761    1.75498 120.24537   0.586
## Treatment_bisFull:RegionLuxembourg    1.00691    1.16539 118.42889   0.864
## Treatment_bisSmart:RegionLuxembourg  -1.32093    1.75344 119.29191  -0.753
##                                     Pr(>|t|)    
## (Intercept)                         7.19e-09 ***
## Treatment_bisFull                     0.9737    
## Treatment_bisSmart                    0.4267    
## SexMale                               0.0836 .  
## RegionLuxembourg                      0.4946    
## Treatment_bisFull:SexMale             0.8321    
## Treatment_bisSmart:SexMale            0.5593    
## Treatment_bisFull:RegionLuxembourg    0.3893    
## Treatment_bisSmart:RegionLuxembourg   0.4527    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S SexMal RgnLxm T_F:SM T_S:SM T_F:RL
## Trtmnt_bsFl -0.298                                                 
## Trtmnt_bsSm -0.181  0.222                                          
## SexMale     -0.233  0.270  0.197                                   
## ReginLxmbrg -0.675  0.149  0.082 -0.033                            
## Trtmnt_F:SM  0.158 -0.568 -0.127 -0.634  0.032                     
## Trtmnt_S:SM  0.094 -0.119 -0.494 -0.448  0.039  0.289              
## Trtmnt_F:RL  0.191 -0.591 -0.138  0.038 -0.304  0.010 -0.023       
## Trtmnt_S:RL  0.114 -0.127 -0.566  0.030 -0.204 -0.036 -0.156  0.275
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(Total_eaten ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_Total_eaten_OP_ref_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Total_eaten ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data_Total_eaten_OP_ref_smart
## 
## REML criterion at convergence: 701.8
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.3037 -0.7174 -0.0551  0.5424  2.5491 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 5.833e+00 2.4151344
##  Site     (Intercept) 1.966e-07 0.0004434
##  Room     (Intercept) 0.000e+00 0.0000000
##  Residual             9.609e+00 3.0998386
## Number of obs: 138, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                                    Estimate Std. Error       df t value
## (Intercept)                         19.3207     1.7200  45.5666  11.233
## Treatment_bisDark                   -1.1933     1.4962 119.1114  -0.798
## Treatment_bisFull                   -1.2270     1.6111 119.3468  -0.762
## SexMale                             -0.2895     1.5695 119.9648  -0.184
## RegionLuxembourg                    -2.4610     2.1240  29.5655  -1.159
## Treatment_bisDark:SexMale           -1.0276     1.7550 120.2454  -0.586
## Treatment_bisFull:SexMale           -0.7752     1.8127 119.6454  -0.428
## Treatment_bisDark:RegionLuxembourg   1.3209     1.7534 119.2919   0.753
## Treatment_bisFull:RegionLuxembourg   2.3278     1.8189 119.2619   1.280
##                                    Pr(>|t|)    
## (Intercept)                        1.01e-14 ***
## Treatment_bisDark                     0.427    
## Treatment_bisFull                     0.448    
## SexMale                               0.854    
## RegionLuxembourg                      0.256    
## Treatment_bisDark:SexMale             0.559    
## Treatment_bisFull:SexMale             0.670    
## Treatment_bisDark:RegionLuxembourg    0.453    
## Treatment_bisFull:RegionLuxembourg    0.203    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F SexMal RgnLxm T_D:SM T_F:SM T_D:RL
## Trtmnt_bsDr -0.747                                                 
## Trtmnt_bsFl -0.699  0.788                                          
## SexMale     -0.403  0.458  0.423                                   
## ReginLxmbrg -0.634  0.405  0.381 -0.111                            
## Trtmnt_D:SM  0.366 -0.494 -0.384 -0.903  0.099                     
## Trtmnt_F:SM  0.352 -0.396 -0.530 -0.862  0.092  0.779              
## Trtmnt_D:RL  0.415 -0.566 -0.445  0.160 -0.671 -0.156 -0.128       
## Trtmnt_F:RL  0.406 -0.457 -0.586  0.149 -0.648 -0.135 -0.104  0.788
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(Total_eaten ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_Total_eaten_OP_ref_full ))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Total_eaten ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data_Total_eaten_OP_ref_full
## 
## REML criterion at convergence: 701.8
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.3037 -0.7174 -0.0551  0.5424  2.5491 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 5.833e+00 2.4151344
##  Site     (Intercept) 1.966e-07 0.0004434
##  Room     (Intercept) 0.000e+00 0.0000000
##  Residual             9.609e+00 3.0998386
## Number of obs: 138, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                                      Estimate Std. Error        df t value
## (Intercept)                          18.09370    1.29568  17.24936  13.965
## Treatment_bisDark                     0.03363    1.01637 119.06383   0.033
## Treatment_bisSmart                    1.22695    1.61114 119.34677   0.762
## SexMale                              -1.06479    0.91835 120.30814  -1.159
## RegionLuxembourg                     -0.13312    1.67622  12.09664  -0.079
## Treatment_bisDark:SexMale            -0.25237    1.18813 119.34712  -0.212
## Treatment_bisSmart:SexMale            0.77524    1.81269 119.64544   0.428
## Treatment_bisDark:RegionLuxembourg   -1.00691    1.16539 118.42889  -0.864
## Treatment_bisSmart:RegionLuxembourg  -2.32784    1.81890 119.26195  -1.280
##                                     Pr(>|t|)    
## (Intercept)                          7.8e-11 ***
## Treatment_bisDark                      0.974    
## Treatment_bisSmart                     0.448    
## SexMale                                0.249    
## RegionLuxembourg                       0.938    
## Treatment_bisDark:SexMale              0.832    
## Treatment_bisSmart:SexMale             0.670    
## Treatment_bisDark:RegionLuxembourg     0.389    
## Treatment_bisSmart:RegionLuxembourg    0.203    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S SexMal RgnLxm T_D:SM T_S:SM T_D:RL
## Trtmnt_bsDr -0.517                                                 
## Trtmnt_bsSm -0.315  0.424                                          
## SexMale     -0.391  0.513  0.322                                   
## ReginLxmbrg -0.672  0.268  0.153  0.044                            
## Trtmnt_D:SM  0.304 -0.568 -0.241 -0.772 -0.037                     
## Trtmnt_S:SM  0.191 -0.257 -0.530 -0.500 -0.004  0.376              
## Trtmnt_D:RL  0.292 -0.591 -0.245 -0.044 -0.404  0.010  0.029       
## Trtmnt_S:RL  0.190 -0.256 -0.586 -0.049 -0.263  0.041 -0.104  0.376
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
test1 <- data.frame(Reference = "Dark", as.data.frame(( summary(lmer(Total_eaten ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_Total_eaten_OP))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test2 <- data.frame(Reference = "Smart", as.data.frame(( summary(lmer(Total_eaten ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_Total_eaten_OP_ref_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test3 <- data.frame(Reference = "Full", as.data.frame(( summary(lmer(Total_eaten ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_Total_eaten_OP_ref_full ))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
Results_Total_eaten_OP <- rbind(test1,test2,test3)

colnames(Results_Total_eaten_OP ) <- c("Reference","Estimate", "Std. Error", "df", "t.value", "Pr(>|z|)")

write.csv2( Results_Total_eaten_OP , file = "output/Results_Total_eaten_OP.csv" )

kable(Results_Total_eaten_OP , caption = " Quantité mangée OP ", padding = 1 )
Quantité mangée OP
Reference Estimate Std. Error df t.value Pr(>|z|)
(Intercept) Dark 18.1273333 1.1619093 11.04065 15.6013318 0.0000000
Treatment_bisFull Dark -0.0336309 1.0163663 119.06383 -0.0330893 0.9736588
Treatment_bisSmart Dark 1.1933231 1.4962120 119.11142 0.7975628 0.4267114
SexMale Dark -1.3171566 0.7549267 118.12777 -1.7447477 0.0836295
RegionLuxembourg Dark -1.1400370 1.6094219 10.17740 -0.7083519 0.4946308
Treatment_bisFull:SexMale Dark 0.2523698 1.1881265 119.34712 0.2124099 0.8321497
Treatment_bisSmart:SexMale Dark 1.0276147 1.7549765 120.24537 0.5855433 0.5592798
Treatment_bisFull:RegionLuxembourg Dark 1.0069124 1.1653922 118.42889 0.8640116 0.3893281
Treatment_bisSmart:RegionLuxembourg Dark -1.3209253 1.7534389 119.29191 -0.7533341 0.4527334
(Intercept)1 Smart 19.3206564 1.7200318 45.56658 11.2327321 0.0000000
Treatment_bisDark Smart -1.1933231 1.4962120 119.11142 -0.7975628 0.4267114
Treatment_bisFull1 Smart -1.2269539 1.6111442 119.34677 -0.7615420 0.4478356
SexMale1 Smart -0.2895419 1.5695339 119.96478 -0.1844763 0.8539513
RegionLuxembourg1 Smart -2.4609624 2.1240277 29.56550 -1.1586301 0.2558803
Treatment_bisDark:SexMale Smart -1.0276147 1.7549765 120.24537 -0.5855433 0.5592798
Treatment_bisFull:SexMale1 Smart -0.7752450 1.8126884 119.64544 -0.4276769 0.6696551
Treatment_bisDark:RegionLuxembourg Smart 1.3209253 1.7534389 119.29191 0.7533341 0.4527334
Treatment_bisFull:RegionLuxembourg1 Smart 2.3278377 1.8189034 119.26195 1.2798028 0.2030985
(Intercept)2 Full 18.0937024 1.2956818 17.24936 13.9646184 0.0000000
Treatment_bisDark1 Full 0.0336309 1.0163663 119.06383 0.0330893 0.9736588
Treatment_bisSmart1 Full 1.2269539 1.6111442 119.34677 0.7615420 0.4478356
SexMale2 Full -1.0647868 0.9183491 120.30814 -1.1594575 0.2485657
RegionLuxembourg2 Full -0.1331246 1.6762151 12.09664 -0.0794198 0.9379975
Treatment_bisDark:SexMale1 Full -0.2523698 1.1881265 119.34712 -0.2124099 0.8321497
Treatment_bisSmart:SexMale1 Full 0.7752450 1.8126884 119.64544 0.4276769 0.6696551
Treatment_bisDark:RegionLuxembourg1 Full -1.0069124 1.1653922 118.42889 -0.8640116 0.3893281
Treatment_bisSmart:RegionLuxembourg1 Full -2.3278377 1.8189034 119.26195 -1.2798028 0.2030985
Info_Total_eaten_OP <- "
Mâles Dark mangent presque significativement moins
"
Info_Total_eaten_OP
## [1] "\nMâles Dark mangent presque significativement moins\n"

6.18 Total_eaten AE

6.18.1 Test

LM_Total_eaten_AE <- lmer(Total_eaten ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_AE)
## boundary (singular) fit: see help('isSingular')
summary(LM_Total_eaten_AE)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Total_eaten ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##    Data: Data_AE
## 
## REML criterion at convergence: 1396.6
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -1.3713 -0.6489 -0.1503  0.3957  4.4909 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 172.20   13.123  
##  Site     (Intercept)  57.69    7.596  
##  Room     (Intercept)   0.00    0.000  
##  Residual             348.77   18.675  
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                          Estimate Std. Error       df t value
## (Intercept)                               66.1000     6.5508  16.0823  10.090
## Treatment_bisFull                         -1.5241     5.9526 136.1193  -0.256
## Treatment_bisSmart                        -3.4811     6.8808 135.6675  -0.506
## Treatment_bisMixt_smart                   -0.8384     7.0900 136.7241  -0.118
## SexMale                                   -1.3826     5.5283 138.8362  -0.250
## RegionLuxembourg                           7.2408     8.9250  16.1877   0.811
## Treatment_bisFull:SexMale                  4.0984     7.6764 136.6759   0.534
## Treatment_bisSmart:SexMale                -0.8524     9.4337 142.0837  -0.090
## Treatment_bisMixt_smart:SexMale          -11.8032     9.2709 137.7702  -1.273
## Treatment_bisFull:RegionLuxembourg         6.6069     7.6410 136.6415   0.865
## Treatment_bisSmart:RegionLuxembourg       -3.9513     8.6499 132.4259  -0.457
## Treatment_bisMixt_smart:RegionLuxembourg  22.4333     9.0685 136.6601   2.474
##                                          Pr(>|t|)    
## (Intercept)                              2.31e-08 ***
## Treatment_bisFull                          0.7983    
## Treatment_bisSmart                         0.6137    
## Treatment_bisMixt_smart                    0.9060    
## SexMale                                    0.8029    
## RegionLuxembourg                           0.4290    
## Treatment_bisFull:SexMale                  0.5943    
## Treatment_bisSmart:SexMale                 0.9281    
## Treatment_bisMixt_smart:SexMale            0.2051    
## Treatment_bisFull:RegionLuxembourg         0.3887    
## Treatment_bisSmart:RegionLuxembourg        0.6486    
## Treatment_bisMixt_smart:RegionLuxembourg   0.0146 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_F:SM T_S:SM T_M_:S
## Trtmnt_bsFl -0.420                                                        
## Trtmnt_bsSm -0.364  0.426                                                 
## Trtmnt_bsM_ -0.354  0.418  0.365                                          
## SexMale     -0.325  0.376  0.328  0.326                                   
## ReginLxmbrg -0.640  0.201  0.172  0.161 -0.050                            
## Trtmnt_F:SM  0.227 -0.566 -0.238 -0.241 -0.719  0.039                     
## Trtmnt_S:SM  0.198 -0.229 -0.491 -0.209 -0.595  0.028  0.428              
## Trtmn_M_:SM  0.185 -0.223 -0.200 -0.552 -0.608  0.047  0.441  0.379       
## Trtmnt_F:RL  0.230 -0.532 -0.228 -0.215  0.015 -0.422  0.006 -0.010 -0.028
## Trtmnt_S:RL  0.194 -0.227 -0.580 -0.186  0.029 -0.369 -0.021 -0.044 -0.031
## Trtmn_M_:RL  0.194 -0.223 -0.180 -0.515  0.019 -0.359 -0.015 -0.041 -0.049
##             T_F:RL T_S:RL
## Trtmnt_bsFl              
## Trtmnt_bsSm              
## Trtmnt_bsM_              
## SexMale                  
## ReginLxmbrg              
## Trtmnt_F:SM              
## Trtmnt_S:SM              
## Trtmn_M_:SM              
## Trtmnt_F:RL              
## Trtmnt_S:RL  0.449       
## Trtmn_M_:RL  0.452  0.379
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Vérification des hypothèses

qqnorm(resid(LM_Total_eaten_AE))
qqline(resid(LM_Total_eaten_AE))

il faudrait faire quelque chose

LM_Total_eaten_AE <- lmer(log(Total_eaten) ~ Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region, data = Data_AE)
## boundary (singular) fit: see help('isSingular')

Vérification des hypothèses

qqnorm(resid(LM_Total_eaten_AE))
qqline(resid(LM_Total_eaten_AE))

C’est très bon.

Homogénité des variances

plot(LM_Total_eaten_AE)

c’est correcte

Distance de cook

plot(cooks.distance(LM_Total_eaten_AE))

6.18.2 Simplification du modèle

drop1(LM_Total_eaten_AE)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Total_eaten) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region
##                       Sum Sq  Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Sex    0.24192 0.080641     3 137.51  1.3159 0.27179  
## Treatment_bis:Region 0.46110 0.153698     3 133.53  2.5080 0.06163 .
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Total_eaten1_AE <- update(LM_Total_eaten_AE, . ~ . - Treatment_bis:Sex)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Total_eaten1_AE)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Total_eaten) ~ Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region
##                       Sum Sq Mean Sq NumDF  DenDF F value  Pr(>F)  
## Sex                  0.04616 0.04616     1 140.63  0.7497 0.38805  
## Treatment_bis:Region 0.44095 0.14699     3 136.55  2.3872 0.07172 .
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

On arrête la simplification de modèle.

Est-ce qu’elle a été utile ?

AIC(LM_Total_eaten1_AE)
## [1] 96.1451
AIC(LM_Total_eaten_AE)
## [1] 106.0847

Oui

LM_Total_eaten_AE <- LM_Total_eaten1_AE

6.18.3 Treatment VS Treatment_bis

AIC(lmer(log(Total_eaten) ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE))
## boundary (singular) fit: see help('isSingular')
## [1] 96.1451
AIC(lmer(log(Total_eaten) ~ Treatment + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment:Region, data = Data_AE))
## [1] 96.10481
summary(lmer(log(Total_eaten) ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE))$coeff
## boundary (singular) fit: see help('isSingular')
##                                             Estimate Std. Error        df
## (Intercept)                               4.10639404 0.08561276  15.51237
## Treatment_bisFull                         0.05809835 0.06515423 135.88730
## Treatment_bisSmart                       -0.03344556 0.07961960 135.13695
## Treatment_bisMixt_smart                  -0.04254948 0.07853939 137.50970
## SexMale                                  -0.03579516 0.04134108 140.62833
## RegionLuxembourg                          0.15684714 0.12062512  17.56734
## Treatment_bisFull:RegionLuxembourg        0.01780827 0.10150200 139.32294
## Treatment_bisSmart:RegionLuxembourg      -0.06198166 0.11482138 135.16171
## Treatment_bisMixt_smart:RegionLuxembourg  0.26337095 0.12034511 139.40396
##                                             t value     Pr(>|t|)
## (Intercept)                              47.9647415 2.743436e-18
## Treatment_bisFull                         0.8917049 3.741274e-01
## Treatment_bisSmart                       -0.4200670 6.751037e-01
## Treatment_bisMixt_smart                  -0.5417598 5.888607e-01
## SexMale                                  -0.8658495 3.880475e-01
## RegionLuxembourg                          1.3002859 2.103043e-01
## Treatment_bisFull:RegionLuxembourg        0.1754475 8.609828e-01
## Treatment_bisSmart:RegionLuxembourg      -0.5398094 5.902167e-01
## Treatment_bisMixt_smart:RegionLuxembourg  2.1884640 3.030110e-02
summary(lmer(log(Total_eaten) ~ Treatment + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment:Region, data = Data_AE))$coeff
##                                     Estimate Std. Error        df     t value
## (Intercept)                      4.104303823 0.08807482  12.85549 46.60019553
## TreatmentFull                    0.055392422 0.06688990 137.13134  0.82811340
## TreatmentSmart                  -0.040372102 0.06672302 139.18905 -0.60507011
## SexMale                         -0.026152404 0.04223928 141.82338 -0.61914889
## RegionLuxembourg                 0.160070875 0.11815017  18.17954  1.35480867
## TreatmentFull:RegionLuxembourg   0.009257067 0.10409183 140.52199  0.08893174
## TreatmentSmart:RegionLuxembourg  0.074816408 0.09983705 139.17388  0.74938523
##                                     Pr(>|t|)
## (Intercept)                     1.010615e-15
## TreatmentFull                   4.090452e-01
## TreatmentSmart                  5.461176e-01
## SexMale                         5.368116e-01
## RegionLuxembourg                1.920769e-01
## TreatmentFull:RegionLuxembourg  9.292628e-01
## TreatmentSmart:RegionLuxembourg 4.548898e-01

Aucun des 2 ne se justifie tellement par rapport à l’autre donc je vais continuer avec treatment_bis qui est plus fréquemment repris dans les autres modèles et plus rigoureux scientifiquement parlant.

6.18.4 Résultats

Analyse des P-val

summary(lmer(log(Total_eaten) ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Total_eaten) ~ Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_AE
## 
## REML criterion at convergence: 70.1
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.1462 -0.6767 -0.0887  0.5050  3.7049 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.03117  0.1766  
##  Site     (Intercept) 0.01131  0.1063  
##  Room     (Intercept) 0.00000  0.0000  
##  Residual             0.06157  0.2481  
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                           Estimate Std. Error        df t value
## (Intercept)                                4.10639    0.08561  15.51237  47.965
## Treatment_bisFull                          0.05810    0.06515 135.88730   0.892
## Treatment_bisSmart                        -0.03345    0.07962 135.13695  -0.420
## Treatment_bisMixt_smart                   -0.04255    0.07854 137.50970  -0.542
## SexMale                                   -0.03580    0.04134 140.62833  -0.866
## RegionLuxembourg                           0.15685    0.12063  17.56734   1.300
## Treatment_bisFull:RegionLuxembourg         0.01781    0.10150 139.32294   0.175
## Treatment_bisSmart:RegionLuxembourg       -0.06198    0.11482 135.16171  -0.540
## Treatment_bisMixt_smart:RegionLuxembourg   0.26337    0.12035 139.40396   2.188
##                                          Pr(>|t|)    
## (Intercept)                                <2e-16 ***
## Treatment_bisFull                          0.3741    
## Treatment_bisSmart                         0.6751    
## Treatment_bisMixt_smart                    0.5889    
## SexMale                                    0.3880    
## RegionLuxembourg                           0.2103    
## Treatment_bisFull:RegionLuxembourg         0.8610    
## Treatment_bisSmart:RegionLuxembourg        0.5902    
## Treatment_bisMixt_smart:RegionLuxembourg   0.0303 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_F:RL T_S:RL
## Trtmnt_bsFl -0.364                                                 
## Trtmnt_bsSm -0.305  0.416                                          
## Trtmnt_bsM_ -0.307  0.431  0.351                                   
## SexMale     -0.195 -0.043  0.038 -0.018                            
## ReginLxmbrg -0.679  0.265  0.211  0.221 -0.017                     
## Trtmnt_F:RL  0.237 -0.641 -0.267 -0.277  0.011 -0.415              
## Trtmnt_S:RL  0.208 -0.289 -0.693 -0.243 -0.005 -0.362  0.449       
## Trtmn_M_:RL  0.208 -0.280 -0.230 -0.652 -0.025 -0.351  0.451  0.378
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Total_eaten) ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE_ref_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Total_eaten) ~ Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_AE_ref_smart
## 
## REML criterion at convergence: 70.1
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.1462 -0.6767 -0.0887  0.5049  3.7049 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.03117  0.1766  
##  Site     (Intercept) 0.01131  0.1063  
##  Room     (Intercept) 0.00000  0.0000  
##  Residual             0.06157  0.2481  
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                                4.072948   0.097489  24.905906
## Treatment_bisDark                          0.033446   0.079620 135.136945
## Treatment_bisFull                          0.091544   0.079196 132.914782
## Treatment_bisMixt_smart                   -0.009104   0.090128 133.371378
## SexMale                                   -0.035795   0.041341 140.628326
## RegionLuxembourg                           0.094866   0.133095  25.549094
## Treatment_bisDark:RegionLuxembourg         0.061982   0.114821 135.161704
## Treatment_bisFull:RegionLuxembourg         0.079790   0.114085 134.470671
## Treatment_bisMixt_smart:RegionLuxembourg   0.325353   0.131227 135.418880
##                                          t value Pr(>|t|)    
## (Intercept)                               41.779   <2e-16 ***
## Treatment_bisDark                          0.420   0.6751    
## Treatment_bisFull                          1.156   0.2498    
## Treatment_bisMixt_smart                   -0.101   0.9197    
## SexMale                                   -0.866   0.3880    
## RegionLuxembourg                           0.713   0.4825    
## Treatment_bisDark:RegionLuxembourg         0.540   0.5902    
## Treatment_bisFull:RegionLuxembourg         0.699   0.4855    
## Treatment_bisMixt_smart:RegionLuxembourg   2.479   0.0144 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trt_M_ SexMal RgnLxm T_D:RL T_F:RL
## Trtmnt_bsDr -0.548                                                 
## Trtmnt_bsFl -0.535  0.663                                          
## Trtmnt_bsM_ -0.470  0.578  0.588                                   
## SexMale     -0.140 -0.038 -0.074 -0.050                            
## ReginLxmbrg -0.715  0.406  0.401  0.350 -0.020                     
## Trtmnt_D:RL  0.383 -0.693 -0.458 -0.400  0.005 -0.535              
## Trtmnt_F:RL  0.376 -0.459 -0.691 -0.406  0.015 -0.528  0.607       
## Trtmn_M_:RL  0.330 -0.395 -0.400 -0.684 -0.019 -0.461  0.528  0.550
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Total_eaten) ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE_ref_full))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Total_eaten) ~ Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_AE_ref_full
## 
## REML criterion at convergence: 70.1
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.1462 -0.6767 -0.0887  0.5050  3.7049 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.03117  0.1766  
##  Site     (Intercept) 0.01131  0.1063  
##  Room     (Intercept) 0.00000  0.0000  
##  Residual             0.06157  0.2481  
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                           Estimate Std. Error        df t value
## (Intercept)                                4.16449    0.08669  16.64069  48.039
## Treatment_bisDark                         -0.05810    0.06515 135.88730  -0.892
## Treatment_bisSmart                        -0.09154    0.07920 132.91479  -1.156
## Treatment_bisMixt_smart                   -0.10065    0.07745 133.58249  -1.299
## SexMale                                   -0.03580    0.04134 140.62833  -0.866
## RegionLuxembourg                           0.17466    0.12125  18.54935   1.440
## Treatment_bisDark:RegionLuxembourg        -0.01781    0.10150 139.32294  -0.175
## Treatment_bisSmart:RegionLuxembourg       -0.07979    0.11408 134.47068  -0.699
## Treatment_bisMixt_smart:RegionLuxembourg   0.24556    0.11730 135.17563   2.094
##                                          Pr(>|t|)    
## (Intercept)                                <2e-16 ***
## Treatment_bisDark                          0.3741    
## Treatment_bisSmart                         0.2498    
## Treatment_bisMixt_smart                    0.1960    
## SexMale                                    0.3880    
## RegionLuxembourg                           0.1664    
## Treatment_bisDark:RegionLuxembourg         0.8610    
## Treatment_bisSmart:RegionLuxembourg        0.4855    
## Treatment_bisMixt_smart:RegionLuxembourg   0.0382 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_S Trt_M_ SexMal RgnLxm T_D:RL T_S:RL
## Trtmnt_bsDr -0.392                                                 
## Trtmnt_bsSm -0.312  0.405                                          
## Trtmnt_bsM_ -0.309  0.404  0.338                                   
## SexMale     -0.225  0.043  0.074  0.018                            
## ReginLxmbrg -0.677  0.273  0.211  0.218 -0.008                     
## Trtmnt_D:RL  0.248 -0.641 -0.259 -0.259 -0.011 -0.425              
## Trtmnt_S:RL  0.208 -0.279 -0.691 -0.234 -0.015 -0.362  0.438       
## Trtmn_M_:RL  0.209 -0.268 -0.225 -0.661 -0.036 -0.338  0.402  0.357
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(log(Total_eaten) ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE_ref_mixt_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Total_eaten) ~ Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment_bis:Region
##    Data: Data_AE_ref_mixt_smart
## 
## REML criterion at convergence: 70.1
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.1462 -0.6767 -0.0887  0.5050  3.7049 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.03117  0.1766  
##  Site     (Intercept) 0.01131  0.1063  
##  Room     (Intercept) 0.00000  0.0000  
##  Residual             0.06157  0.2481  
## Number of obs: 165, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                       Estimate Std. Error         df t value
## (Intercept)                           4.063845   0.096769  25.639744  41.995
## Treatment_bisDark                     0.042549   0.078539 137.509700   0.542
## Treatment_bisFull                     0.100648   0.077454 133.582489   1.299
## Treatment_bisSmart                    0.009104   0.090128 133.371384   0.101
## SexMale                              -0.035795   0.041341 140.628331  -0.866
## RegionLuxembourg                      0.420218   0.137267  28.731407   3.061
## Treatment_bisDark:RegionLuxembourg   -0.263371   0.120345 139.403956  -2.188
## Treatment_bisFull:RegionLuxembourg   -0.245563   0.117296 135.175629  -2.094
## Treatment_bisSmart:RegionLuxembourg  -0.325353   0.131227 135.418884  -2.479
##                                     Pr(>|t|)    
## (Intercept)                          < 2e-16 ***
## Treatment_bisDark                    0.58886    
## Treatment_bisFull                    0.19603    
## Treatment_bisSmart                   0.91969    
## SexMale                              0.38805    
## RegionLuxembourg                     0.00474 ** 
## Treatment_bisDark:RegionLuxembourg   0.03030 *  
## Treatment_bisFull:RegionLuxembourg   0.03817 *  
## Treatment_bisSmart:RegionLuxembourg  0.01439 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Trtm_D Trtm_F Trtm_S SexMal RgnLxm T_D:RL T_F:RL
## Trtmnt_bsDr -0.540                                                 
## Trtmnt_bsFl -0.524  0.651                                          
## Trtmnt_bsSm -0.458  0.562  0.562                                   
## SexMale     -0.188  0.018 -0.018  0.050                            
## ReginLxmbrg -0.673  0.377  0.372  0.314 -0.037                     
## Trtmnt_D:RL  0.345 -0.652 -0.426 -0.365  0.025 -0.568              
## Trtmnt_F:RL  0.341 -0.430 -0.661 -0.370  0.036 -0.556  0.635       
## Trtmnt_S:RL  0.304 -0.385 -0.387 -0.684  0.019 -0.509  0.586  0.584
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
test1 <- data.frame(Reference = "Dark", as.data.frame(( summary(lmer(log(Total_eaten) ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test2 <- data.frame(Reference = "Smart", as.data.frame(( summary(lmer(log(Total_eaten) ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE_ref_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test3 <- data.frame(Reference = "Full", as.data.frame(( summary(lmer(log(Total_eaten) ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE_ref_full))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test4 <- data.frame(Reference = "Mixt_smart", as.data.frame(( summary(lmer(log(Total_eaten) ~ Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Region, data = Data_AE_ref_mixt_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
Results_Total_eaten_AE <- rbind(test1,test2,test3,test4)

colnames(Results_Total_eaten_AE ) <- c("Reference","Estimate", "Std. Error", "df", "t.value", "Pr(>|z|)")

write.csv2( Results_Total_eaten_AE , file = "output/Results_Total_eaten_AE.csv" )

kable(Results_Total_eaten_AE , caption = " Quantité mangée AE ", padding = 1 )
Quantité mangée AE
Reference Estimate Std. Error df t.value Pr(>|z|)
(Intercept) Dark 4.1063940 0.0856128 15.51237 47.9647415 0.0000000
Treatment_bisFull Dark 0.0580983 0.0651542 135.88730 0.8917049 0.3741274
Treatment_bisSmart Dark -0.0334456 0.0796196 135.13695 -0.4200670 0.6751037
Treatment_bisMixt_smart Dark -0.0425495 0.0785394 137.50970 -0.5417598 0.5888607
SexMale Dark -0.0357952 0.0413411 140.62833 -0.8658495 0.3880475
RegionLuxembourg Dark 0.1568471 0.1206251 17.56734 1.3002859 0.2103043
Treatment_bisFull:RegionLuxembourg Dark 0.0178083 0.1015020 139.32294 0.1754475 0.8609828
Treatment_bisSmart:RegionLuxembourg Dark -0.0619817 0.1148214 135.16171 -0.5398094 0.5902167
Treatment_bisMixt_smart:RegionLuxembourg Dark 0.2633710 0.1203451 139.40396 2.1884640 0.0303011
(Intercept)1 Smart 4.0729485 0.0974888 24.90591 41.7786403 0.0000000
Treatment_bisDark Smart 0.0334455 0.0796196 135.13694 0.4200664 0.6751041
Treatment_bisFull1 Smart 0.0915439 0.0791965 132.91478 1.1559092 0.2497918
Treatment_bisMixt_smart1 Smart -0.0091039 0.0901281 133.37138 -0.1010105 0.9196938
SexMale1 Smart -0.0357952 0.0413411 140.62833 -0.8658498 0.3880473
RegionLuxembourg1 Smart 0.0948656 0.1330951 25.54909 0.7127659 0.4824502
Treatment_bisDark:RegionLuxembourg Smart 0.0619817 0.1148214 135.16170 0.5398097 0.5902165
Treatment_bisFull:RegionLuxembourg1 Smart 0.0797899 0.1140848 134.47067 0.6993913 0.4855155
Treatment_bisMixt_smart:RegionLuxembourg1 Smart 0.3253526 0.1312269 135.41888 2.4793135 0.0143913
(Intercept)2 Full 4.1644924 0.0866894 16.64069 48.0392100 0.0000000
Treatment_bisDark1 Full -0.0580983 0.0651542 135.88730 -0.8917049 0.3741274
Treatment_bisSmart1 Full -0.0915439 0.0791965 132.91479 -1.1559092 0.2497918
Treatment_bisMixt_smart2 Full -0.1006478 0.0774540 133.58249 -1.2994538 0.1960264
SexMale2 Full -0.0357952 0.0413411 140.62833 -0.8658495 0.3880475
RegionLuxembourg2 Full 0.1746554 0.1212467 18.54935 1.4404961 0.1663937
Treatment_bisDark:RegionLuxembourg1 Full -0.0178083 0.1015020 139.32294 -0.1754475 0.8609828
Treatment_bisSmart:RegionLuxembourg1 Full -0.0797899 0.1140848 134.47068 -0.6993914 0.4855155
Treatment_bisMixt_smart:RegionLuxembourg2 Full 0.2455627 0.1172965 135.17563 2.0935215 0.0381708
(Intercept)3 Mixt_smart 4.0638446 0.0967694 25.63974 41.9951320 0.0000000
Treatment_bisDark2 Mixt_smart 0.0425495 0.0785394 137.50970 0.5417598 0.5888607
Treatment_bisFull2 Mixt_smart 0.1006478 0.0774540 133.58249 1.2994538 0.1960264
Treatment_bisSmart2 Mixt_smart 0.0091039 0.0901281 133.37138 0.1010109 0.9196935
SexMale3 Mixt_smart -0.0357952 0.0413411 140.62833 -0.8658495 0.3880475
RegionLuxembourg3 Mixt_smart 0.4202181 0.1372665 28.73141 3.0613301 0.0047442
Treatment_bisDark:RegionLuxembourg2 Mixt_smart -0.2633710 0.1203451 139.40396 -2.1884640 0.0303011
Treatment_bisFull:RegionLuxembourg2 Mixt_smart -0.2455627 0.1172965 135.17563 -2.0935215 0.0381708
Treatment_bisSmart:RegionLuxembourg2 Mixt_smart -0.3253526 0.1312269 135.41888 -2.4793134 0.0143913
Info_Total_eaten_AE <- "
Les individus dans le traitement mixt smart et qui étaient dans la région luxembourgeoise ont mangé significativement plus que l'effet de la région luxembourgeoise et de mixt smart additioné.
"
Info_Total_eaten_AE
## [1] "\nLes individus dans le traitement mixt smart et qui étaient dans la région luxembourgeoise ont mangé significativement plus que l'effet de la région luxembourgeoise et de mixt smart additioné.\n"

6.19 Pupa_mass * TT_pupation OP

6.19.1 Test

LM_Pupa_mass_by_TT_pupation_OP <- lmer(Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region + TT_pupation:Sex + TT_pupation:Region + TT_pupation:Treatment_bis, data = Data_OP)
## boundary (singular) fit: see help('isSingular')
summary(LM_Pupa_mass_by_TT_pupation_OP)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region +  
##     TT_pupation:Sex + TT_pupation:Region + TT_pupation:Treatment_bis
##    Data: Data_OP
## 
## REML criterion at convergence: -564.2
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.77466 -0.58566 -0.02733  0.61730  2.10290 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 2.049e-04 0.014316
##  Site     (Intercept) 0.000e+00 0.000000
##  Room     (Intercept) 1.312e-05 0.003622
##  Residual             2.110e-04 0.014527
## Number of obs: 127, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                                       Estimate Std. Error         df t value
## (Intercept)                          1.444e-01  1.879e-02  1.022e+02   7.685
## TT_pupation                          6.386e-04  1.159e-03  1.098e+02   0.551
## Treatment_bisFull                   -4.082e-03  2.145e-02  1.092e+02  -0.190
## Treatment_bisSmart                   1.340e-02  2.771e-02  1.120e+02   0.484
## SexMale                              2.404e-02  1.872e-02  1.103e+02   1.284
## RegionLuxembourg                    -4.539e-02  2.279e-02  9.121e+01  -1.991
## Treatment_bisFull:SexMale           -4.050e-03  5.955e-03  1.052e+02  -0.680
## Treatment_bisSmart:SexMale           2.084e-02  8.924e-03  1.072e+02   2.335
## Treatment_bisFull:RegionLuxembourg  -4.936e-04  5.846e-03  1.051e+02  -0.084
## Treatment_bisSmart:RegionLuxembourg -7.470e-03  8.943e-03  1.056e+02  -0.835
## TT_pupation:SexMale                 -1.690e-03  1.259e-03  1.104e+02  -1.343
## TT_pupation:RegionLuxembourg         2.667e-03  1.415e-03  1.115e+02   1.885
## TT_pupation:Treatment_bisFull        7.179e-04  1.406e-03  1.093e+02   0.511
## TT_pupation:Treatment_bisSmart      -1.044e-03  1.802e-03  1.120e+02  -0.579
##                                     Pr(>|t|)    
## (Intercept)                         9.68e-12 ***
## TT_pupation                           0.5828    
## Treatment_bisFull                     0.8494    
## Treatment_bisSmart                    0.6295    
## SexMale                               0.2017    
## RegionLuxembourg                      0.0494 *  
## Treatment_bisFull:SexMale             0.4979    
## Treatment_bisSmart:SexMale            0.0214 *  
## Treatment_bisFull:RegionLuxembourg    0.9329    
## Treatment_bisSmart:RegionLuxembourg   0.4054    
## TT_pupation:SexMale                   0.1822    
## TT_pupation:RegionLuxembourg          0.0621 .  
## TT_pupation:Treatment_bisFull         0.6106    
## TT_pupation:Treatment_bisSmart        0.5636    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 14 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Test des hypothèses

Normalité des réisuds

qqnorm(resid(LM_Pupa_mass_by_TT_pupation_OP))
qqline(resid(LM_Pupa_mass_by_TT_pupation_OP))

Homogénité des variances

plot(LM_Pupa_mass_by_TT_pupation_OP)

Distance de cook

plot(cooks.distance(LM_Pupa_mass_by_TT_pupation_OP))

6.19.2 Simplification du modèle

drop1(LM_Pupa_mass_by_TT_pupation_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + TT_pupation:Sex + TT_pupation:Region + TT_pupation:Treatment_bis
##                               Sum Sq    Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Sex         0.00157184 0.00078592     2 105.92  3.7239 0.02736 *
## Treatment_bis:Region      0.00015344 0.00007672     2 104.95  0.3635 0.69610  
## TT_pupation:Sex           0.00038041 0.00038041     1 110.37  1.8025 0.18217  
## TT_pupation:Region        0.00074974 0.00074974     1 111.53  3.5525 0.06206 .
## TT_pupation:Treatment_bis 0.00019789 0.00009895     2 108.48  0.4688 0.62699  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Pupa_mass_by_TT_pupation1_OP <- update(LM_Pupa_mass_by_TT_pupation_OP, . ~ . - Treatment_bis:Region)
drop1(LM_Pupa_mass_by_TT_pupation1_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + TT_pupation:Sex + TT_pupation:Region + TT_pupation:Treatment_bis
##                               Sum Sq    Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Sex         0.00145250 0.00072625     2 107.75  3.4793 0.03433 *
## TT_pupation:Sex           0.00043311 0.00043311     1 111.97  2.0750 0.15252  
## TT_pupation:Region        0.00072014 0.00072014     1 113.65  3.4501 0.06584 .
## TT_pupation:Treatment_bis 0.00027151 0.00013575     2 110.62  0.6504 0.52384  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Pupa_mass_by_TT_pupation2_OP <- update(LM_Pupa_mass_by_TT_pupation1_OP, . ~ . - TT_pupation:Treatment_bis)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Pupa_mass_by_TT_pupation2_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + TT_pupation:Sex + TT_pupation:Region
##                        Sum Sq    Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Sex  0.00170623 0.00085311     2 110.14  4.1273 0.01869 *
## TT_pupation:Sex    0.00031541 0.00031541     1 114.08  1.5259 0.21927  
## TT_pupation:Region 0.00061565 0.00061565     1 116.85  2.9784 0.08702 .
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Pupa_mass_by_TT_pupation3_OP <- update(LM_Pupa_mass_by_TT_pupation2_OP, . ~ . - TT_pupation:Sex)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Pupa_mass_by_TT_pupation3_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + TT_pupation:Region
##                        Sum Sq    Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Sex  0.00160162 0.00080081     2 111.52  3.8410 0.02437 *
## TT_pupation:Region 0.00067014 0.00067014     1 117.64  3.2143 0.07557 .
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Pupa_mass_by_TT_pupation4_OP <- update(LM_Pupa_mass_by_TT_pupation3_OP, . ~ . - TT_pupation:Region)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Pupa_mass_by_TT_pupation4_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex
##                       Sum Sq    Mean Sq NumDF   DenDF F value  Pr(>F)  
## TT_pupation       0.00063657 0.00063657     1 117.318  2.9851 0.08667 .
## Region            0.00013388 0.00013388     1   9.975  0.6278 0.44660  
## Treatment_bis:Sex 0.00159790 0.00079895     2 112.599  3.7465 0.02659 *
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Il n’y a plus d’interactions qui n’ont pas de P-val significative, nous décidons d’arrêter la simplification du modèle.

Est ce que cela a été utile

AIC(LM_Pupa_mass_by_TT_pupation4_OP)
## [1] -595.0125
AIC(LM_Pupa_mass_by_TT_pupation_OP)
## [1] -528.1728

Oui ca a été utile

LM_Pupa_mass_by_TT_pupation_OP <- LM_Pupa_mass_by_TT_pupation4_OP

6.19.3 Treatment VS Teatment_bis

AIC(lmer(Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex, data = Data_OP))
## boundary (singular) fit: see help('isSingular')
## [1] -595.0125
AIC(lmer(Pupa_mass ~ TT_pupation + Treatment + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment:Sex, data = Data_OP))
## boundary (singular) fit: see help('isSingular')
## [1] -597.3523
summary(lmer(Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex, data = Data_OP))$coeff
## boundary (singular) fit: see help('isSingular')
##                                 Estimate   Std. Error         df    t value
## (Intercept)                 0.1369587775 0.0120791491  52.219598 11.3384459
## TT_pupation                 0.0011490787 0.0006650799 117.317536  1.7277304
## Treatment_bisFull           0.0066872385 0.0041824362 110.862675  1.5988860
## Treatment_bisSmart         -0.0041703437 0.0064524187 114.316969 -0.6463226
## SexMale                    -0.0003893792 0.0037745429 112.349677 -0.1031593
## RegionLuxembourg           -0.0068409928 0.0086338757   9.974852 -0.7923432
## Treatment_bisFull:SexMale  -0.0038756611 0.0058557396 110.680361 -0.6618568
## Treatment_bisSmart:SexMale  0.0203645384 0.0086953419 114.683612  2.3420055
##                                Pr(>|t|)
## (Intercept)                1.072302e-15
## TT_pupation                8.666801e-02
## Treatment_bisFull          1.126922e-01
## Treatment_bisSmart         5.193659e-01
## SexMale                    9.180205e-01
## RegionLuxembourg           4.465952e-01
## Treatment_bisFull:SexMale  5.094386e-01
## Treatment_bisSmart:SexMale 2.090560e-02
summary(lmer(Pupa_mass ~ TT_pupation + Treatment + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment:Sex, data = Data_OP))$coeff
## boundary (singular) fit: see help('isSingular')
##                            Estimate   Std. Error        df    t value
## (Intercept)             0.132962522 0.0118416789  61.59946 11.2283506
## TT_pupation             0.001297626 0.0006569609 117.95508  1.9751948
## TreatmentFull           0.008322570 0.0045223261 110.02814  1.8403295
## TreatmentSmart          0.003021375 0.0043861891 110.88681  0.6888383
## SexMale                -0.001900135 0.0044575517 111.65676 -0.4262732
## RegionLuxembourg       -0.006933699 0.0089587164  10.01680 -0.7739612
## TreatmentFull:SexMale  -0.001997117 0.0063649682 111.09076 -0.3137670
## TreatmentSmart:SexMale  0.013208643 0.0066386542 110.20262  1.9896567
##                            Pr(>|t|)
## (Intercept)            1.536946e-16
## TT_pupation            5.058166e-02
## TreatmentFull          6.841489e-02
## TreatmentSmart         4.923638e-01
## SexMale                6.707294e-01
## RegionLuxembourg       4.568318e-01
## TreatmentFull:SexMale  7.542864e-01
## TreatmentSmart:SexMale 4.910575e-02

Rien de très différent, on peut garder Treatment qui serait mieux selon l’AIC

6.19.4 Résultats

Analyse des pval

summary(lmer(Pupa_mass ~ TT_pupation + Treatment + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment:Sex, data = Data_OP))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Pupa_mass ~ TT_pupation + Treatment + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment:Sex
##    Data: Data_OP
## 
## REML criterion at convergence: -621.4
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.60308 -0.61144 -0.07127  0.67163  2.31257 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 2.049e-04 1.432e-02
##  Site     (Intercept) 9.173e-14 3.029e-07
##  Room     (Intercept) 6.695e-06 2.588e-03
##  Residual             2.065e-04 1.437e-02
## Number of obs: 127, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                          Estimate Std. Error         df t value Pr(>|t|)    
## (Intercept)              0.132963   0.011842  61.599462  11.228   <2e-16 ***
## TT_pupation              0.001298   0.000657 117.955082   1.975   0.0506 .  
## TreatmentFull            0.008323   0.004522 110.028139   1.840   0.0684 .  
## TreatmentSmart           0.003021   0.004386 110.886805   0.689   0.4924    
## SexMale                 -0.001900   0.004458 111.656764  -0.426   0.6707    
## RegionLuxembourg        -0.006934   0.008959  10.016796  -0.774   0.4568    
## TreatmentFull:SexMale   -0.001997   0.006365 111.090764  -0.314   0.7543    
## TreatmentSmart:SexMale   0.013209   0.006639 110.202619   1.990   0.0491 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TT_ppt TrtmnF TrtmnS SexMal RgnLxm TrF:SM
## TT_pupation -0.809                                          
## TreatmntFll -0.159 -0.016                                   
## TretmntSmrt -0.088 -0.100  0.495                            
## SexMale     -0.181  0.023  0.475  0.474                     
## ReginLxmbrg -0.304 -0.058 -0.032 -0.042 -0.059              
## TrtmntFl:SM  0.062  0.074 -0.726 -0.366 -0.714  0.043       
## TrtmntSm:SM  0.060  0.065 -0.343 -0.666 -0.671  0.052  0.502
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(Pupa_mass ~ TT_pupation + Treatment + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment:Sex, data = Data_OP_ref_full))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Pupa_mass ~ TT_pupation + Treatment + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment:Sex
##    Data: Data_OP_ref_full
## 
## REML criterion at convergence: -621.4
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.60308 -0.61144 -0.07127  0.67163  2.31257 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 2.049e-04 1.432e-02
##  Site     (Intercept) 9.173e-14 3.029e-07
##  Room     (Intercept) 6.695e-06 2.588e-03
##  Residual             2.065e-04 1.437e-02
## Number of obs: 127, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                          Estimate Std. Error         df t value Pr(>|t|)    
## (Intercept)              0.141285   0.011987  63.691133  11.787   <2e-16 ***
## TT_pupation              0.001298   0.000657 117.955076   1.975   0.0506 .  
## TreatmentDark           -0.008323   0.004522 110.028139  -1.840   0.0684 .  
## TreatmentSmart          -0.005301   0.004476 110.140025  -1.184   0.2388    
## SexMale                 -0.003897   0.004460 110.208746  -0.874   0.3841    
## RegionLuxembourg        -0.006934   0.008959  10.016796  -0.774   0.4568    
## TreatmentDark:SexMale    0.001997   0.006365 111.090764   0.314   0.7543    
## TreatmentSmart:SexMale   0.015206   0.006495 109.861452   2.341   0.0210 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TT_ppt TrtmnD TrtmnS SexMal RgnLxm TrD:SM
## TT_pupation -0.806                                          
## TreatmntDrk -0.220  0.016                                   
## TretmntSmrt -0.125 -0.081  0.525                            
## SexMale     -0.304  0.129  0.561  0.519                     
## ReginLxmbrg -0.312 -0.058  0.032 -0.009  0.003              
## TrtmntDr:SM  0.213 -0.074 -0.726 -0.374 -0.714 -0.043       
## TrtmntSm:SM  0.137 -0.007 -0.360 -0.679 -0.653  0.011  0.467
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(Pupa_mass ~ TT_pupation + Treatment + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment:Sex, data = Data_OP_ref_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Pupa_mass ~ TT_pupation + Treatment + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment:Sex
##    Data: Data_OP_ref_smart
## 
## REML criterion at convergence: -621.4
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.60308 -0.61144 -0.07127  0.67163  2.31257 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev. 
##  Mother   (Intercept) 2.049e-04 1.432e-02
##  Site     (Intercept) 9.173e-14 3.029e-07
##  Room     (Intercept) 6.695e-06 2.588e-03
##  Residual             2.065e-04 1.437e-02
## Number of obs: 127, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                         Estimate Std. Error         df t value Pr(>|t|)    
## (Intercept)             0.135984   0.012259  67.398714  11.093   <2e-16 ***
## TT_pupation             0.001298   0.000657 117.955081   1.975   0.0506 .  
## TreatmentDark          -0.003021   0.004386 110.886805  -0.689   0.4924    
## TreatmentFull           0.005301   0.004476 110.140025   1.184   0.2388    
## SexMale                 0.011309   0.004922 110.740441   2.298   0.0235 *  
## RegionLuxembourg       -0.006934   0.008959  10.016796  -0.774   0.4568    
## TreatmentDark:SexMale  -0.013209   0.006639 110.202619  -1.990   0.0491 *  
## TreatmentFull:SexMale  -0.015206   0.006495 109.861452  -2.341   0.0210 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TT_ppt TrtmnD TrtmnF SexMal RgnLxm TrD:SM
## TT_pupation -0.817                                          
## TreatmntDrk -0.272  0.100                                   
## TreatmntFll -0.243  0.081  0.479                            
## SexMale     -0.248  0.108  0.468  0.426                     
## ReginLxmbrg -0.308 -0.058  0.042  0.009  0.017              
## TrtmntDr:SM  0.180 -0.065 -0.666 -0.306 -0.741 -0.052       
## TrtmntFl:SM  0.114  0.007 -0.322 -0.679 -0.728 -0.011  0.530
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
test1 <- data.frame(Reference = "Dark", as.data.frame(( summary(lmer(Pupa_mass ~ TT_pupation + Treatment + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment:Sex, data = Data_OP))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test2 <- data.frame(Reference = "Smart", as.data.frame(( summary(lmer(Pupa_mass ~ TT_pupation + Treatment + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment:Sex, data = Data_OP_ref_full))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test3 <- data.frame(Reference = "Full", as.data.frame(( summary(lmer(Pupa_mass ~ TT_pupation + Treatment + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment:Sex, data = Data_OP_ref_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
Results_Pupa_mass_by_TT_pupation_OP <- rbind(test1,test2,test3)

colnames(Results_Pupa_mass_by_TT_pupation_OP ) <- c("Reference","Estimate", "Std. Error", "df", "t.value", "Pr(>|z|)")

write.csv2( Results_Pupa_mass_by_TT_pupation_OP , file = "output/Results_Pupa_mass_by_TT_pupation_OP.csv" )

kable(Results_Pupa_mass_by_TT_pupation_OP , caption = " Poids des chrysalides en fonction du temps pour rentrer en chrysalide OP", padding = 1 )
Poids des chrysalides en fonction du temps pour rentrer en chrysalide OP
Reference Estimate Std. Error df t.value Pr(>|z|)
(Intercept) Dark 0.1329625 0.0118417 61.59946 11.2283506 0.0000000
TT_pupation Dark 0.0012976 0.0006570 117.95508 1.9751948 0.0505817
TreatmentFull Dark 0.0083226 0.0045223 110.02814 1.8403295 0.0684149
TreatmentSmart Dark 0.0030214 0.0043862 110.88681 0.6888383 0.4923638
SexMale Dark -0.0019001 0.0044576 111.65676 -0.4262732 0.6707294
RegionLuxembourg Dark -0.0069337 0.0089587 10.01680 -0.7739612 0.4568318
TreatmentFull:SexMale Dark -0.0019971 0.0063650 111.09076 -0.3137670 0.7542864
TreatmentSmart:SexMale Dark 0.0132086 0.0066387 110.20262 1.9896567 0.0491057
(Intercept)1 Smart 0.1412851 0.0119866 63.69113 11.7868894 0.0000000
TT_pupation1 Smart 0.0012976 0.0006570 117.95508 1.9751948 0.0505817
TreatmentDark Smart -0.0083226 0.0045223 110.02814 -1.8403295 0.0684149
TreatmentSmart1 Smart -0.0053012 0.0044760 110.14002 -1.1843581 0.2388209
SexMale1 Smart -0.0038973 0.0044596 110.20875 -0.8739025 0.3840717
RegionLuxembourg1 Smart -0.0069337 0.0089587 10.01680 -0.7739612 0.4568318
TreatmentDark:SexMale Smart 0.0019971 0.0063650 111.09076 0.3137670 0.7542864
TreatmentSmart:SexMale1 Smart 0.0152058 0.0064951 109.86145 2.3411298 0.0210293
(Intercept)2 Full 0.1359839 0.0122589 67.39871 11.0926521 0.0000000
TT_pupation2 Full 0.0012976 0.0006570 117.95508 1.9751948 0.0505817
TreatmentDark1 Full -0.0030214 0.0043862 110.88680 -0.6888383 0.4923638
TreatmentFull1 Full 0.0053012 0.0044760 110.14002 1.1843581 0.2388209
SexMale2 Full 0.0113085 0.0049221 110.74044 2.2975077 0.0234689
RegionLuxembourg2 Full -0.0069337 0.0089587 10.01680 -0.7739612 0.4568318
TreatmentDark:SexMale1 Full -0.0132086 0.0066387 110.20262 -1.9896567 0.0491057
TreatmentFull:SexMale1 Full -0.0152058 0.0064951 109.86145 -2.3411298 0.0210293
Info_Pupa_mass_by_TT_pupation_OP <- "
Au plus un individu met du temps pour entrer en chrysaldie, au plus sa chrysaldie est lourde (ce n'est pas parfaitement significatif p-val = 0.0506)
Les individus en traitement Full ont quasiment significativement (p-val = 0.0684) des chrysalides plus lourdes (0.0083 g) que les inbdividus en traitement dark. 
Les chrysalides des individus mâles du traitement Smart sont significativements (p-val = 0.0235) plus lourdes (0.011 g) que celles des femelles.
"
Info_Pupa_mass_by_TT_pupation_OP
## [1] "\nAu plus un individu met du temps pour entrer en chrysaldie, au plus sa chrysaldie est lourde (ce n'est pas parfaitement significatif p-val = 0.0506)\nLes individus en traitement Full ont quasiment significativement (p-val = 0.0684) des chrysalides plus lourdes (0.0083 g) que les inbdividus en traitement dark. \nLes chrysalides des individus mâles du traitement Smart sont significativements (p-val = 0.0235) plus lourdes (0.011 g) que celles des femelles.\n"

6.20 Pupa_mass * TT_pupation AE

6.20.1 Test

LM_Pupa_mass_by_TT_pupation_AE <- lmer(Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region + TT_pupation:Sex + TT_pupation:Region + TT_pupation:Treatment_bis, data = Data_AE)
## boundary (singular) fit: see help('isSingular')
summary(LM_Pupa_mass_by_TT_pupation_AE)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region +  
##     TT_pupation:Sex + TT_pupation:Region + TT_pupation:Treatment_bis
##    Data: Data_AE
## 
## REML criterion at convergence: -346.9
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.75030 -0.51678  0.01297  0.56880  2.29821 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  Mother   (Intercept) 0.000340 0.01844 
##  Site     (Intercept) 0.000177 0.01330 
##  Room     (Intercept) 0.000000 0.00000 
##  Residual             0.002600 0.05099 
## Number of obs: 161, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                               1.742e-01  3.086e-02  1.237e+02
## TT_pupation                               3.350e-03  6.219e-04  1.396e+02
## Treatment_bisFull                         4.181e-03  3.807e-02  1.343e+02
## Treatment_bisSmart                        2.572e-02  5.819e-02  1.390e+02
## Treatment_bisMixt_smart                   8.286e-02  5.571e-02  1.405e+02
## SexMale                                   1.419e-02  3.583e-02  1.363e+02
## RegionLuxembourg                          8.641e-02  4.316e-02  1.048e+02
## Treatment_bisFull:SexMale                -1.078e-02  2.156e-02  1.324e+02
## Treatment_bisSmart:SexMale               -4.973e-02  2.561e-02  1.400e+02
## Treatment_bisMixt_smart:SexMale          -5.793e-02  2.593e-02  1.371e+02
## Treatment_bisFull:RegionLuxembourg        2.844e-04  2.191e-02  1.285e+02
## Treatment_bisSmart:RegionLuxembourg       1.419e-02  2.466e-02  1.304e+02
## Treatment_bisMixt_smart:RegionLuxembourg  2.414e-02  3.049e-02  1.366e+02
## TT_pupation:SexMale                       2.963e-04  7.296e-04  1.376e+02
## TT_pupation:RegionLuxembourg             -1.975e-03  8.467e-04  1.397e+02
## TT_pupation:Treatment_bisFull             5.285e-04  8.704e-04  1.324e+02
## TT_pupation:Treatment_bisSmart            1.301e-06  1.365e-03  1.401e+02
## TT_pupation:Treatment_bisMixt_smart      -3.124e-04  1.240e-03  1.421e+02
##                                          t value Pr(>|t|)    
## (Intercept)                                5.646 1.07e-07 ***
## TT_pupation                                5.387 2.97e-07 ***
## Treatment_bisFull                          0.110   0.9127    
## Treatment_bisSmart                         0.442   0.6592    
## Treatment_bisMixt_smart                    1.487   0.1392    
## SexMale                                    0.396   0.6926    
## RegionLuxembourg                           2.002   0.0478 *  
## Treatment_bisFull:SexMale                 -0.500   0.6180    
## Treatment_bisSmart:SexMale                -1.942   0.0541 .  
## Treatment_bisMixt_smart:SexMale           -2.234   0.0271 *  
## Treatment_bisFull:RegionLuxembourg         0.013   0.9897    
## Treatment_bisSmart:RegionLuxembourg        0.576   0.5659    
## Treatment_bisMixt_smart:RegionLuxembourg   0.792   0.4298    
## TT_pupation:SexMale                        0.406   0.6852    
## TT_pupation:RegionLuxembourg              -2.332   0.0211 *  
## TT_pupation:Treatment_bisFull              0.607   0.5448    
## TT_pupation:Treatment_bisSmart             0.001   0.9992    
## TT_pupation:Treatment_bisMixt_smart       -0.252   0.8015    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 18 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Test des hypothèses

Normalité des réisuds

qqnorm(resid(LM_Pupa_mass_by_TT_pupation_AE))
qqline(resid(LM_Pupa_mass_by_TT_pupation_AE))

Homogénité des variances

plot(LM_Pupa_mass_by_TT_pupation_AE)

Distance de cook

plot(cooks.distance(LM_Pupa_mass_by_TT_pupation_AE))

1 gros outlier à retirer si possible

Data_Pupa_mass_AE <- (Data_AE %>% filter(Sex != "NA", Pupa_mass != "NA" ))[unname(cooks.distance(LM_Pupa_mass_by_TT_pupation_AE) != max(cooks.distance(LM_Pupa_mass_by_TT_pupation_AE))),]

Data_Pupa_mass_AE_ref_smart <- Data_Pupa_mass_AE
Data_Pupa_mass_AE_ref_smart$Treatment_bis <- relevel(Data_Pupa_mass_AE$Treatment_bis, ref = "Smart")

Data_Pupa_mass_AE_ref_full <- Data_Pupa_mass_AE
Data_Pupa_mass_AE_ref_full$Treatment_bis <- relevel(Data_Pupa_mass_AE$Treatment_bis, ref = "Full")

Data_Pupa_mass_AE_ref_mixt_smart <- Data_Pupa_mass_AE
Data_Pupa_mass_AE_ref_mixt_smart$Treatment_bis <- relevel(Data_Pupa_mass_AE$Treatment_bis, ref = "Mixt_smart")

Et on refait les tests

LM_Pupa_mass_by_TT_pupation_AE <- lmer(Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region + TT_pupation:Sex + TT_pupation:Region + TT_pupation:Treatment_bis, data = Data_Pupa_mass_AE)
## boundary (singular) fit: see help('isSingular')

Test des hypothèses

Normalité des réisuds

qqnorm(resid(LM_Pupa_mass_by_TT_pupation_AE))
qqline(resid(LM_Pupa_mass_by_TT_pupation_AE))

Homogénité des variances

plot(LM_Pupa_mass_by_TT_pupation_AE)

Distance de cook

plot(cooks.distance(LM_Pupa_mass_by_TT_pupation_AE))

6.20.2 Simplification du modèle

drop1(LM_Pupa_mass_by_TT_pupation_AE)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + TT_pupation:Sex + TT_pupation:Region + TT_pupation:Treatment_bis
##                              Sum Sq   Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Sex         0.0241345 0.0080448     3 135.07  3.3696 0.02049 *
## Treatment_bis:Region      0.0024038 0.0008013     3 131.10  0.3356 0.79961  
## TT_pupation:Sex           0.0022687 0.0022687     1 137.08  0.9502 0.33137  
## TT_pupation:Region        0.0050456 0.0050456     1 141.04  2.1133 0.14824  
## TT_pupation:Treatment_bis 0.0020554 0.0006851     3 137.55  0.2870 0.83475  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Pupa_mass_by_TT_pupation1_AE <- update(LM_Pupa_mass_by_TT_pupation_AE, . ~ . - TT_pupation:Treatment_bis)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Pupa_mass_by_TT_pupation1_AE)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + TT_pupation:Sex + TT_pupation:Region
##                         Sum Sq   Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Sex    0.0226113 0.0075371     3 137.94  3.2021 0.02533 *
## Treatment_bis:Region 0.0012372 0.0004124     3 132.89  0.1752 0.91302  
## TT_pupation:Sex      0.0035188 0.0035188     1 136.38  1.4949 0.22356  
## TT_pupation:Region   0.0088535 0.0088535     1 144.58  3.7613 0.05440 .
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Pupa_mass_by_TT_pupation2_AE <- update(LM_Pupa_mass_by_TT_pupation1_AE, . ~ . - Treatment_bis:Region)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Pupa_mass_by_TT_pupation2_AE)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + TT_pupation:Sex + TT_pupation:Region
##                       Sum Sq   Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Sex  0.0224964 0.0074988     3 141.24  3.2380 0.02412 *
## TT_pupation:Sex    0.0035112 0.0035112     1 140.12  1.5161 0.22027  
## TT_pupation:Region 0.0110907 0.0110907     1 147.84  4.7890 0.03021 *
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_Pupa_mass_by_TT_pupation3_AE <- update(LM_Pupa_mass_by_TT_pupation2_AE, . ~ . - TT_pupation:Sex)
## boundary (singular) fit: see help('isSingular')
drop1(LM_Pupa_mass_by_TT_pupation3_AE)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + TT_pupation:Region
##                       Sum Sq   Mean Sq NumDF  DenDF F value  Pr(>F)  
## Treatment_bis:Sex  0.0233515 0.0077838     3 142.66  3.3527 0.02079 *
## TT_pupation:Region 0.0092204 0.0092204     1 148.82  3.9714 0.04811 *
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Il n’y a plus d’interactions qui n’ont pas de P-val significative, nous décidons d’arrêter la simplification du modèle.

Est ce que cela a été utile

AIC(LM_Pupa_mass_by_TT_pupation3_AE)
## [1] -388.1635
AIC(LM_Pupa_mass_by_TT_pupation_AE)
## [1] -311.0651

Oui ca a été utile

LM_Pupa_mass_by_TT_pupation_AE <- LM_Pupa_mass_by_TT_pupation3_AE

6.20.3 Treatment VS Teatment_bis

AIC(lmer(Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + TT_pupation:Region, data = Data_Pupa_mass_AE))
## boundary (singular) fit: see help('isSingular')
## [1] -388.1635
AIC(lmer(Pupa_mass ~ TT_pupation + Treatment + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment:Sex + TT_pupation:Region, data = Data_Pupa_mass_AE))
## [1] -399.218
summary(lmer(Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + TT_pupation:Region, data = Data_Pupa_mass_AE))$coeff
## boundary (singular) fit: see help('isSingular')
##                                     Estimate   Std. Error        df    t value
## (Intercept)                      0.163661932 0.0248098577  85.55708  6.5966494
## TT_pupation                      0.003535437 0.0004737540 146.72755  7.4626003
## Treatment_bisFull                0.027442317 0.0132922627 136.98381  2.0645331
## Treatment_bisSmart               0.035806593 0.0146653899 141.18930  2.4415711
## Treatment_bisMixt_smart          0.073485892 0.0161464105 141.72522  4.5512215
## SexMale                          0.034197865 0.0145101790 142.99166  2.3568190
## RegionLuxembourg                 0.069387917 0.0355604711  97.16244  1.9512654
## Treatment_bisFull:SexMale       -0.016839485 0.0200227427 140.11365 -0.8410179
## Treatment_bisSmart:SexMale      -0.061332541 0.0240548772 146.31100 -2.5496925
## Treatment_bisMixt_smart:SexMale -0.060484288 0.0239643576 143.10470 -2.5239270
## TT_pupation:RegionLuxembourg    -0.001411724 0.0007083967 148.82178 -1.9928435
##                                     Pr(>|t|)
## (Intercept)                     3.326751e-09
## TT_pupation                     6.904534e-12
## Treatment_bisFull               4.085362e-02
## Treatment_bisSmart              1.586039e-02
## Treatment_bisMixt_smart         1.137354e-05
## SexMale                         1.978842e-02
## RegionLuxembourg                5.390552e-02
## Treatment_bisFull:SexMale       4.017709e-01
## Treatment_bisSmart:SexMale      1.181097e-02
## Treatment_bisMixt_smart:SexMale 1.269705e-02
## TT_pupation:RegionLuxembourg    4.810705e-02
summary(lmer(Pupa_mass ~ TT_pupation + Treatment + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment:Sex + TT_pupation:Region, data = Data_Pupa_mass_AE))$coeff
##                                  Estimate   Std. Error        df   t value
## (Intercept)                   0.169616792 0.0263330211  37.59508  6.441220
## TT_pupation                   0.003468364 0.0004772750 148.09297  7.267014
## TreatmentFull                 0.023456395 0.0134550218 138.45614  1.743319
## TreatmentSmart                0.050107876 0.0127178878 143.64853  3.939953
## SexMale                       0.031144138 0.0146053194 144.05932  2.132383
## RegionLuxembourg              0.048197842 0.0343320695  94.97878  1.403872
## TreatmentFull:SexMale        -0.011506877 0.0203328288 142.04022 -0.565926
## TreatmentSmart:SexMale       -0.055389346 0.0199827751 147.16011 -2.771855
## TT_pupation:RegionLuxembourg -0.000957090 0.0006850904 149.92855 -1.397027
##                                  Pr(>|t|)
## (Intercept)                  1.483418e-07
## TT_pupation                  1.953388e-11
## TreatmentFull                8.349774e-02
## TreatmentSmart               1.267428e-04
## SexMale                      3.467107e-02
## RegionLuxembourg             1.636182e-01
## TreatmentFull:SexMale        5.723371e-01
## TreatmentSmart:SexMale       6.294382e-03
## TT_pupation:RegionLuxembourg 1.644697e-01

Même si l’AIC trouve que c’est mieux de prendre treatment, comme Mixt smart a un effet significatif, je compte prendre Treatment_bis

6.20.4 Résultats

Analyse des pval

summary(lmer(Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + TT_pupation:Region, data = Data_Pupa_mass_AE))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + TT_pupation:Region
##    Data: Data_Pupa_mass_AE
## 
## REML criterion at convergence: -418.2
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.74936 -0.57066 -0.01126  0.52477  2.35322 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0002398 0.01549 
##  Site     (Intercept) 0.0003281 0.01811 
##  Room     (Intercept) 0.0000000 0.00000 
##  Residual             0.0023217 0.04818 
## Number of obs: 160, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                   Estimate Std. Error         df t value
## (Intercept)                      1.637e-01  2.481e-02  8.556e+01   6.597
## TT_pupation                      3.535e-03  4.738e-04  1.467e+02   7.463
## Treatment_bisFull                2.744e-02  1.329e-02  1.370e+02   2.065
## Treatment_bisSmart               3.581e-02  1.467e-02  1.412e+02   2.442
## Treatment_bisMixt_smart          7.349e-02  1.615e-02  1.417e+02   4.551
## SexMale                          3.420e-02  1.451e-02  1.430e+02   2.357
## RegionLuxembourg                 6.939e-02  3.556e-02  9.716e+01   1.951
## Treatment_bisFull:SexMale       -1.684e-02  2.002e-02  1.401e+02  -0.841
## Treatment_bisSmart:SexMale      -6.133e-02  2.405e-02  1.463e+02  -2.550
## Treatment_bisMixt_smart:SexMale -6.048e-02  2.396e-02  1.431e+02  -2.524
## TT_pupation:RegionLuxembourg    -1.412e-03  7.084e-04  1.488e+02  -1.993
##                                 Pr(>|t|)    
## (Intercept)                     3.33e-09 ***
## TT_pupation                     6.90e-12 ***
## Treatment_bisFull                 0.0409 *  
## Treatment_bisSmart                0.0159 *  
## Treatment_bisMixt_smart         1.14e-05 ***
## SexMale                           0.0198 *  
## RegionLuxembourg                  0.0539 .  
## Treatment_bisFull:SexMale         0.4018    
## Treatment_bisSmart:SexMale        0.0118 *  
## Treatment_bisMixt_smart:SexMale   0.0127 *  
## TT_pupation:RegionLuxembourg      0.0481 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TT_ppt Trtm_F Trtm_S Trt_M_ SexMal RgnLxm T_F:SM T_S:SM
## TT_pupation -0.836                                                        
## Trtmnt_bsFl -0.335  0.089                                                 
## Trtmnt_bsSm -0.300  0.084  0.449                                          
## Trtmnt_bsM_ -0.295  0.083  0.428  0.360                                   
## SexMale     -0.291  0.053  0.461  0.419  0.412                            
## ReginLxmbrg -0.617  0.556  0.073 -0.068  0.213  0.076                     
## Trtmnt_F:SM  0.219 -0.058 -0.672 -0.316 -0.278 -0.714  0.005              
## Trtmnt_S:SM  0.164 -0.007 -0.283 -0.620 -0.268 -0.609 -0.021  0.437       
## Trtmn_M_:SM  0.169 -0.025 -0.285 -0.248 -0.680 -0.618 -0.098  0.436  0.388
## TT_pptn:RgL  0.586 -0.669 -0.084  0.049 -0.232 -0.093 -0.905  0.005  0.017
##             T_M_:S
## TT_pupation       
## Trtmnt_bsFl       
## Trtmnt_bsSm       
## Trtmnt_bsM_       
## SexMale           
## ReginLxmbrg       
## Trtmnt_F:SM       
## Trtmnt_S:SM       
## Trtmn_M_:SM       
## TT_pptn:RgL  0.109
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + TT_pupation:Region, data = Data_Pupa_mass_AE_ref_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + TT_pupation:Region
##    Data: Data_Pupa_mass_AE_ref_smart
## 
## REML criterion at convergence: -418.2
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.74936 -0.57066 -0.01126  0.52477  2.35322 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0002398 0.01549 
##  Site     (Intercept) 0.0003281 0.01811 
##  Room     (Intercept) 0.0000000 0.00000 
##  Residual             0.0023217 0.04818 
## Number of obs: 160, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                   Estimate Std. Error         df t value
## (Intercept)                      1.995e-01  2.474e-02  9.190e+01   8.061
## TT_pupation                      3.535e-03  4.738e-04  1.467e+02   7.463
## Treatment_bisDark               -3.581e-02  1.467e-02  1.412e+02  -2.442
## Treatment_bisFull               -8.364e-03  1.473e-02  1.391e+02  -0.568
## Treatment_bisMixt_smart          3.768e-02  1.747e-02  1.377e+02   2.157
## SexMale                         -2.713e-02  1.907e-02  1.462e+02  -1.423
## RegionLuxembourg                 6.939e-02  3.556e-02  9.716e+01   1.951
## Treatment_bisDark:SexMale        6.133e-02  2.405e-02  1.463e+02   2.550
## Treatment_bisFull:SexMale        4.449e-02  2.363e-02  1.440e+02   1.883
## Treatment_bisMixt_smart:SexMale  8.483e-04  2.656e-02  1.424e+02   0.032
## TT_pupation:RegionLuxembourg    -1.412e-03  7.084e-04  1.488e+02  -1.993
##                                 Pr(>|t|)    
## (Intercept)                      2.7e-12 ***
## TT_pupation                      6.9e-12 ***
## Treatment_bisDark                 0.0159 *  
## Treatment_bisFull                 0.5709    
## Treatment_bisMixt_smart           0.0328 *  
## SexMale                           0.1570    
## RegionLuxembourg                  0.0539 .  
## Treatment_bisDark:SexMale         0.0118 *  
## Treatment_bisFull:SexMale         0.0618 .  
## Treatment_bisMixt_smart:SexMale   0.9746    
## TT_pupation:RegionLuxembourg      0.0481 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TT_ppt Trtm_D Trtm_F Trt_M_ SexMal RgnLxm T_D:SM T_F:SM
## TT_pupation -0.788                                                        
## Trtmnt_bsDr -0.292 -0.084                                                 
## Trtmnt_bsFl -0.354 -0.004  0.591                                          
## Trtmnt_bsM_ -0.321  0.006  0.507  0.521                                   
## SexMale     -0.288  0.031  0.463  0.456  0.366                            
## ReginLxmbrg -0.659  0.556  0.068  0.134  0.254  0.032                     
## Trtmnt_D:SM  0.203  0.007 -0.620 -0.362 -0.272 -0.798  0.021              
## Trtmnt_F:SM  0.233 -0.041 -0.363 -0.616 -0.270 -0.805  0.025  0.648       
## Trtmn_M_:SM  0.204 -0.015 -0.337 -0.337 -0.625 -0.705 -0.070  0.555  0.563
## TT_pptn:RgL  0.617 -0.669 -0.049 -0.125 -0.256 -0.049 -0.905 -0.017 -0.013
##             T_M_:S
## TT_pupation       
## Trtmnt_bsDr       
## Trtmnt_bsFl       
## Trtmnt_bsM_       
## SexMale           
## ReginLxmbrg       
## Trtmnt_D:SM       
## Trtmnt_F:SM       
## Trtmn_M_:SM       
## TT_pptn:RgL  0.083
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + TT_pupation:Region, data = Data_Pupa_mass_AE_ref_full))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + TT_pupation:Region
##    Data: Data_Pupa_mass_AE_ref_full
## 
## REML criterion at convergence: -418.2
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.74936 -0.57066 -0.01126  0.52477  2.35322 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0002398 0.01549 
##  Site     (Intercept) 0.0003281 0.01811 
##  Room     (Intercept) 0.0000000 0.00000 
##  Residual             0.0023217 0.04818 
## Number of obs: 160, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                   Estimate Std. Error         df t value
## (Intercept)                      1.911e-01  2.390e-02  7.990e+01   7.996
## TT_pupation                      3.535e-03  4.738e-04  1.467e+02   7.463
## Treatment_bisDark               -2.744e-02  1.329e-02  1.370e+02  -2.065
## Treatment_bisSmart               8.364e-03  1.473e-02  1.391e+02   0.568
## Treatment_bisMixt_smart          4.604e-02  1.593e-02  1.386e+02   2.890
## SexMale                          1.736e-02  1.401e-02  1.379e+02   1.239
## RegionLuxembourg                 6.939e-02  3.556e-02  9.716e+01   1.951
## Treatment_bisDark:SexMale        1.684e-02  2.002e-02  1.401e+02   0.841
## Treatment_bisSmart:SexMale      -4.449e-02  2.363e-02  1.440e+02  -1.883
## Treatment_bisMixt_smart:SexMale -4.364e-02  2.359e-02  1.393e+02  -1.850
## TT_pupation:RegionLuxembourg    -1.412e-03  7.084e-04  1.488e+02  -1.993
##                                 Pr(>|t|)    
## (Intercept)                     8.28e-12 ***
## TT_pupation                     6.90e-12 ***
## Treatment_bisDark                0.04085 *  
## Treatment_bisSmart               0.57093    
## Treatment_bisMixt_smart          0.00447 ** 
## SexMale                          0.21759    
## RegionLuxembourg                 0.05391 .  
## Treatment_bisDark:SexMale        0.40177    
## Treatment_bisSmart:SexMale       0.06176 .  
## Treatment_bisMixt_smart:SexMale  0.06643 .  
## TT_pupation:RegionLuxembourg     0.04811 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TT_ppt Trtm_D Trtm_S Trt_M_ SexMal RgnLxm T_D:SM T_S:SM
## TT_pupation -0.819                                                        
## Trtmnt_bsDr -0.208 -0.089                                                 
## Trtmnt_bsSm -0.250  0.004  0.456                                          
## Trtmnt_bsM_ -0.243  0.010  0.401  0.352                                   
## SexMale     -0.257 -0.027  0.483  0.418  0.434                            
## ReginLxmbrg -0.599  0.556 -0.073 -0.134  0.155  0.086                     
## Trtmnt_D:SM  0.147  0.058 -0.672 -0.292 -0.279 -0.689 -0.005              
## Trtmnt_S:SM  0.138  0.041 -0.282 -0.616 -0.274 -0.590 -0.025  0.402       
## Trtmn_M_:SM  0.142  0.024 -0.281 -0.237 -0.695 -0.602 -0.104  0.406  0.367
## TT_pptn:RgL  0.562 -0.669  0.084  0.125 -0.165 -0.089 -0.905 -0.005  0.013
##             T_M_:S
## TT_pupation       
## Trtmnt_bsDr       
## Trtmnt_bsSm       
## Trtmnt_bsM_       
## SexMale           
## ReginLxmbrg       
## Trtmnt_D:SM       
## Trtmnt_S:SM       
## Trtmn_M_:SM       
## TT_pptn:RgL  0.106
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + TT_pupation:Region, data = Data_Pupa_mass_AE_ref_mixt_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + TT_pupation:Region
##    Data: Data_Pupa_mass_AE_ref_mixt_smart
## 
## REML criterion at convergence: -418.2
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -2.74936 -0.57066 -0.01126  0.52477  2.35322 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0002398 0.01549 
##  Site     (Intercept) 0.0003281 0.01811 
##  Room     (Intercept) 0.0000000 0.00000 
##  Residual             0.0023217 0.04818 
## Number of obs: 160, groups:  Mother, 23; Site, 13; Room, 2
## 
## Fixed effects:
##                                Estimate Std. Error         df t value Pr(>|t|)
## (Intercept)                   2.371e-01  2.530e-02  9.773e+01   9.375 2.82e-15
## TT_pupation                   3.535e-03  4.738e-04  1.467e+02   7.463 6.90e-12
## Treatment_bisDark            -7.349e-02  1.615e-02  1.417e+02  -4.551 1.14e-05
## Treatment_bisFull            -4.604e-02  1.593e-02  1.386e+02  -2.890  0.00447
## Treatment_bisSmart           -3.768e-02  1.747e-02  1.377e+02  -2.157  0.03277
## SexMale                      -2.629e-02  1.884e-02  1.421e+02  -1.396  0.16503
## RegionLuxembourg              6.939e-02  3.556e-02  9.716e+01   1.951  0.05391
## Treatment_bisDark:SexMale     6.048e-02  2.396e-02  1.431e+02   2.524  0.01270
## Treatment_bisFull:SexMale     4.364e-02  2.359e-02  1.393e+02   1.850  0.06643
## Treatment_bisSmart:SexMale   -8.483e-04  2.656e-02  1.424e+02  -0.032  0.97457
## TT_pupation:RegionLuxembourg -1.412e-03  7.084e-04  1.488e+02  -1.993  0.04811
##                                 
## (Intercept)                  ***
## TT_pupation                  ***
## Treatment_bisDark            ***
## Treatment_bisFull            ** 
## Treatment_bisSmart           *  
## SexMale                         
## RegionLuxembourg             .  
## Treatment_bisDark:SexMale    *  
## Treatment_bisFull:SexMale    .  
## Treatment_bisSmart:SexMale      
## TT_pupation:RegionLuxembourg *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) TT_ppt Trtm_D Trtm_F Trtm_S SexMal RgnLxm T_D:SM T_F:SM
## TT_pupation -0.767                                                        
## Trtmnt_bsDr -0.349 -0.083                                                 
## Trtmnt_bsFl -0.400 -0.010  0.657                                          
## Trtmnt_bsSm -0.377 -0.006  0.622  0.615                                   
## SexMale     -0.357  0.010  0.547  0.548  0.511                            
## ReginLxmbrg -0.469  0.556 -0.213 -0.155 -0.254 -0.066                     
## Trtmnt_D:SM  0.268  0.025 -0.680 -0.451 -0.420 -0.796  0.098              
## Trtmnt_F:SM  0.304 -0.024 -0.455 -0.695 -0.434 -0.804  0.104  0.646       
## Trtmnt_S:SM  0.232  0.015 -0.370 -0.374 -0.625 -0.696  0.070  0.551  0.561
## TT_pptn:RgL  0.427 -0.669  0.232  0.165  0.256  0.067 -0.905 -0.109 -0.106
##             T_S:SM
## TT_pupation       
## Trtmnt_bsDr       
## Trtmnt_bsFl       
## Trtmnt_bsSm       
## SexMale           
## ReginLxmbrg       
## Trtmnt_D:SM       
## Trtmnt_F:SM       
## Trtmnt_S:SM       
## TT_pptn:RgL -0.083
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
test1 <- data.frame(Reference = "Dark", as.data.frame(( summary(lmer(Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + TT_pupation:Region, data = Data_Pupa_mass_AE))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test2 <- data.frame(Reference = "Smart", as.data.frame(( summary(lmer(Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + TT_pupation:Region, data = Data_Pupa_mass_AE_ref_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test3 <- data.frame(Reference = "Full", as.data.frame(( summary(lmer(Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + TT_pupation:Region, data = Data_Pupa_mass_AE_ref_full))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test4 <- data.frame(Reference = "Mixt_smart", as.data.frame(( summary(lmer(Pupa_mass ~ TT_pupation + Treatment_bis + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + TT_pupation:Region, data = Data_Pupa_mass_AE_ref_mixt_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
Results_Pupa_mass_by_TT_pupation_AE <- rbind(test1,test2,test3,test4)

colnames(Results_Pupa_mass_by_TT_pupation_AE ) <- c("Reference","Estimate", "Std. Error", "df", "t.value", "Pr(>|z|)")

write.csv2( Results_Pupa_mass_by_TT_pupation_AE , file = "output/Results_Pupa_mass_by_TT_pupation_AE.csv" )

kable(Results_Pupa_mass_by_TT_pupation_AE , caption = " Poids des chrysalides en fonction du temps pour rentrer en chrysalide AE", padding = 1 )
Poids des chrysalides en fonction du temps pour rentrer en chrysalide AE
Reference Estimate Std. Error df t.value Pr(>|z|)
(Intercept) Dark 0.1636619 0.0248099 85.55708 6.5966494 0.0000000
TT_pupation Dark 0.0035354 0.0004738 146.72755 7.4626003 0.0000000
Treatment_bisFull Dark 0.0274423 0.0132923 136.98381 2.0645331 0.0408536
Treatment_bisSmart Dark 0.0358066 0.0146654 141.18930 2.4415711 0.0158604
Treatment_bisMixt_smart Dark 0.0734859 0.0161464 141.72522 4.5512215 0.0000114
SexMale Dark 0.0341979 0.0145102 142.99166 2.3568190 0.0197884
RegionLuxembourg Dark 0.0693879 0.0355605 97.16244 1.9512654 0.0539055
Treatment_bisFull:SexMale Dark -0.0168395 0.0200227 140.11365 -0.8410179 0.4017709
Treatment_bisSmart:SexMale Dark -0.0613325 0.0240549 146.31100 -2.5496925 0.0118110
Treatment_bisMixt_smart:SexMale Dark -0.0604843 0.0239644 143.10470 -2.5239270 0.0126971
TT_pupation:RegionLuxembourg Dark -0.0014117 0.0007084 148.82178 -1.9928435 0.0481070
(Intercept)1 Smart 0.1994685 0.0247435 91.89547 8.0614386 0.0000000
TT_pupation1 Smart 0.0035354 0.0004738 146.72755 7.4626003 0.0000000
Treatment_bisDark Smart -0.0358066 0.0146654 141.18930 -2.4415711 0.0158604
Treatment_bisFull1 Smart -0.0083643 0.0147251 139.09801 -0.5680266 0.5709327
Treatment_bisMixt_smart1 Smart 0.0376793 0.0174712 137.65842 2.1566499 0.0327701
SexMale1 Smart -0.0271347 0.0190728 146.15536 -1.4226888 0.1569572
RegionLuxembourg1 Smart 0.0693879 0.0355605 97.16244 1.9512654 0.0539055
Treatment_bisDark:SexMale Smart 0.0613325 0.0240549 146.31100 2.5496925 0.0118110
Treatment_bisFull:SexMale1 Smart 0.0444931 0.0236328 144.04251 1.8826854 0.0617597
Treatment_bisMixt_smart:SexMale1 Smart 0.0008483 0.0265589 142.43076 0.0319386 0.9745658
TT_pupation:RegionLuxembourg1 Smart -0.0014117 0.0007084 148.82178 -1.9928435 0.0481070
(Intercept)2 Full 0.1911042 0.0238991 79.90131 7.9963051 0.0000000
TT_pupation2 Full 0.0035354 0.0004738 146.72755 7.4626003 0.0000000
Treatment_bisDark1 Full -0.0274423 0.0132923 136.98381 -2.0645331 0.0408536
Treatment_bisSmart1 Full 0.0083643 0.0147251 139.09801 0.5680266 0.5709327
Treatment_bisMixt_smart2 Full 0.0460436 0.0159308 138.61207 2.8902268 0.0044699
SexMale2 Full 0.0173584 0.0140144 137.87065 1.2386096 0.2175948
RegionLuxembourg2 Full 0.0693879 0.0355605 97.16243 1.9512654 0.0539055
Treatment_bisDark:SexMale1 Full 0.0168395 0.0200227 140.11365 0.8410179 0.4017709
Treatment_bisSmart:SexMale1 Full -0.0444931 0.0236328 144.04251 -1.8826854 0.0617597
Treatment_bisMixt_smart:SexMale2 Full -0.0436448 0.0235911 139.26385 -1.8500523 0.0664253
TT_pupation:RegionLuxembourg2 Full -0.0014117 0.0007084 148.82178 -1.9928435 0.0481070
(Intercept)3 Mixt_smart 0.2371478 0.0252965 97.73242 9.3747209 0.0000000
TT_pupation3 Mixt_smart 0.0035354 0.0004738 146.72755 7.4626003 0.0000000
Treatment_bisDark2 Mixt_smart -0.0734859 0.0161464 141.72522 -4.5512215 0.0000114
Treatment_bisFull2 Mixt_smart -0.0460436 0.0159308 138.61207 -2.8902268 0.0044699
Treatment_bisSmart2 Mixt_smart -0.0376793 0.0174712 137.65842 -2.1566499 0.0327701
SexMale3 Mixt_smart -0.0262864 0.0188360 142.12225 -1.3955433 0.1650287
RegionLuxembourg3 Mixt_smart 0.0693879 0.0355605 97.16244 1.9512654 0.0539055
Treatment_bisDark:SexMale2 Mixt_smart 0.0604843 0.0239644 143.10470 2.5239270 0.0126971
Treatment_bisFull:SexMale2 Mixt_smart 0.0436448 0.0235911 139.26385 1.8500523 0.0664253
Treatment_bisSmart:SexMale2 Mixt_smart -0.0008483 0.0265589 142.43076 -0.0319386 0.9745658
TT_pupation:RegionLuxembourg3 Mixt_smart -0.0014117 0.0007084 148.82178 -1.9928435 0.0481070
Info_Pupa_mass_by_TT_pupation_AE <- "
Au plus un individu met du temps pour entrer en chrysalide, au plus sa chrysalide sera lourde (p-val = 6.90e-12).
Les chrysalides des individus des traitements Full et Smart sont significatiment (p-val = 0.0409 et 0.0159 respectivement) plus lourdes (0.027 g et 0.036 g respectivement) que celles du traitement Dark.
Celles de Mixt-smart sont significativement (p-val = 1.14e-05 et 0.00447 et 0.0328 respectivement) plus lourdes (0.073 g, 0.046 g et 0.038 g respectivement) que celles des traitements Dark, Full et Smart.
Les chrysalides venant d'individus mâles dans le traitement Dark sont significativement (p-val = 0.0198) plus lourdes (0.034 g) que celles des femelles.
Les chrysalides des individus déscendant d'une mère provenant de la région luxembourgeoise sont quasiement significativement (p-val = 0.0539) plus lourdes (0.069 g) que celles du brabant mais les individus ont significativement (p-val = 0.0481) moins bien optimisé le temps avant l'entrée en chrysaldie pour augmenter la masse finale de la chrysalide (0.0014 g en moins par semaine passée).
"
Info_Pupa_mass_by_TT_pupation_AE
## [1] "\nAu plus un individu met du temps pour entrer en chrysalide, au plus sa chrysalide sera lourde (p-val = 6.90e-12).\nLes chrysalides des individus des traitements Full et Smart sont significatiment (p-val = 0.0409 et 0.0159 respectivement) plus lourdes (0.027 g et 0.036 g respectivement) que celles du traitement Dark.\nCelles de Mixt-smart sont significativement (p-val = 1.14e-05 et 0.00447 et 0.0328 respectivement) plus lourdes (0.073 g, 0.046 g et 0.038 g respectivement) que celles des traitements Dark, Full et Smart.\nLes chrysalides venant d'individus mâles dans le traitement Dark sont significativement (p-val = 0.0198) plus lourdes (0.034 g) que celles des femelles.\nLes chrysalides des individus déscendant d'une mère provenant de la région luxembourgeoise sont quasiement significativement (p-val = 0.0539) plus lourdes (0.069 g) que celles du brabant mais les individus ont significativement (p-val = 0.0481) moins bien optimisé le temps avant l'entrée en chrysaldie pour augmenter la masse finale de la chrysalide (0.0014 g en moins par semaine passée).\n"

6.21 Mass_by_Time OP

Dévelloppement du jeux de données

Data_mass <- Data[,1:31] %>% pivot_longer(cols = M0:M20, names_to = "Numéro_de_masse", values_to = "Mass")
Data_mass$Time <- rep(0:20, length.out = nrow(Data_mass))
Data_mass_OP <- Data_mass %>% filter(Species == "OP")
Data_mass_AE <- Data_mass %>% filter(Species == "AE")
Data_mass_OP_ref_smart <- Data_mass_OP
Data_mass_OP_ref_smart$Treatment <- relevel(Data_mass_OP$Treatment, ref = "Smart")
Data_mass_OP_ref_smart$Treatment_bis <- relevel(Data_mass_OP$Treatment_bis, ref = "Smart")

Data_mass_OP_ref_full <- Data_mass_OP
Data_mass_OP_ref_full$Treatment <- relevel(Data_mass_OP$Treatment, ref = "Full")
Data_mass_OP_ref_full$Treatment_bis <- relevel(Data_mass_OP$Treatment_bis, ref = "Full")

Data_mass_AE_ref_smart <- Data_mass_AE
Data_mass_AE_ref_smart$Treatment <- relevel(Data_mass_AE$Treatment, ref = "Smart")
Data_mass_AE_ref_smart$Treatment_bis <- relevel(Data_mass_AE$Treatment_bis, ref = "Smart")

Data_mass_AE_ref_full <- Data_mass_AE
Data_mass_AE_ref_full$Treatment <- relevel(Data_mass_AE$Treatment, ref = "Full")
Data_mass_AE_ref_full$Treatment_bis <- relevel(Data_mass_AE$Treatment_bis, ref = "Full")

Data_mass_AE_ref_mixt_smart <- Data_mass_AE
Data_mass_AE_ref_mixt_smart$Treatment_bis <- relevel(Data_mass_AE$Treatment_bis, ref = "Mixt_smart")

6.21.1 Test

LM_mass_by_time_OP <- lmer(Mass ~ Time + Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region + Time:Sex + Time:Region + Time:Treatment_bis, data = Data_mass_OP)
## boundary (singular) fit: see help('isSingular')
summary(LM_mass_by_time_OP)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Mass ~ Time + Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region +  
##     Time:Sex + Time:Region + Time:Treatment_bis
##    Data: Data_mass_OP
## 
## REML criterion at convergence: -697.8
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.2967 -0.5231 -0.1635  0.4271  3.2827 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 5.959e-04 0.024411
##  Site     (Intercept) 0.000e+00 0.000000
##  Room     (Intercept) 7.933e-05 0.008907
##  Residual             5.622e-03 0.074983
## Number of obs: 340, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                                       Estimate Std. Error         df t value
## (Intercept)                           0.057193   0.017070  13.323503   3.351
## Time                                  0.134394   0.010227 318.674967  13.141
## Treatment_bisFull                    -0.009552   0.018769 321.112729  -0.509
## Treatment_bisSmart                   -0.028187   0.026872 300.016428  -1.049
## SexMale                              -0.014241   0.014671 318.731994  -0.971
## RegionLuxembourg                     -0.003663   0.020565  18.437854  -0.178
## Treatment_bisFull:SexMale             0.029530   0.018609 323.259347   1.587
## Treatment_bisSmart:SexMale            0.037074   0.026209 325.188218   1.415
## Treatment_bisFull:RegionLuxembourg    0.001946   0.018165 318.269645   0.107
## Treatment_bisSmart:RegionLuxembourg   0.013948   0.026286 324.513027   0.531
## Time:SexMale                         -0.001798   0.011257 316.082921  -0.160
## Time:RegionLuxembourg                -0.009891   0.011245 318.772953  -0.880
## Time:Treatment_bisFull                0.003894   0.012472 315.991611   0.312
## Time:Treatment_bisSmart              -0.019730   0.016540 314.725178  -1.193
##                                     Pr(>|t|)    
## (Intercept)                          0.00506 ** 
## Time                                 < 2e-16 ***
## Treatment_bisFull                    0.61115    
## Treatment_bisSmart                   0.29505    
## SexMale                              0.33246    
## RegionLuxembourg                     0.86056    
## Treatment_bisFull:SexMale            0.11352    
## Treatment_bisSmart:SexMale           0.15816    
## Treatment_bisFull:RegionLuxembourg   0.91475    
## Treatment_bisSmart:RegionLuxembourg  0.59604    
## Time:SexMale                         0.87317    
## Time:RegionLuxembourg                0.37974    
## Time:Treatment_bisFull               0.75507    
## Time:Treatment_bisSmart              0.23384    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 14 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Vérification des hypothèses

qqnorm(resid(LM_mass_by_time_OP))
qqline(resid(LM_mass_by_time_OP))

Il faudrait modifier les données

LM_mass_by_time_OP <- lmer(sqrt(Mass) ~ Time + Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region + Time:Sex + Time:Region + Time:Treatment_bis, data = Data_mass_OP)
## boundary (singular) fit: see help('isSingular')
qqnorm(resid(LM_mass_by_time_OP))
qqline(resid(LM_mass_by_time_OP))

Homogénité des variances

plot(LM_mass_by_time_OP)

Distance de cook

plot(cooks.distance(LM_mass_by_time_OP))

6.21.2 Simplification du modèle

drop1(LM_mass_by_time_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## sqrt(Mass) ~ Time + Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + Time:Sex + Time:Region + Time:Treatment_bis
##                         Sum Sq   Mean Sq NumDF  DenDF F value Pr(>F)
## Treatment_bis:Sex    0.0239834 0.0119917     2 322.99  1.4888 0.2272
## Treatment_bis:Region 0.0023772 0.0011886     2 320.14  0.1476 0.8629
## Time:Sex             0.0000081 0.0000081     1 315.05  0.0010 0.9747
## Time:Region          0.0034646 0.0034646     1 317.28  0.4301 0.5124
## Time:Treatment_bis   0.0083163 0.0041581     2 314.57  0.5162 0.5973
LM_mass_by_time1_OP <- update(LM_mass_by_time_OP, . ~ . - Time:Sex)
## boundary (singular) fit: see help('isSingular')
drop1(LM_mass_by_time1_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## sqrt(Mass) ~ Time + Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + Time:Region + Time:Treatment_bis
##                         Sum Sq   Mean Sq NumDF  DenDF F value Pr(>F)
## Treatment_bis:Sex    0.0239586 0.0119793     2 324.01  1.4920 0.2265
## Treatment_bis:Region 0.0023854 0.0011927     2 321.13  0.1485 0.8620
## Time:Region          0.0034846 0.0034846     1 318.25  0.4340 0.5105
## Time:Treatment_bis   0.0083517 0.0041759     2 315.53  0.5201 0.5950
LM_mass_by_time2_OP <- update(LM_mass_by_time1_OP, . ~ . - Treatment_bis:Region)
## boundary (singular) fit: see help('isSingular')
drop1(LM_mass_by_time2_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## sqrt(Mass) ~ Time + Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Time:Region + Time:Treatment_bis
##                       Sum Sq   Mean Sq NumDF  DenDF F value Pr(>F)
## Treatment_bis:Sex  0.0261048 0.0130524     2 325.75  1.6342 0.1967
## Time:Region        0.0033492 0.0033492     1 320.40  0.4193 0.5177
## Time:Treatment_bis 0.0083862 0.0041931     2 317.49  0.5250 0.5921
LM_mass_by_time3_OP <- update(LM_mass_by_time2_OP, . ~ . - Time:Treatment_bis)
## boundary (singular) fit: see help('isSingular')
drop1(LM_mass_by_time3_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## sqrt(Mass) ~ Time + Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Time:Region
##                      Sum Sq   Mean Sq NumDF DenDF F value Pr(>F)
## Treatment_bis:Sex 0.0265620 0.0132810     2 327.8  1.6677 0.1903
## Time:Region       0.0038125 0.0038125     1 322.6  0.4787 0.4895
LM_mass_by_time4_OP <- update(LM_mass_by_time3_OP, . ~ . - Time:Region)
## boundary (singular) fit: see help('isSingular')
drop1(LM_mass_by_time4_OP)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## sqrt(Mass) ~ Time + Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex
##                   Sum Sq Mean Sq NumDF  DenDF  F value Pr(>F)    
## Time              6.1829  6.1829     1 322.80 777.6929 <2e-16 ***
## Region            0.0026  0.0026     1   8.29   0.3265 0.5829    
## Treatment_bis:Sex 0.0257  0.0128     2 328.82   1.6132 0.2008    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Plus aucune interaction ne peut être retirée, on arrête la simplification ici.

A-t-elle été utile ?

AIC(LM_mass_by_time4_OP)
## [1] -588.0614
AIC(LM_mass_by_time_OP)
## [1] -540.6358

Oui

LM_mass_by_time_OP <- LM_mass_by_time4_OP

6.21.3 Treatment VS Teatment_bis

AIC(lmer(sqrt(Mass) ~ Time + Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Sex, data = Data_mass_OP))
## boundary (singular) fit: see help('isSingular')
## [1] -588.0614
AIC(lmer(sqrt(Mass) ~ Time + Treatment + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment:Sex, data = Data_mass_OP))
## boundary (singular) fit: see help('isSingular')
## [1] -586.3493
summary(lmer(sqrt(Mass) ~ Time + Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Sex, data = Data_mass_OP))$coeff
## boundary (singular) fit: see help('isSingular')
##                                Estimate  Std. Error        df    t value
## (Intercept)                 0.220724276 0.020750234  10.67268 10.6371943
## Time                        0.184932177 0.006631449 322.79757 27.8871449
## Treatment_bisFull          -0.004852993 0.015235595 318.10720 -0.3185299
## Treatment_bisSmart         -0.044586795 0.022074852 202.78652 -2.0198004
## SexMale                    -0.013763824 0.013787010 322.49172 -0.9983182
## RegionLuxembourg           -0.014130903 0.024730564   8.29156 -0.5713943
## Treatment_bisFull:SexMale   0.030282903 0.022100770 326.19562  1.3702193
## Treatment_bisSmart:SexMale  0.047042537 0.030940365 330.56177  1.5204260
##                                Pr(>|t|)
## (Intercept)                5.168431e-07
## Time                       5.648613e-88
## Treatment_bisFull          7.502920e-01
## Treatment_bisSmart         4.471995e-02
## SexMale                    3.188736e-01
## RegionLuxembourg           5.828857e-01
## Treatment_bisFull:SexMale  1.715607e-01
## Treatment_bisSmart:SexMale 1.293598e-01
summary(lmer(sqrt(Mass) ~ Time + Treatment + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment:Sex, data = Data_mass_OP))$coeff
## boundary (singular) fit: see help('isSingular')
##                           Estimate  Std. Error         df    t value
## (Intercept)             0.22659730 0.021554322  15.986170 10.5128476
## Time                    0.18491748 0.006639799 323.829950 27.8498622
## TreatmentFull          -0.01024599 0.016940827 326.795431 -0.6048106
## TreatmentSmart         -0.02683642 0.015908217 325.105880 -1.6869536
## SexMale                -0.01501092 0.016925973 324.243868 -0.8868572
## RegionLuxembourg       -0.01513882 0.026020536   8.577493 -0.5818028
## TreatmentFull:SexMale   0.03071164 0.024323967 327.849850  1.2626082
## TreatmentSmart:SexMale  0.02110689 0.024611818 324.645621  0.8575917
##                            Pr(>|t|)
## (Intercept)            1.375492e-08
## Time                   5.862102e-88
## TreatmentFull          5.457246e-01
## TreatmentSmart         9.257148e-02
## SexMale                3.758131e-01
## RegionLuxembourg       5.756683e-01
## TreatmentFull:SexMale  2.076273e-01
## TreatmentSmart:SexMale 3.917506e-01

Si je me base sur les AIC je continue avec treatment_bis

6.21.4 Résultats

Analyse des P-val

summary(lmer(sqrt(Mass) ~ Time + Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Sex, data = Data_mass_OP))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: sqrt(Mass) ~ Time + Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment_bis:Sex
##    Data: Data_mass_OP
## 
## REML criterion at convergence: -612.1
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.4446 -0.6284 -0.1251  0.6382  2.5225 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 1.470e-03 0.038347
##  Site     (Intercept) 0.000e+00 0.000000
##  Room     (Intercept) 9.135e-05 0.009558
##  Residual             7.950e-03 0.089165
## Number of obs: 340, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                              Estimate Std. Error         df t value Pr(>|t|)
## (Intercept)                  0.220724   0.020750  10.672683  10.637 5.17e-07
## Time                         0.184932   0.006631 322.797568  27.887  < 2e-16
## Treatment_bisFull           -0.004853   0.015236 318.107205  -0.319   0.7503
## Treatment_bisSmart          -0.044587   0.022075 202.786518  -2.020   0.0447
## SexMale                     -0.013764   0.013787 322.491722  -0.998   0.3189
## RegionLuxembourg            -0.014131   0.024731   8.291560  -0.571   0.5829
## Treatment_bisFull:SexMale    0.030283   0.022101 326.195624   1.370   0.1716
## Treatment_bisSmart:SexMale   0.047043   0.030940 330.561768   1.520   0.1294
##                               
## (Intercept)                ***
## Time                       ***
## Treatment_bisFull             
## Treatment_bisSmart         *  
## SexMale                       
## RegionLuxembourg              
## Treatment_bisFull:SexMale     
## Treatment_bisSmart:SexMale    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Time   Trtm_F Trtm_S SexMal RgnLxm T_F:SM
## Time        -0.245                                          
## Trtmnt_bsFl -0.247 -0.002                                   
## Trtmnt_bsSm -0.166 -0.017  0.284                            
## SexMale     -0.260  0.003  0.368  0.290                     
## ReginLxmbrg -0.591 -0.005 -0.030 -0.057 -0.012              
## Trtmnt_F:SM  0.166  0.030 -0.697 -0.215 -0.630  0.023       
## Trtmnt_S:SM  0.118  0.008 -0.170 -0.679 -0.463  0.018  0.301
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(sqrt(Mass) ~ Time + Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Sex, data = Data_mass_OP_ref_full))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: sqrt(Mass) ~ Time + Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment_bis:Sex
##    Data: Data_mass_OP_ref_full
## 
## REML criterion at convergence: -612.1
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.4446 -0.6284 -0.1251  0.6382  2.5225 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 1.470e-03 0.038347
##  Site     (Intercept) 0.000e+00 0.000000
##  Room     (Intercept) 9.135e-05 0.009558
##  Residual             7.950e-03 0.089165
## Number of obs: 340, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                              Estimate Std. Error         df t value Pr(>|t|)
## (Intercept)                  0.215871   0.022501  14.965224   9.594 8.77e-08
## Time                         0.184932   0.006631 322.797581  27.887  < 2e-16
## Treatment_bisDark            0.004853   0.015236 318.107213   0.319   0.7503
## Treatment_bisSmart          -0.039734   0.022988 306.923596  -1.728   0.0849
## SexMale                      0.016519   0.017162 328.492168   0.963   0.3365
## RegionLuxembourg            -0.014131   0.024731   8.291531  -0.571   0.5829
## Treatment_bisDark:SexMale   -0.030283   0.022101 326.195630  -1.370   0.1716
## Treatment_bisSmart:SexMale   0.016760   0.032149 328.800638   0.521   0.6025
##                               
## (Intercept)                ***
## Time                       ***
## Treatment_bisDark             
## Treatment_bisSmart         .  
## SexMale                       
## RegionLuxembourg              
## Treatment_bisDark:SexMale     
## Treatment_bisSmart:SexMale    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Time   Trtm_D Trtm_S SexMal RgnLxm T_D:SM
## Time        -0.227                                          
## Trtmnt_bsDr -0.449  0.002                                   
## Trtmnt_bsSm -0.260 -0.016  0.390                            
## SexMale     -0.404  0.040  0.602  0.357                     
## ReginLxmbrg -0.566 -0.005  0.030 -0.034  0.021              
## Trtmnt_D:SM  0.319 -0.030 -0.697 -0.256 -0.782 -0.023       
## Trtmnt_S:SM  0.214 -0.013 -0.316 -0.695 -0.522  0.001  0.397
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
summary(lmer(sqrt(Mass) ~ Time + Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Sex, data = Data_mass_OP_ref_smart))
## boundary (singular) fit: see help('isSingular')
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: sqrt(Mass) ~ Time + Treatment_bis + Sex + Region + (1 | Mother) +  
##     (1 | Site) + (1 | Room) + Treatment_bis:Sex
##    Data: Data_mass_OP_ref_smart
## 
## REML criterion at convergence: -612.1
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -2.4446 -0.6284 -0.1251  0.6382  2.5225 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 1.470e-03 0.038347
##  Site     (Intercept) 0.000e+00 0.000000
##  Room     (Intercept) 9.135e-05 0.009558
##  Residual             7.950e-03 0.089165
## Number of obs: 340, groups:  Mother, 12; Site, 8; Room, 2
## 
## Fixed effects:
##                             Estimate Std. Error         df t value Pr(>|t|)    
## (Intercept)                 0.176137   0.027675  28.422980   6.364 6.45e-07 ***
## Time                        0.184932   0.006631 322.797573  27.887  < 2e-16 ***
## Treatment_bisDark           0.044587   0.022075 202.786524   2.020   0.0447 *  
## Treatment_bisFull           0.039734   0.022988 306.923592   1.728   0.0849 .  
## SexMale                     0.033279   0.027433 330.000961   1.213   0.2260    
## RegionLuxembourg           -0.014131   0.024731   8.291547  -0.571   0.5829    
## Treatment_bisDark:SexMale  -0.047043   0.030940 330.561768  -1.520   0.1294    
## Treatment_bisFull:SexMale  -0.016760   0.032149 328.800636  -0.521   0.6025    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation of Fixed Effects:
##             (Intr) Time   Trtm_D Trtm_F SexMal RgnLxm T_D:SM
## Time        -0.198                                          
## Trtmnt_bsDr -0.673  0.017                                   
## Trtmnt_bsFl -0.619  0.016  0.772                            
## SexMale     -0.492  0.010  0.620  0.591                     
## ReginLxmbrg -0.489 -0.005  0.057  0.034  0.014              
## Trtmnt_D:SM  0.453 -0.008 -0.679 -0.539 -0.895 -0.018       
## Trtmnt_F:SM  0.403  0.013 -0.506 -0.695 -0.846 -0.001  0.755
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')
test1 <- data.frame(Reference = "Dark", as.data.frame(( summary(lmer(sqrt(Mass) ~ Time + Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Sex, data = Data_mass_OP))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test2 <- data.frame(Reference = "Smart", as.data.frame(( summary(lmer(sqrt(Mass) ~ Time + Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Sex, data = Data_mass_OP_ref_full))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
test3 <- data.frame(Reference = "Full", as.data.frame(( summary(lmer(sqrt(Mass) ~ Time + Treatment_bis + Sex + Region + (1 | Mother) +  (1 | Site) + (1 | Room) + Treatment_bis:Sex, data = Data_mass_OP_ref_smart))$coeff)[,]))
## boundary (singular) fit: see help('isSingular')
Results_Mass_by_time_OP <- rbind(test1,test2,test3)

colnames(Results_Mass_by_time_OP ) <- c("Reference","Estimate", "Std. Error", "df", "t.value", "Pr(>|z|)")

write.csv2( Results_Mass_by_time_OP , file = "output/Results_Mass_by_time_OP.csv" )

kable(Results_Mass_by_time_OP , caption = " Poids en fonction du temps OP ", padding = 1 )
Poids en fonction du temps OP
Reference Estimate Std. Error df t.value Pr(>|z|)
(Intercept) Dark 0.2207243 0.0207502 10.672683 10.6371943 0.0000005
Time Dark 0.1849322 0.0066314 322.797568 27.8871449 0.0000000
Treatment_bisFull Dark -0.0048530 0.0152356 318.107205 -0.3185299 0.7502920
Treatment_bisSmart Dark -0.0445868 0.0220749 202.786518 -2.0198004 0.0447199
SexMale Dark -0.0137638 0.0137870 322.491722 -0.9983182 0.3188736
RegionLuxembourg Dark -0.0141309 0.0247306 8.291559 -0.5713943 0.5828857
Treatment_bisFull:SexMale Dark 0.0302829 0.0221008 326.195624 1.3702193 0.1715607
Treatment_bisSmart:SexMale Dark 0.0470425 0.0309404 330.561769 1.5204260 0.1293598
(Intercept)1 Smart 0.2158713 0.0225005 14.965224 9.5940617 0.0000001
Time1 Smart 0.1849322 0.0066314 322.797581 27.8871466 0.0000000
Treatment_bisDark Smart 0.0048530 0.0152356 318.107213 0.3185302 0.7502918
Treatment_bisSmart1 Smart -0.0397338 0.0229875 306.923596 -1.7284922 0.0849057
SexMale1 Smart 0.0165191 0.0171621 328.492168 0.9625306 0.3364912
RegionLuxembourg1 Smart -0.0141309 0.0247306 8.291531 -0.5713942 0.5828858
Treatment_bisDark:SexMale Smart -0.0302829 0.0221008 326.195630 -1.3702194 0.1715607
Treatment_bisSmart:SexMale1 Smart 0.0167596 0.0321488 328.800638 0.5213135 0.6024993
(Intercept)2 Full 0.1761375 0.0276751 28.422980 6.3644741 0.0000006
Time2 Full 0.1849322 0.0066314 322.797573 27.8871457 0.0000000
Treatment_bisDark1 Full 0.0445868 0.0220749 202.786524 2.0198000 0.0447200
Treatment_bisFull1 Full 0.0397338 0.0229875 306.923592 1.7284928 0.0849056
SexMale2 Full 0.0332787 0.0274326 330.000961 1.2131097 0.2259555
RegionLuxembourg2 Full -0.0141309 0.0247306 8.291547 -0.5713942 0.5828858
Treatment_bisDark:SexMale1 Full -0.0470425 0.0309404 330.561769 -1.5204256 0.1293599
Treatment_bisFull:SexMale1 Full -0.0167596 0.0321488 328.800636 -0.5213140 0.6024990
Info_Mass_by_Time_OP <- "
Augmentation de la masse avec le temps.
Smart est plus léger que Dark.
Full est presque plus lourd que smart (p val 0.0849)
"
Info_Mass_by_Time_OP
## [1] "\nAugmentation de la masse avec le temps.\nSmart est plus léger que Dark.\nFull est presque plus lourd que smart (p val 0.0849)\n"

6.22 Mass_by_Time AE

6.22.1 Test

LM_mass_by_time_AE <- lmer(Mass ~ Time + Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region + Time:Sex + Time:Region + Time:Treatment_bis, data = Data_mass_AE)
## boundary (singular) fit: see help('isSingular')
summary(LM_mass_by_time_AE)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: Mass ~ Time + Treatment_bis + Sex + Region + (1 | Mother) + (1 |  
##     Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region +  
##     Time:Sex + Time:Region + Time:Treatment_bis
##    Data: Data_mass_AE
## 
## REML criterion at convergence: -1326.6
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -3.7359 -0.5761 -0.1620  0.3832  4.1216 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 1.367e-03 0.036972
##  Site     (Intercept) 8.966e-05 0.009469
##  Room     (Intercept) 0.000e+00 0.000000
##  Residual             2.207e-02 0.148548
## Number of obs: 1523, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                               2.257e-02  1.919e-02  2.933e+01
## Time                                      5.465e-02  2.313e-03  1.503e+03
## Treatment_bisFull                        -1.368e-02  1.972e-02  1.500e+03
## Treatment_bisSmart                       -8.441e-02  2.489e-02  1.505e+03
## Treatment_bisMixt_smart                  -2.763e-02  2.363e-02  1.498e+03
## SexMale                                  -2.054e-02  1.823e-02  1.491e+03
## RegionLuxembourg                         -6.609e-03  2.434e-02  2.232e+01
## Treatment_bisFull:SexMale                -1.356e-02  2.001e-02  1.480e+03
## Treatment_bisSmart:SexMale               -2.137e-02  2.585e-02  1.388e+03
## Treatment_bisMixt_smart:SexMale           4.613e-03  2.407e-02  1.426e+03
## Treatment_bisFull:RegionLuxembourg       -3.866e-02  2.006e-02  1.467e+03
## Treatment_bisSmart:RegionLuxembourg       8.279e-02  2.382e-02  1.504e+03
## Treatment_bisMixt_smart:RegionLuxembourg -4.795e-02  2.363e-02  1.455e+03
## Time:SexMale                              4.988e-03  2.363e-03  1.493e+03
## Time:RegionLuxembourg                    -6.482e-03  2.434e-03  1.503e+03
## Time:Treatment_bisFull                    1.277e-02  2.812e-03  1.498e+03
## Time:Treatment_bisSmart                   2.871e-02  4.034e-03  1.494e+03
## Time:Treatment_bisMixt_smart              1.752e-02  3.398e-03  1.493e+03
##                                          t value Pr(>|t|)    
## (Intercept)                                1.176 0.249038    
## Time                                      23.625  < 2e-16 ***
## Treatment_bisFull                         -0.694 0.487870    
## Treatment_bisSmart                        -3.392 0.000712 ***
## Treatment_bisMixt_smart                   -1.169 0.242428    
## SexMale                                   -1.127 0.259979    
## RegionLuxembourg                          -0.272 0.788446    
## Treatment_bisFull:SexMale                 -0.678 0.498003    
## Treatment_bisSmart:SexMale                -0.826 0.408704    
## Treatment_bisMixt_smart:SexMale            0.192 0.848071    
## Treatment_bisFull:RegionLuxembourg        -1.927 0.054117 .  
## Treatment_bisSmart:RegionLuxembourg        3.476 0.000523 ***
## Treatment_bisMixt_smart:RegionLuxembourg  -2.029 0.042605 *  
## Time:SexMale                               2.110 0.034987 *  
## Time:RegionLuxembourg                     -2.663 0.007824 ** 
## Time:Treatment_bisFull                     4.539 6.10e-06 ***
## Time:Treatment_bisSmart                    7.117 1.70e-12 ***
## Time:Treatment_bisMixt_smart               5.156 2.85e-07 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 18 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
## optimizer (nloptwrap) convergence code: 0 (OK)
## boundary (singular) fit: see help('isSingular')

Vérification des hypothèses

qqnorm(resid(LM_mass_by_time_AE))
qqline(resid(LM_mass_by_time_AE))

Il faudrait modifier les données

LM_mass_by_time_AE <- lmer(log(Mass) ~ log(Time + 1) + Treatment_bis + Sex + Region + (1|Mother) + (1|Site) + (1|Room) + Treatment_bis:Sex + Treatment_bis:Region + Time:Sex + Time:Region + Time:Treatment_bis, data = Data_mass_AE)
qqnorm(resid(LM_mass_by_time_AE))
qqline(resid(LM_mass_by_time_AE))

Homogénité des variances

plot(LM_mass_by_time_AE)

Distance de cook

plot(cooks.distance(LM_mass_by_time_AE))

6.22.2 Simplification du modèle

drop1(LM_mass_by_time_AE)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Mass) ~ log(Time + 1) + Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + Time:Sex + Time:Region + Time:Treatment_bis
##                      Sum Sq Mean Sq NumDF  DenDF   F value    Pr(>F)    
## log(Time + 1)        393.47  393.47     1 1486.0 1543.0572 < 2.2e-16 ***
## Treatment_bis:Sex      1.66    0.55     3 1202.4    2.1682   0.09007 .  
## Treatment_bis:Region  14.23    4.74     3 1496.5   18.6006 7.558e-12 ***
## Sex:Time               6.70    3.35     2 1491.2   13.1445 2.193e-06 ***
## Region:Time            0.02    0.02     1 1495.9    0.0944   0.75876    
## Treatment_bis:Time     9.33    3.11     3 1488.3   12.1935 6.960e-08 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_mass_by_time1_AE <- update(LM_mass_by_time_AE, . ~ . - Region:Time)
drop1(LM_mass_by_time1_AE)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Mass) ~ log(Time + 1) + Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Sex + Treatment_bis:Region + Sex:Time + Treatment_bis:Time
##                      Sum Sq Mean Sq NumDF  DenDF   F value    Pr(>F)    
## log(Time + 1)        398.38  398.38     1 1486.8 1563.2356 < 2.2e-16 ***
## Treatment_bis:Sex      1.64    0.55     3 1197.4    2.1469   0.09263 .  
## Treatment_bis:Region  14.24    4.75     3 1496.9   18.6227 7.323e-12 ***
## Sex:Time               7.39    3.70     2 1492.1   14.4993 5.800e-07 ***
## Treatment_bis:Time     9.47    3.16     3 1489.4   12.3925 5.240e-08 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
LM_mass_by_time2_AE <- update(LM_mass_by_time1_AE, . ~ . - Treatment_bis:Sex)
drop1(LM_mass_by_time2_AE)
## Single term deletions using Satterthwaite's method:
## 
## Model:
## log(Mass) ~ log(Time + 1) + Treatment_bis + Sex + Region + (1 | Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region + Sex:Time + Treatment_bis:Time
##                      Sum Sq Mean Sq NumDF  DenDF  F value    Pr(>F)    
## log(Time + 1)        399.05  399.05     1 1490.1 1561.105 < 2.2e-16 ***
## Treatment_bis:Region  13.80    4.60     3 1498.1   18.000 1.773e-11 ***
## Sex:Time               7.61    3.80     2 1495.7   14.882 3.982e-07 ***
## Treatment_bis:Time     9.43    3.14     3 1492.7   12.295 6.021e-08 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

Plus aucune interaction ne peut être retirée, on arrête la simplification ici.

A-t-elle été utile ?

AIC(LM_mass_by_time2_AE)
## [1] 2401.794
AIC(LM_mass_by_time_AE)
## [1] 2421.181

Oui

LM_mass_by_time_AE <- LM_mass_by_time2_AE

6.22.3 Treatment VS Teatment_bis

AIC(lmer(log(Mass) ~ log(Time + 1) + Treatment_bis + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Sex:Time + Treatment_bis:Time, data = Data_mass_AE))
## [1] 2401.794
AIC(lmer(log(Mass) ~ log(Time + 1) + Treatment + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment:Region +  Sex:Time + Treatment:Time, data = Data_mass_AE))
## boundary (singular) fit: see help('isSingular')
## [1] 2446.118
summary(lmer(log(Mass) ~ log(Time + 1) + Treatment_bis + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Sex:Time + Treatment_bis:Time, data = Data_mass_AE))$coeff
##                                             Estimate  Std. Error         df
## (Intercept)                              -4.44361062 0.089768114   21.49434
## log(Time + 1)                             1.91333827 0.048425669 1490.12099
## Treatment_bisFull                        -0.08259230 0.060264609 1500.63377
## Treatment_bisSmart                       -0.30684313 0.080215588 1023.06236
## Treatment_bisMixt_smart                  -0.03446372 0.073320391  613.46518
## SexMale                                  -0.06647218 0.045287925 1501.49311
## RegionLuxembourg                         -0.23506408 0.106400734   13.97362
## Treatment_bisFull:RegionLuxembourg       -0.07319669 0.068774496 1502.57903
## Treatment_bisSmart:RegionLuxembourg       0.44695597 0.080586138 1503.01309
## Treatment_bisMixt_smart:RegionLuxembourg -0.15058163 0.080883405 1502.89824
## SexFemale:Time                           -0.06326390 0.011596056 1497.79215
## SexMale:Time                             -0.05270663 0.012351026 1499.65244
## Treatment_bisFull:Time                    0.03069469 0.009462657 1495.29475
## Treatment_bisSmart:Time                   0.08002726 0.013980137 1492.62092
## Treatment_bisMixt_smart:Time              0.03637843 0.011410995 1492.23637
##                                              t value      Pr(>|t|)
## (Intercept)                              -49.5009913  1.218434e-23
## log(Time + 1)                             39.5108277 3.616177e-234
## Treatment_bisFull                         -1.3704943  1.707376e-01
## Treatment_bisSmart                        -3.8252307  1.385582e-04
## Treatment_bisMixt_smart                   -0.4700428  6.384915e-01
## SexMale                                   -1.4677682  1.423766e-01
## RegionLuxembourg                          -2.2092337  4.436000e-02
## Treatment_bisFull:RegionLuxembourg        -1.0642999  2.873639e-01
## Treatment_bisSmart:RegionLuxembourg        5.5463134  3.441909e-08
## Treatment_bisMixt_smart:RegionLuxembourg  -1.8617123  6.283873e-02
## SexFemale:Time                            -5.4556395  5.701479e-08
## SexMale:Time                              -4.2673888  2.101638e-05
## Treatment_bisFull:Time                     3.2437707  1.205630e-03
## Treatment_bisSmart:Time                    5.7243548  1.252999e-08
## Treatment_bisMixt_smart:Time               3.1880152  1.462244e-03
summary(lmer(log(Mass) ~ log(Time + 1) + Treatment + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment:Region +  Sex:Time + Treatment:Time, data = Data_mass_AE))$coeff
## boundary (singular) fit: see help('isSingular')
##                                    Estimate  Std. Error         df     t value
## (Intercept)                     -4.46431856 0.086085787   25.09907 -51.8589504
## log(Time + 1)                    1.95669407 0.049010482 1494.33051  39.9239916
## TreatmentFull                   -0.07952621 0.061506258 1503.89313  -1.2929776
## TreatmentSmart                  -0.09926120 0.062187684 1506.00280  -1.5961552
## SexMale                         -0.07870978 0.046117013 1505.05502  -1.7067406
## RegionLuxembourg                -0.24038054 0.102776140   14.45272  -2.3388749
## TreatmentFull:RegionLuxembourg  -0.06219461 0.070159896 1506.51870  -0.8864695
## TreatmentSmart:RegionLuxembourg  0.13865660 0.067594576 1508.16205   2.0512977
## SexFemale:Time                  -0.07240102 0.011770060 1502.03735  -6.1512875
## SexMale:Time                    -0.06146513 0.012535319 1503.37316  -4.9033561
## TreatmentFull:Time               0.03034798 0.009652753 1499.36338   3.1439713
## TreatmentSmart:Time              0.04009804 0.009987649 1499.69933   4.0147628
##                                      Pr(>|t|)
## (Intercept)                      4.716225e-27
## log(Time + 1)                   7.975599e-238
## TreatmentFull                    1.962174e-01
## TreatmentSmart                   1.106639e-01
## SexMale                          8.807655e-02
## RegionLuxembourg                 3.417564e-02
## TreatmentFull:RegionLuxembourg   3.755061e-01
## TreatmentSmart:RegionLuxembourg  4.041037e-02
## SexFemale:Time                   9.835797e-10
## SexMale:Time                     1.044262e-06
## TreatmentFull:Time               1.699395e-03
## TreatmentSmart:Time              6.244627e-05

Je continue avec treatment_bis

6.22.4 Résultats

Analyse des P-val

summary(lmer(log(Mass) ~ log(Time + 1) + Treatment_bis + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Sex:Time + Treatment_bis:Time, data = Data_mass_AE))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Mass) ~ log(Time + 1) + Treatment_bis + Sex + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  
##     Sex:Time + Treatment_bis:Time
##    Data: Data_mass_AE
## 
## REML criterion at convergence: 2363.8
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -4.7886 -0.6332  0.0249  0.6948  2.3466 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0260547 0.16141 
##  Site     (Intercept) 0.0130938 0.11443 
##  Room     (Intercept) 0.0006075 0.02465 
##  Residual             0.2556202 0.50559 
## Number of obs: 1523, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                              -4.444e+00  8.977e-02  2.149e+01
## log(Time + 1)                             1.913e+00  4.843e-02  1.490e+03
## Treatment_bisFull                        -8.259e-02  6.026e-02  1.501e+03
## Treatment_bisSmart                       -3.068e-01  8.022e-02  1.023e+03
## Treatment_bisMixt_smart                  -3.446e-02  7.332e-02  6.135e+02
## SexMale                                  -6.647e-02  4.529e-02  1.501e+03
## RegionLuxembourg                         -2.351e-01  1.064e-01  1.397e+01
## Treatment_bisFull:RegionLuxembourg       -7.320e-02  6.877e-02  1.503e+03
## Treatment_bisSmart:RegionLuxembourg       4.470e-01  8.059e-02  1.503e+03
## Treatment_bisMixt_smart:RegionLuxembourg -1.506e-01  8.088e-02  1.503e+03
## SexFemale:Time                           -6.326e-02  1.160e-02  1.498e+03
## SexMale:Time                             -5.271e-02  1.235e-02  1.500e+03
## Treatment_bisFull:Time                    3.070e-02  9.463e-03  1.495e+03
## Treatment_bisSmart:Time                   8.003e-02  1.398e-02  1.493e+03
## Treatment_bisMixt_smart:Time              3.638e-02  1.141e-02  1.492e+03
##                                          t value Pr(>|t|)    
## (Intercept)                              -49.501  < 2e-16 ***
## log(Time + 1)                             39.511  < 2e-16 ***
## Treatment_bisFull                         -1.370 0.170738    
## Treatment_bisSmart                        -3.825 0.000139 ***
## Treatment_bisMixt_smart                   -0.470 0.638491    
## SexMale                                   -1.468 0.142377    
## RegionLuxembourg                          -2.209 0.044360 *  
## Treatment_bisFull:RegionLuxembourg        -1.064 0.287364    
## Treatment_bisSmart:RegionLuxembourg        5.546 3.44e-08 ***
## Treatment_bisMixt_smart:RegionLuxembourg  -1.862 0.062839 .  
## SexFemale:Time                            -5.456 5.70e-08 ***
## SexMale:Time                              -4.267 2.10e-05 ***
## Treatment_bisFull:Time                     3.244 0.001206 ** 
## Treatment_bisSmart:Time                    5.724 1.25e-08 ***
## Treatment_bisMixt_smart:Time               3.188 0.001462 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 15 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
summary(lmer(log(Mass) ~ log(Time + 1) + Treatment_bis + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Sex:Time + Treatment_bis:Time, data = Data_mass_AE_ref_smart))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Mass) ~ log(Time + 1) + Treatment_bis + Sex + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  
##     Sex:Time + Treatment_bis:Time
##    Data: Data_mass_AE_ref_smart
## 
## REML criterion at convergence: 2363.8
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -4.7886 -0.6332  0.0249  0.6948  2.3466 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0260547 0.16141 
##  Site     (Intercept) 0.0130938 0.11443 
##  Room     (Intercept) 0.0006075 0.02465 
##  Residual             0.2556202 0.50559 
## Number of obs: 1523, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                                -4.75045    0.10164   33.33352
## log(Time + 1)                               1.91334    0.04843 1490.12098
## Treatment_bisDark                           0.30684    0.08022 1023.06235
## Treatment_bisFull                           0.22425    0.08002  850.97112
## Treatment_bisMixt_smart                     0.27238    0.09141  189.99750
## SexMale                                    -0.06647    0.04529 1501.49311
## RegionLuxembourg                            0.21189    0.11563   19.70058
## Treatment_bisDark:RegionLuxembourg         -0.44696    0.08059 1503.01309
## Treatment_bisFull:RegionLuxembourg         -0.52015    0.08065 1489.13361
## Treatment_bisMixt_smart:RegionLuxembourg   -0.59754    0.09143 1501.35834
## SexFemale:Time                              0.01676    0.01711 1493.63679
## SexMale:Time                                0.02732    0.01801 1495.10793
## Treatment_bisDark:Time                     -0.08003    0.01398 1492.62092
## Treatment_bisFull:Time                     -0.04933    0.01429 1491.86546
## Treatment_bisMixt_smart:Time               -0.04365    0.01548 1488.91049
##                                          t value Pr(>|t|)    
## (Intercept)                              -46.736  < 2e-16 ***
## log(Time + 1)                             39.511  < 2e-16 ***
## Treatment_bisDark                          3.825 0.000139 ***
## Treatment_bisFull                          2.803 0.005184 ** 
## Treatment_bisMixt_smart                    2.980 0.003261 ** 
## SexMale                                   -1.468 0.142377    
## RegionLuxembourg                           1.833 0.082033 .  
## Treatment_bisDark:RegionLuxembourg        -5.546 3.44e-08 ***
## Treatment_bisFull:RegionLuxembourg        -6.450 1.51e-10 ***
## Treatment_bisMixt_smart:RegionLuxembourg  -6.535 8.67e-11 ***
## SexFemale:Time                             0.980 0.327247    
## SexMale:Time                               1.517 0.129446    
## Treatment_bisDark:Time                    -5.724 1.25e-08 ***
## Treatment_bisFull:Time                    -3.452 0.000572 ***
## Treatment_bisMixt_smart:Time              -2.820 0.004864 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 15 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
summary(lmer(log(Mass) ~ log(Time + 1) + Treatment_bis + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Sex:Time + Treatment_bis:Time, data = Data_mass_AE_ref_full))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Mass) ~ log(Time + 1) + Treatment_bis + Sex + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  
##     Sex:Time + Treatment_bis:Time
##    Data: Data_mass_AE_ref_full
## 
## REML criterion at convergence: 2363.8
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -4.7886 -0.6332  0.0249  0.6948  2.3466 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0260547 0.16141 
##  Site     (Intercept) 0.0130938 0.11443 
##  Room     (Intercept) 0.0006075 0.02465 
##  Residual             0.2556202 0.50559 
## Number of obs: 1523, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                            Estimate Std. Error         df
## (Intercept)                              -4.526e+00  9.046e-02  2.240e+01
## log(Time + 1)                             1.913e+00  4.843e-02  1.490e+03
## Treatment_bisDark                         8.259e-02  6.026e-02  1.501e+03
## Treatment_bisSmart                       -2.243e-01  8.002e-02  8.510e+02
## Treatment_bisMixt_smart                   4.813e-02  7.220e-02  7.538e+02
## SexMale                                  -6.647e-02  4.529e-02  1.501e+03
## RegionLuxembourg                         -3.083e-01  1.071e-01  1.469e+01
## Treatment_bisDark:RegionLuxembourg        7.320e-02  6.877e-02  1.503e+03
## Treatment_bisSmart:RegionLuxembourg       5.202e-01  8.065e-02  1.489e+03
## Treatment_bisMixt_smart:RegionLuxembourg -7.738e-02  7.914e-02  1.502e+03
## SexFemale:Time                           -3.257e-02  1.263e-02  1.494e+03
## SexMale:Time                             -2.201e-02  1.269e-02  1.496e+03
## Treatment_bisDark:Time                   -3.070e-02  9.463e-03  1.495e+03
## Treatment_bisSmart:Time                   4.933e-02  1.429e-02  1.492e+03
## Treatment_bisMixt_smart:Time              5.684e-03  1.186e-02  1.491e+03
##                                          t value Pr(>|t|)    
## (Intercept)                              -50.037  < 2e-16 ***
## log(Time + 1)                             39.511  < 2e-16 ***
## Treatment_bisDark                          1.370 0.170738    
## Treatment_bisSmart                        -2.803 0.005184 ** 
## Treatment_bisMixt_smart                    0.667 0.505233    
## SexMale                                   -1.468 0.142377    
## RegionLuxembourg                          -2.878 0.011685 *  
## Treatment_bisDark:RegionLuxembourg         1.064 0.287364    
## Treatment_bisSmart:RegionLuxembourg        6.450 1.51e-10 ***
## Treatment_bisMixt_smart:RegionLuxembourg  -0.978 0.328333    
## SexFemale:Time                            -2.580 0.009984 ** 
## SexMale:Time                              -1.735 0.082912 .  
## Treatment_bisDark:Time                    -3.244 0.001206 ** 
## Treatment_bisSmart:Time                    3.452 0.000572 ***
## Treatment_bisMixt_smart:Time               0.479 0.631777    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 15 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
summary(lmer(log(Mass) ~ log(Time + 1) + Treatment_bis + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Sex:Time + Treatment_bis:Time, data = Data_mass_AE_ref_mixt_smart))
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log(Mass) ~ log(Time + 1) + Treatment_bis + Sex + Region + (1 |  
##     Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  
##     Sex:Time + Treatment_bis:Time
##    Data: Data_mass_AE_ref_mixt_smart
## 
## REML criterion at convergence: 2363.8
## 
## Scaled residuals: 
##     Min      1Q  Median      3Q     Max 
## -4.7886 -0.6332  0.0249  0.6948  2.3466 
## 
## Random effects:
##  Groups   Name        Variance  Std.Dev.
##  Mother   (Intercept) 0.0260547 0.16141 
##  Site     (Intercept) 0.0130938 0.11443 
##  Room     (Intercept) 0.0006075 0.02465 
##  Residual             0.2556202 0.50559 
## Number of obs: 1523, groups:  Mother, 24; Site, 13; Room, 2
## 
## Fixed effects:
##                                       Estimate Std. Error         df t value
## (Intercept)                         -4.478e+00  9.875e-02  2.933e+01 -45.345
## log(Time + 1)                        1.913e+00  4.843e-02  1.490e+03  39.511
## Treatment_bisDark                    3.446e-02  7.332e-02  6.135e+02   0.470
## Treatment_bisFull                   -4.813e-02  7.220e-02  7.538e+02  -0.667
## Treatment_bisSmart                  -2.724e-01  9.141e-02  1.900e+02  -2.980
## SexMale                             -6.647e-02  4.529e-02  1.501e+03  -1.468
## RegionLuxembourg                    -3.856e-01  1.154e-01  1.945e+01  -3.341
## Treatment_bisDark:RegionLuxembourg   1.506e-01  8.088e-02  1.503e+03   1.862
## Treatment_bisFull:RegionLuxembourg   7.738e-02  7.914e-02  1.502e+03   0.978
## Treatment_bisSmart:RegionLuxembourg  5.975e-01  9.143e-02  1.501e+03   6.535
## SexFemale:Time                      -2.688e-02  1.412e-02  1.493e+03  -1.904
## SexMale:Time                        -1.633e-02  1.497e-02  1.493e+03  -1.091
## Treatment_bisDark:Time              -3.638e-02  1.141e-02  1.492e+03  -3.188
## Treatment_bisFull:Time              -5.684e-03  1.186e-02  1.491e+03  -0.479
## Treatment_bisSmart:Time              4.365e-02  1.548e-02  1.489e+03   2.820
##                                     Pr(>|t|)    
## (Intercept)                          < 2e-16 ***
## log(Time + 1)                        < 2e-16 ***
## Treatment_bisDark                    0.63849    
## Treatment_bisFull                    0.50523    
## Treatment_bisSmart                   0.00326 ** 
## SexMale                              0.14238    
## RegionLuxembourg                     0.00335 ** 
## Treatment_bisDark:RegionLuxembourg   0.06284 .  
## Treatment_bisFull:RegionLuxembourg   0.32833    
## Treatment_bisSmart:RegionLuxembourg 8.67e-11 ***
## SexFemale:Time                       0.05706 .  
## SexMale:Time                         0.27566    
## Treatment_bisDark:Time               0.00146 ** 
## Treatment_bisFull:Time               0.63178    
## Treatment_bisSmart:Time              0.00486 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Correlation matrix not shown by default, as p = 15 > 12.
## Use print(x, correlation=TRUE)  or
##     vcov(x)        if you need it
test1 <- data.frame(Reference = "Dark", as.data.frame(( summary(lmer(log(Mass) ~ log(Time + 1) + Treatment_bis + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Sex:Time + Treatment_bis:Time, data = Data_mass_AE))$coeff)[,]))

test2 <- data.frame(Reference = "Smart", as.data.frame(( summary(lmer(log(Mass) ~ log(Time + 1) + Treatment_bis + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Sex:Time + Treatment_bis:Time, data = Data_mass_AE_ref_smart))$coeff)[,]))

test3 <- data.frame(Reference = "Full", as.data.frame(( summary(lmer(log(Mass) ~ log(Time + 1) + Treatment_bis + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Sex:Time + Treatment_bis:Time, data = Data_mass_AE_ref_full))$coeff)[,]))

test4 <- data.frame(Reference = "Mixt_smart", as.data.frame(( summary(lmer(log(Mass) ~ log(Time + 1) + Treatment_bis + Sex + Region + (1 |  Mother) + (1 | Site) + (1 | Room) + Treatment_bis:Region +  Sex:Time + Treatment_bis:Time, data = Data_mass_AE_ref_mixt_smart))$coeff)[,]))

Results_Mass_by_time_AE <- rbind(test1,test2,test3,test4)

colnames(Results_Mass_by_time_AE ) <- c("Reference","Estimate", "Std. Error", "df", "t.value", "Pr(>|z|)")

write.csv2( Results_Mass_by_time_AE , file = "output/Results_Mass_by_time_AE.csv" )

kable(Results_Mass_by_time_AE , caption = " Poids en fonction du temps OP ", padding = 1 )
Poids en fonction du temps OP
Reference Estimate Std. Error df t.value Pr(>|z|)
(Intercept) Dark -4.4436106 0.0897681 21.49434 -49.5009913 0.0000000
log(Time + 1) Dark 1.9133383 0.0484257 1490.12099 39.5108277 0.0000000
Treatment_bisFull Dark -0.0825923 0.0602646 1500.63377 -1.3704943 0.1707376
Treatment_bisSmart Dark -0.3068431 0.0802156 1023.06236 -3.8252307 0.0001386
Treatment_bisMixt_smart Dark -0.0344637 0.0733204 613.46518 -0.4700428 0.6384915
SexMale Dark -0.0664722 0.0452879 1501.49311 -1.4677682 0.1423766
RegionLuxembourg Dark -0.2350641 0.1064007 13.97362 -2.2092337 0.0443600
Treatment_bisFull:RegionLuxembourg Dark -0.0731967 0.0687745 1502.57903 -1.0642999 0.2873639
Treatment_bisSmart:RegionLuxembourg Dark 0.4469560 0.0805861 1503.01309 5.5463134 0.0000000
Treatment_bisMixt_smart:RegionLuxembourg Dark -0.1505816 0.0808834 1502.89824 -1.8617123 0.0628387
SexFemale:Time Dark -0.0632639 0.0115961 1497.79215 -5.4556395 0.0000001
SexMale:Time Dark -0.0527066 0.0123510 1499.65244 -4.2673888 0.0000210
Treatment_bisFull:Time Dark 0.0306947 0.0094627 1495.29475 3.2437707 0.0012056
Treatment_bisSmart:Time Dark 0.0800273 0.0139801 1492.62092 5.7243548 0.0000000
Treatment_bisMixt_smart:Time Dark 0.0363784 0.0114110 1492.23637 3.1880152 0.0014622
(Intercept)1 Smart -4.7504537 0.1016436 33.33352 -46.7363764 0.0000000
log(Time + 1)1 Smart 1.9133383 0.0484257 1490.12098 39.5108277 0.0000000
Treatment_bisDark Smart 0.3068431 0.0802156 1023.06235 3.8252307 0.0001386
Treatment_bisFull1 Smart 0.2242508 0.0800151 850.97112 2.8026063 0.0051843
Treatment_bisMixt_smart1 Smart 0.2723794 0.0914083 189.99750 2.9798107 0.0032611
SexMale1 Smart -0.0664722 0.0452879 1501.49311 -1.4677682 0.1423766
RegionLuxembourg1 Smart 0.2118919 0.1156285 19.70058 1.8325234 0.0820334
Treatment_bisDark:RegionLuxembourg Smart -0.4469560 0.0805861 1503.01309 -5.5463134 0.0000000
Treatment_bisFull:RegionLuxembourg1 Smart -0.5201527 0.0806479 1489.13361 -6.4496726 0.0000000
Treatment_bisMixt_smart:RegionLuxembourg1 Smart -0.5975376 0.0914316 1501.35834 -6.5353503 0.0000000
SexFemale:Time1 Smart 0.0167634 0.0171056 1493.63679 0.9799951 0.3272472
SexMale:Time1 Smart 0.0273206 0.0180082 1495.10793 1.5171261 0.1294462
Treatment_bisDark:Time Smart -0.0800273 0.0139801 1492.62092 -5.7243548 0.0000000
Treatment_bisFull:Time1 Smart -0.0493326 0.0142913 1491.86546 -3.4519409 0.0005721
Treatment_bisMixt_smart:Time1 Smart -0.0436488 0.0154777 1488.91049 -2.8201069 0.0048644
(Intercept)2 Full -4.5262029 0.0904563 22.39562 -50.0374423 0.0000000
log(Time + 1)2 Full 1.9133383 0.0484257 1490.12098 39.5108277 0.0000000
Treatment_bisDark1 Full 0.0825923 0.0602646 1500.63377 1.3704943 0.1707376
Treatment_bisSmart1 Full -0.2242508 0.0800151 850.97114 -2.8026062 0.0051843
Treatment_bisMixt_smart2 Full 0.0481286 0.0722003 753.82942 0.6665977 0.5052331
SexMale2 Full -0.0664722 0.0452879 1501.49311 -1.4677682 0.1423766
RegionLuxembourg2 Full -0.3082608 0.1070983 14.68677 -2.8782974 0.0116854
Treatment_bisDark:RegionLuxembourg1 Full 0.0731967 0.0687745 1502.57903 1.0642999 0.2873639
Treatment_bisSmart:RegionLuxembourg1 Full 0.5201527 0.0806479 1489.13361 6.4496726 0.0000000
Treatment_bisMixt_smart:RegionLuxembourg2 Full -0.0773849 0.0791422 1501.52959 -0.9777963 0.3283326
SexFemale:Time2 Full -0.0325692 0.0126252 1493.70720 -2.5796945 0.0099836
SexMale:Time2 Full -0.0220119 0.0126856 1495.58449 -1.7351963 0.0829120
Treatment_bisDark:Time1 Full -0.0306947 0.0094627 1495.29475 -3.2437707 0.0012056
Treatment_bisSmart:Time1 Full 0.0493326 0.0142913 1491.86546 3.4519409 0.0005721
Treatment_bisMixt_smart:Time2 Full 0.0056837 0.0118578 1491.37488 0.4793259 0.6317770
(Intercept)3 Mixt_smart -4.4780743 0.0987552 29.32734 -45.3452161 0.0000000
log(Time + 1)3 Mixt_smart 1.9133383 0.0484257 1490.12099 39.5108277 0.0000000
Treatment_bisDark2 Mixt_smart 0.0344637 0.0733204 613.46517 0.4700428 0.6384915
Treatment_bisFull2 Mixt_smart -0.0481286 0.0722003 753.82940 -0.6665977 0.5052331
Treatment_bisSmart2 Mixt_smart -0.2723794 0.0914083 189.99750 -2.9798107 0.0032611
SexMale3 Mixt_smart -0.0664722 0.0452879 1501.49311 -1.4677682 0.1423766
RegionLuxembourg3 Mixt_smart -0.3856457 0.1154138 19.45421 -3.3414188 0.0033459
Treatment_bisDark:RegionLuxembourg2 Mixt_smart 0.1505816 0.0808834 1502.89824 1.8617123 0.0628387
Treatment_bisFull:RegionLuxembourg2 Mixt_smart 0.0773849 0.0791422 1501.52959 0.9777963 0.3283326
Treatment_bisSmart:RegionLuxembourg2 Mixt_smart 0.5975376 0.0914316 1501.35834 6.5353503 0.0000000
SexFemale:Time3 Mixt_smart -0.0268855 0.0141181 1492.69888 -1.9043201 0.0570606
SexMale:Time3 Mixt_smart -0.0163282 0.0149730 1493.40299 -1.0905120 0.2756636
Treatment_bisDark:Time2 Mixt_smart -0.0363784 0.0114110 1492.23637 -3.1880152 0.0014622
Treatment_bisFull:Time2 Mixt_smart -0.0056837 0.0118578 1491.37488 -0.4793259 0.6317770
Treatment_bisSmart:Time2 Mixt_smart 0.0436488 0.0154777 1488.91049 2.8201069 0.0048644
Info_Mass_by_Time_AE <- "
Augmentation de la masse en fonction du temps
Smart est plus légere que n'importe quel autre traitement
Luxembourg est plus léger que Brabant pour les individus dans Dark
Luxembourg est plus léger que Brabant pour les individus dans Full
Par ordre d'optimisation du temps pour prendre de la masse croissant : Dark < Full & Mixt Smart < Smart
"
Info_Mass_by_Time_AE
## [1] "\nAugmentation de la masse en fonction du temps\nSmart est plus légere que n'importe quel autre traitement\nLuxembourg est plus léger que Brabant pour les individus dans Dark\nLuxembourg est plus léger que Brabant pour les individus dans Full\nPar ordre d'optimisation du temps pour prendre de la masse croissant : Dark < Full & Mixt Smart < Smart\n"