Running examples in ‘loewesadditivity-Ex.R’ failed
The error most likely occurred in:

> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: plot_surface
> ### Title: Plot the surface and observations
> ### Aliases: plot_surface
> 
> ### ** Examples
> 
> df <- loewesadditivity::cyrpa_ripr
> df$dose_A <- df$CyRPA
> df$dose_B <- df$RIPR
> data <- fortify_gia_data(df)
> model_params <- c("beta_A" = .5, "beta_B" = .5,
+                  "gamma_A" = .5, "gamma_B" = .5,
+                  "tau_1" = 0, "tau_2" = 0)
> n_boot <- 10
> GIA_fn <- base_GIA
> S_fn <- calc_S_base
> fn_list <- NULL
> alpha <- .05
> verbose <- FALSE
> out <- estimate_params(data = data,
+ init_params = model_params,
+ n_boot = n_boot,
+ GIA_fn = GIA_fn,
+ S_fn = S_fn,
+ fn_list = fn_list,
+ alpha = alpha,
+ verbose = verbose)
> plot_surface(out)
Error in `metR::geom_text_contour()`:
! Problem while converting geom to grob.
ℹ Error occurred in the 3rd layer.
Caused by error in `[.data.table`:
! attempt access index 18/18 in VECTOR_ELT
Backtrace:
     ▆
  1. ├─loewesadditivity::plot_surface(out)
  2. │ ├─base::print(g)
  3. │ └─ggplot2 (local) `print.ggplot2::ggplot`(g)
  4. │   ├─ggplot2::ggplot_gtable(data)
  5. │   └─ggplot2 (local) `ggplot_gtable.ggplot2::ggplot_built`(data)
  6. │     └─ggplot2:::by_layer(...)
  7. │       ├─rlang::try_fetch(...)
  8. │       │ ├─base::tryCatch(...)
  9. │       │ │ └─base (local) tryCatchList(expr, classes, parentenv, handlers)
 10. │       │ │   └─base (local) tryCatchOne(expr, names, parentenv, handlers[[1L]])
 11. │       │ │     └─base (local) doTryCatch(return(expr), name, parentenv, handler)
 12. │       │ └─base::withCallingHandlers(...)
 13. │       └─ggplot2 (local) f(l = layers[[i]], d = data[[i]])
 14. │         └─l$draw_geom(d, layout)
 15. │           └─ggplot2 (local) draw_geom(..., self = self)
 16. │             └─self$geom$draw_layer(...)
 17. │               └─ggplot2 (local) draw_layer(..., self = self)
 18. │                 └─base::lapply(...)
 19. │                   └─ggplot2 (local) FUN(X[[i]], ...)
 20. │                     ├─rlang::inject(self$draw_panel(data, panel_params, coord, !!!params))
 21. │                     └─self$draw_panel(...)
 22. │                       └─metR (local) draw_panel(...)
 23. │                         ├─data[, `:=`(N, .N), by = .(group, piece)]
 24. │                         └─data.table:::`[.data.table`(...)
 25. └─base::.handleSimpleError(...)
 26.   └─rlang (local) h(simpleError(msg, call))
 27.     └─handlers[[1L]](cnd)
 28.       └─cli::cli_abort(...)
 29.         └─rlang::abort(...)
Execution halted