Calling libraries

library(lme4)
## Loading required package: Matrix

Tidy Data

path = "~/201 2025/Hibernation_Data.csv"
hdf <-read.csv(path)
hdf$Sex <- as.factor(hdf$Sex)

Linear Mixed Model modeling Mass

lm1 <- lmer(Mass ~ Sex + ExpWk + Sex:ExpWk + FoodInt + PercFat + BMI + (1 | AnNum), data = hdf)
summary(lm1)
## Linear mixed model fit by REML ['lmerMod']
## Formula: Mass ~ Sex + ExpWk + Sex:ExpWk + FoodInt + PercFat + BMI + (1 |  
##     AnNum)
##    Data: hdf
## 
## REML criterion at convergence: 41.4
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -0.78656 -0.25228  0.01139  0.22002  0.76378 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  AnNum    (Intercept) 127.905  11.309  
##  Residual               4.735   2.176  
## Number of obs: 14, groups:  AnNum, 5
## 
## Fixed effects:
##                    Estimate Std. Error t value
## (Intercept)       -14.21752   89.42624  -0.159
## SexM               11.90993   13.92528   0.855
## ExpWkPstHib3        9.32994   14.81035   0.630
## ExpWkPstHib4       13.31567    9.65295   1.379
## FoodInt            -1.55807    1.97308  -0.790
## PercFat            -0.01129    0.35656  -0.032
## BMI                36.90287   19.44914   1.897
## SexM:ExpWkPstHib3  -2.58632   17.17902  -0.151
## SexM:ExpWkPstHib4  -4.98426   13.53549  -0.368
## 
## Correlation of Fixed Effects:
##             (Intr) SexM   ExWPH3 ExWPH4 FodInt PercFt BMI    SM:EWPH3
## SexM        -0.655                                                   
## ExpWkPstHb3 -0.959  0.640                                            
## ExpWkPstHb4 -0.953  0.625  0.965                                     
## FoodInt      0.740 -0.617 -0.830 -0.769                              
## PercFat      0.862 -0.513 -0.855 -0.900  0.556                       
## BMI         -0.995  0.616  0.970  0.962 -0.771 -0.873                
## SxM:ExpWPH3  0.968 -0.634 -0.992 -0.966  0.792  0.872 -0.976         
## SxM:ExpWPH4  0.973 -0.623 -0.962 -0.982  0.750  0.872 -0.977  0.973

Linear Mixed Model modeling BMI

lm2 <- lmer(BMI ~ Sex + ExpWk + Sex:ExpWk + FoodInt + PercFat + Mass + (1 | AnNum), data = hdf)
summary(lm2)
## Linear mixed model fit by REML ['lmerMod']
## Formula: BMI ~ Sex + ExpWk + Sex:ExpWk + FoodInt + PercFat + Mass + (1 |  
##     AnNum)
##    Data: hdf
## 
## REML criterion at convergence: 6.4
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -1.10874 -0.23986  0.01941  0.31823  1.06314 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  AnNum    (Intercept) 0.002176 0.04664 
##  Residual             0.002351 0.04849 
## Number of obs: 14, groups:  AnNum, 5
## 
## Fixed effects:
##                    Estimate Std. Error t value
## (Intercept)        3.402173   0.391101   8.699
## SexM              -0.355120   0.076430  -4.646
## ExpWkPstHib3      -0.550536   0.099110  -5.555
## ExpWkPstHib4      -0.437298   0.063425  -6.895
## FoodInt            0.046837   0.015244   3.072
## PercFat            0.012603   0.004308   2.925
## Mass               0.007958   0.002776   2.867
## SexM:ExpWkPstHib3  0.598446   0.127701   4.686
## SexM:ExpWkPstHib4  0.521664   0.088586   5.889
## 
## Correlation of Fixed Effects:
##             (Intr) SexM   ExWPH3 ExWPH4 FodInt PercFt Mass   SM:EWPH3
## SexM        -0.411                                                   
## ExpWkPstHb3 -0.696  0.559                                            
## ExpWkPstHb4 -0.459  0.541  0.637                                     
## FoodInt      0.478 -0.577 -0.594 -0.387                              
## PercFat      0.660 -0.363 -0.650 -0.625  0.400                       
## Mass        -0.979  0.405  0.725  0.484 -0.582 -0.749                
## SxM:ExpWPH3  0.771 -0.583 -0.933 -0.605  0.544  0.693 -0.794         
## SxM:ExpWPH4  0.704 -0.589 -0.662 -0.802  0.415  0.595 -0.699  0.746

Linear Mixed Model modeling FoodInt

