Exlporation

## Joining, by = c("year", "Site")
## `geom_smooth()` using method = 'gam' and formula 'y ~ s(x, bs = "cs")'

General model selection

Model Selection

Look at results

sigma loglik aic bic deviance df.residual r2.conditional r2.marginal icc rmse score.log score.spherical
1 -326118.5 652249.1 652293.1 573947.9 11418 0.994205 0.0487864 0.9939077 119.2766 -Inf 0.0042455
term estimate std.error conf.level conf.low conf.high statistic df.error p.value effect group
(Intercept) 4.8820477 0.1773985 0.95 4.5343531 5.2297423 27.52024 Inf 0 fixed
SeaIce 0.0034279 0.0002911 0.95 0.0028573 0.0039985 11.77384 Inf 0 fixed
age 0.0081185 0.0000916 0.95 0.0079390 0.0082980 88.65383 Inf 0 fixed
SeaIce:age -0.0000609 0.0000032 0.95 -0.0000671 -0.0000547 -19.23813 Inf 0 fixed
SD (Intercept) 0.4787174 NA 0.95 NA NA NA NA NA random Individual:Site
SD (Intercept) 0.8217339 NA 0.95 NA NA NA NA NA random Site
SD (Observations) 1.0000000 NA 0.95 NA NA NA NA NA random Residual

For temp and precip

General model selection Temp

Model Selection

## Joining, by = c("year", "Site")
sigma loglik aic bic deviance df.residual r2.conditional r2.marginal icc rmse score.log score.spherical
1 -268702.3 537416.5 537459.5 471430.2 9582 0.9910807 0.256555 0.9880027 118.9279 -Inf 0.0046435
term estimate std.error conf.level conf.low conf.high statistic df.error p.value effect group
(Intercept) 4.4414973 0.1239255 0.95 4.1986078 4.6843867 35.84007 Inf 0 fixed
Temperature 0.1128972 0.0018622 0.95 0.1092474 0.1165470 60.62612 Inf 0 fixed
age 0.0035335 0.0001825 0.95 0.0031757 0.0038912 19.35921 Inf 0 fixed
Temperature:age -0.0002285 0.0000235 0.95 -0.0002745 -0.0001825 -9.72767 Inf 0 fixed
SD (Intercept) 0.4136570 NA 0.95 NA NA NA NA NA random Individual:Site
SD (Intercept) 0.5390821 NA 0.95 NA NA NA NA NA random Site
SD (Observations) 1.0000000 NA 0.95 NA NA NA NA NA random Residual

General model selection Prec

Model Selection

## Joining, by = c("year", "Site")
## for distance: in month 1 Month and lag 1, 1, 1 rmse = 139.255086087724
## Joining, by = c("year", "Site")
## for distance: in month 3 Months and lag 1, 1, 1 rmse = 140.890539913043
## Joining, by = c("year", "Site")
## for distance: in month 5 Months and lag 1, 1, 1 rmse = 140.567382295569
## Joining, by = c("year", "Site")
## for distance: in month 1 Month and lag 1, 1, 0.6 rmse = 139.010789933175
## Joining, by = c("year", "Site")
## for distance: in month 3 Months and lag 1, 1, 0.6 rmse = 140.322882651472
## Joining, by = c("year", "Site")
## for distance: in month 5 Months and lag 1, 1, 0.6 rmse = 140.411552602555
## Joining, by = c("year", "Site")
## for distance: in month 1 Month and lag 1, 0.6, 0.6 rmse = 139.001244291099
## Joining, by = c("year", "Site")
## for distance: in month 3 Months and lag 1, 0.6, 0.6 rmse = 140.276667878914
## Joining, by = c("year", "Site")
## for distance: in month 5 Months and lag 1, 0.6, 0.6 rmse = 140.537281858137
## Joining, by = c("year", "Site")
## for distance: in month 1 Month and lag 1, 1, 0.4 rmse = 139.025591411743
## Joining, by = c("year", "Site")
## for distance: in month 3 Months and lag 1, 1, 0.4 rmse = 140.065397061673
## Joining, by = c("year", "Site")
## for distance: in month 5 Months and lag 1, 1, 0.4 rmse = 140.265960819607
## Joining, by = c("year", "Site")
## for distance: in month 1 Month and lag 1, 0.6, 0.4 rmse = 138.96613004196
## Joining, by = c("year", "Site")
## for distance: in month 3 Months and lag 1, 0.6, 0.4 rmse = 139.967858597932
## Joining, by = c("year", "Site")
## for distance: in month 5 Months and lag 1, 0.6, 0.4 rmse = 140.432946327702
## Joining, by = c("year", "Site")
## for distance: in month 1 Month and lag 1, 0.4, 0.4 rmse = 139.131018017459
## Joining, by = c("year", "Site")
## for distance: in month 3 Months and lag 1, 0.4, 0.4 rmse = 139.855973532081
## Joining, by = c("year", "Site")
## for distance: in month 5 Months and lag 1, 0.4, 0.4 rmse = 140.346400785004
## Joining, by = c("year", "Site")
## for distance: in month 1 Month and lag 1, 1, 0 rmse = 139.327658907572
## Joining, by = c("year", "Site")
## for distance: in month 3 Months and lag 1, 1, 0 rmse = 139.827566971016
## Joining, by = c("year", "Site")
## for distance: in month 5 Months and lag 1, 1, 0 rmse = 139.913092253992
## Joining, by = c("year", "Site")
## for distance: in month 1 Month and lag 1, 0.6, 0 rmse = 139.213431029874
## Joining, by = c("year", "Site")
## for distance: in month 3 Months and lag 1, 0.6, 0 rmse = 139.635311856949
## Joining, by = c("year", "Site")
## for distance: in month 5 Months and lag 1, 0.6, 0 rmse = 140.004697616627
## Joining, by = c("year", "Site")
## for distance: in month 1 Month and lag 1, 0.4, 0 rmse = 139.311504323035
## Joining, by = c("year", "Site")
## for distance: in month 3 Months and lag 1, 0.4, 0 rmse = 139.58061907075
## Joining, by = c("year", "Site")
## for distance: in month 5 Months and lag 1, 0.4, 0 rmse = 140.006465599509
## Joining, by = c("year", "Site")
## for distance: in month 1 Month and lag 1, 0, 0 rmse = 139.759725014458
## Joining, by = c("year", "Site")
## for distance: in month 3 Months and lag 1, 0, 0 rmse = 139.677544030951
## Joining, by = c("year", "Site")
## for distance: in month 5 Months and lag 1, 0, 0 rmse = 139.918483152781
## Joining, by = c("year", "Site")
sigma loglik aic bic deviance df.residual r2.conditional r2.marginal icc rmse score.log score.spherical
1 -288909.3 577830.6 577873.9 508271.4 10106 0.9936923 0.0562368 0.9933164 120.9868 -Inf 0.0044948
term estimate std.error conf.level conf.low conf.high statistic df.error p.value effect group
(Intercept) 4.8332115 0.1773327 0.95 4.4856457 5.1807772 27.255046 Inf 0.000000 fixed
Prec 0.0002826 0.0000113 0.95 0.0002604 0.0003048 24.979951 Inf 0.000000 fixed
age 0.0076938 0.0001061 0.95 0.0074859 0.0079018 72.528388 Inf 0.000000 fixed
Prec:age 0.0000009 0.0000003 0.95 0.0000002 0.0000016 2.604716 Inf 0.009195 fixed
SD (Intercept) 0.4620753 NA 0.95 NA NA NA NA NA random Individual:Site
SD (Intercept) 0.7881173 NA 0.95 NA NA NA NA NA random Site
SD (Observations) 1.0000000 NA 0.95 NA NA NA NA NA random Residual

