I am fitting a gam using the MGCV package in R using the bam function:
gam_model = bam(y ~ s(time, k = -1) + s(ID, bs = 're'), family = 'gaussian', data = dat, method = "fREML", select = FALSE, nthreads = 64, discrete = TRUE, control = ctrl)
The size of the dataset is 10,388 observations. The GAM fits quite quickly (483 seconds), however the summary.gam function takes significantly longer: ~18 minutes (measured using the tictoc package).
Might anyone know what could be causing this?
This is the R version information:
platform x86_64-pc-linux-gnu arch x86_64 os linux-gnu system x86_64, linux-gnu status major 3 minor 6.3 year 2020 month 02 day 29 svn rev 77875 language R version.string R version 3.6.3 (2020-02-29) nickname Holding the Windsock