lm3 <- lmer(FoodInt ~ ExpWk + Sex:ExpWk + PercFat + Mass + BMI + (1 | AnNum), data = hdf)
summary(lm3)
## Linear mixed model fit by REML ['lmerMod']
## Formula: FoodInt ~ ExpWk + Sex:ExpWk + PercFat + Mass + BMI + (1 | AnNum)
##    Data: hdf
## 
## REML criterion at convergence: 28.2
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -0.64018 -0.48002  0.02578  0.31839  0.87512 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  AnNum    (Intercept) 2.2297   1.4932  
##  Residual             0.3217   0.5671  
## Number of obs: 14, groups:  AnNum, 5
## 
## Fixed effects:
##                    Estimate Std. Error t value
## (Intercept)       -37.74806   13.42938  -2.811
## ExpWkPstHib3        7.06798    1.94882   3.627
## ExpWkPstHib4        4.86036    1.68397   2.886
## PercFat            -0.12596    0.07011  -1.797
## Mass               -0.05749    0.07544  -0.762
## BMI                10.39137    3.89634   2.667
## ExpWkPstHib2:SexM   5.00244    1.71794   2.912
## ExpWkPstHib3:SexM  -2.52690    2.24932  -1.123
## ExpWkPstHib4:SexM  -0.91766    1.91258  -0.480
## 
## Correlation of Fixed Effects:
##             (Intr) ExWPH3 ExWPH4 PercFt Mass   BMI    EWPH2: EWPH3:
## ExpWkPstHb3 -0.899                                                 
## ExpWkPstHb4 -0.792  0.862                                          
## PercFat      0.779 -0.799 -0.733                                   
## Mass         0.097 -0.223 -0.524 -0.012                            
## BMI         -0.773  0.788  0.903 -0.573 -0.702                     
## ExpWkPH2:SM -0.483  0.490  0.550 -0.368 -0.334  0.521              
## ExpWkPH3:SM  0.607 -0.644 -0.391  0.601 -0.259 -0.302  0.288       
## ExpWkPH4:SM  0.572 -0.533 -0.459  0.521 -0.130 -0.360  0.353  0.896

Linear Mixed Model modeling PercFat