SPEI

## Loading required package: sp
## 
## Attaching package: 'raster'
## The following object is masked from 'package:nlme':
## 
##     getData
## The following object is masked from 'package:lme4':
## 
##     getData
## The following object is masked from 'package:dplyr':
## 
##     select
## Linking to GEOS 3.9.1, GDAL 3.2.1, PROJ 7.2.1; sf_use_s2() is TRUE
## Loading required package: lmomco
## # Package SPEI (1.7) loaded [try SPEINews()].
## [1] "1 of 22 ready"
## [1] "2 of 22 ready"
## [1] "3 of 22 ready"
## [1] "4 of 22 ready"
## [1] "5 of 22 ready"
## [1] "6 of 22 ready"
## [1] "7 of 22 ready"
## [1] "8 of 22 ready"
## [1] "9 of 22 ready"
## [1] "10 of 22 ready"
## Error in spei(NewMonthly2[[i]]$bal, 1) : Error: Data must not contain NAs
## Error in spei(NewMonthly2[[i]]$bal, 3) : Error: Data must not contain NAs
## Error in spei(NewMonthly2[[i]]$bal, 5) : Error: Data must not contain NAs
## [1] "11 of 22 ready"
## [1] "12 of 22 ready"
## [1] "13 of 22 ready"
## [1] "14 of 22 ready"
## [1] "15 of 22 ready"
## [1] "16 of 22 ready"
## [1] "17 of 22 ready"
## [1] "18 of 22 ready"
## [1] "19 of 22 ready"
## [1] "20 of 22 ready"
## [1] "21 of 22 ready"
## [1] "22 of 22 ready"

General model selection SPEI

Model Selection

## Joining, by = c("year", "Site")
sigma loglik aic bic deviance df.residual r2.conditional r2.marginal icc rmse score.log score.spherical
1 -327590.1 655192.2 655236.3 576341 11501 0.9941293 0.0492325 0.9938253 119.2587 -Inf 0.0042402
term estimate std.error conf.level conf.low conf.high statistic df.error p.value effect group
(Intercept) 4.8826631 0.1760372 0.95 4.5376365 5.2276897 27.736542 Inf 0.0e+00 fixed
SPEI 0.0004291 0.0000137 0.95 0.0004023 0.0004559 31.359414 Inf 0.0e+00 fixed
age 0.0075518 0.0000961 0.95 0.0073634 0.0077403 78.542150 Inf 0.0e+00 fixed
SPEI:age -0.0000020 0.0000004 0.95 -0.0000028 -0.0000012 -4.769261 Inf 1.8e-06 fixed
SD (Intercept) 0.4855703 NA 0.95 NA NA NA NA NA random Individual:Site
SD (Intercept) 0.8006826 NA 0.95 NA NA NA NA NA random Site
SD (Observations) 1.0000000 NA 0.95 NA NA NA NA NA random Residual

Final dataset

## Joining, by = c("Growth", "SeaIce", "age", "Individual", "year", "Site")
## Joining, by = c("Growth", "age", "Individual", "year", "Site", "Prec")
## Joining, by = c("Growth", "age", "Individual", "year", "Site", "SPEI")
## Joining, by = c("Growth", "age", "Individual", "year", "Site", "Temperature")

SEM

## 
##   This is piecewiseSEM version 2.1.0.
## 
## 
##   Questions or bugs can be addressed to <LefcheckJ@si.edu>.

Per site