lm4 <- lmer(PercFat ~ ExpWk + Sex:ExpWk + Mass + BMI + FoodInt + (1 | AnNum), data = hdf)
summary(lm3)
## Linear mixed model fit by REML ['lmerMod']
## Formula: FoodInt ~ ExpWk + Sex:ExpWk + PercFat + Mass + BMI + (1 | AnNum)
##    Data: hdf
## 
## REML criterion at convergence: 28.2
## 
## Scaled residuals: 
##      Min       1Q   Median       3Q      Max 
## -0.64018 -0.48002  0.02578  0.31839  0.87512 
## 
## Random effects:
##  Groups   Name        Variance Std.Dev.
##  AnNum    (Intercept) 2.2297   1.4932  
##  Residual             0.3217   0.5671  
## Number of obs: 14, groups:  AnNum, 5
## 
## Fixed effects:
##                    Estimate Std. Error t value
## (Intercept)       -37.74806   13.42938  -2.811
## ExpWkPstHib3        7.06798    1.94882   3.627
## ExpWkPstHib4        4.86036    1.68397   2.886
## PercFat            -0.12596    0.07011  -1.797
## Mass               -0.05749    0.07544  -0.762
## BMI                10.39137    3.89634   2.667
## ExpWkPstHib2:SexM   5.00244    1.71794   2.912
## ExpWkPstHib3:SexM  -2.52690    2.24932  -1.123
## ExpWkPstHib4:SexM  -0.91766    1.91258  -0.480
## 
## Correlation of Fixed Effects:
##             (Intr) ExWPH3 ExWPH4 PercFt Mass   BMI    EWPH2: EWPH3:
## ExpWkPstHb3 -0.899                                                 
## ExpWkPstHb4 -0.792  0.862                                          
## PercFat      0.779 -0.799 -0.733                                   
## Mass         0.097 -0.223 -0.524 -0.012                            
## BMI         -0.773  0.788  0.903 -0.573 -0.702                     
## ExpWkPH2:SM -0.483  0.490  0.550 -0.368 -0.334  0.521              
## ExpWkPH3:SM  0.607 -0.644 -0.391  0.601 -0.259 -0.302  0.288       
## ExpWkPH4:SM  0.572 -0.533 -0.459  0.521 -0.130 -0.360  0.353  0.896
jtools::summ(lm1)
Observations 14
Dependent variable Mass
Type Mixed effects linear regression
AIC 63.39
BIC 70.42
Pseudo-R² (fixed effects) 0.54
Pseudo-R² (total) 0.98
Fixed Effects
Est. S.E. t val. d.f. p
(Intercept) -14.22 89.43 -0.16 2.66 0.88
SexM 11.91 13.93 0.86 4.81 0.43
ExpWkPstHib3 9.33 14.81 0.63 2.61 0.58
ExpWkPstHib4 13.32 9.65 1.38 2.50 0.28
FoodInt -1.56 1.97 -0.79 3.10 0.49
PercFat -0.01 0.36 -0.03 2.26 0.98
BMI 36.90 19.45 1.90 2.61 0.17
SexM:ExpWkPstHib3 -2.59 17.18 -0.15 2.58 0.89
SexM:ExpWkPstHib4 -4.98 13.54 -0.37 2.56 0.74
p values calculated using Satterthwaite d.f.
Random Effects
Group Parameter Std. Dev.
AnNum (Intercept) 11.31
Residual 2.18
Grouping Variables
Group # groups ICC
AnNum 5 0.96
jtools::summ(lm2)
Observations 14
Dependent variable BMI
Type Mixed effects linear regression
AIC 28.43
BIC 35.46
Pseudo-R² (fixed effects) 0.95
Pseudo-R² (total) 0.98
Fixed Effects
Est. S.E. t val. d.f. p
(Intercept) 3.40 0.39 8.70 1.76 0.02
SexM -0.36 0.08 -4.65 2.65 0.02
ExpWkPstHib3 -0.55 0.10 -5.55 4.98 0.00
ExpWkPstHib4 -0.44 0.06 -6.89 3.81 0.00
FoodInt 0.05 0.02 3.07 2.41 0.07
PercFat 0.01 0.00 2.93 4.41 0.04
Mass 0.01 0.00 2.87 2.52 0.08
SexM:ExpWkPstHib3 0.60 0.13 4.69 4.97 0.01
SexM:ExpWkPstHib4 0.52 0.09 5.89 5.00 0.00
p values calculated using Satterthwaite d.f.
Random Effects
Group Parameter Std. Dev.
AnNum (Intercept) 0.05
Residual 0.05
Grouping Variables
Group # groups ICC
AnNum 5 0.48
jtools::summ(lm3)
Observations 14
Dependent variable FoodInt
Type Mixed effects linear regression
AIC 50.20
BIC 57.23
Pseudo-R² (fixed effects) 0.55
Pseudo-R² (total) 0.94
Fixed Effects
Est. S.E. t val. d.f. p
(Intercept) -37.75 13.43 -2.81 4.83 0.04
ExpWkPstHib3 7.07 1.95 3.63 4.19 0.02
ExpWkPstHib4 4.86 1.68 2.89 3.93 0.05
PercFat -0.13 0.07 -1.80 4.38 0.14
Mass -0.06 0.08 -0.76 4.07 0.49
BMI 10.39 3.90 2.67 3.99 0.06
ExpWkPstHib2:SexM 5.00 1.72 2.91 3.15 0.06
ExpWkPstHib3:SexM -2.53 2.25 -1.12 3.40 0.33
ExpWkPstHib4:SexM -0.92 1.91 -0.48 3.00 0.66
p values calculated using Satterthwaite d.f.
Random Effects
Group Parameter Std. Dev.
AnNum (Intercept) 1.49
Residual 0.57
Grouping Variables
Group # groups ICC
AnNum 5 0.87
jtools::summ(lm4)
Observations 14
Dependent variable PercFat
Type Mixed effects linear regression
AIC 61.50
BIC 68.53
Pseudo-R² (fixed effects) 0.80
Pseudo-R² (total) 0.86
Fixed Effects
Est. S.E. t val. d.f. p
(Intercept) -185.77 48.89 -3.80 4.99 0.01
ExpWkPstHib3 31.84 7.55 4.22 4.54 0.01
ExpWkPstHib4 24.72 6.32 3.91 4.96 0.01
Mass -0.21 0.25 -0.81 4.31 0.46
BMI 48.27 17.14 2.82 4.97 0.04
FoodInt -2.80 0.84 -3.32 0.98 0.19
ExpWkPstHib2:SexM 19.64 5.96 3.29 3.13 0.04
ExpWkPstHib3:SexM -16.57 4.95 -3.35 2.77 0.05
ExpWkPstHib4:SexM -10.12 4.36 -2.32 3.00 0.10
p values calculated using Satterthwaite d.f.
Random Effects
Group Parameter Std. Dev.
AnNum (Intercept) 2.02
Residual 3.19
Grouping Variables
Group # groups ICC
AnNum 5 0.29