Error(s) in re-building vignettes:
--- re-building ‘Introduction.Rmd’ using rmarkdown

 *** caught segfault ***
address 0x110, cause 'invalid permissions'

 *** caught segfault ***
address 0x110, cause 'invalid permissions'

Traceback:
 1: cpp_horseshoe(X, Y, intercept, as.integer(nburn), as.integer(npost),     seed, verbose, as.integer(printevery), as.integer(chain_index))
 2: horseshoe_mcmc(X, Y, intercept = !standardize, nburn = nburn,     npost = npost, seed = seed_chain, verbose = output_verbose,     printevery = printevery, chain_index = chain)
 3: eval(c.expr, envir = args, enclos = envir)
 4: eval(c.expr, envir = args, enclos = envir)

Traceback:
 1: cpp_horseshoe(X, Y, intercept, as.integer(nburn), as.integer(npost),     seed, verbose, as.integer(printevery), as.integer(chain_index))
 2: horseshoe_mcmc(X, Y, intercept = !standardize, nburn = nburn,     npost = npost, seed = seed_chain, verbose = output_verbose,     printevery = printevery, chain_index = chain)
 3: eval(c.expr, envir = args, enclos = envir)
 5: doTryCatch(return(expr), name, parentenv, handler)
 4: eval(c.expr, envir = args, enclos = envir)
 5: doTryCatch(return(expr), name, parentenv, handler)
 6: tryCatchOne(expr, names, parentenv, handlers[[1L]])
 7: tryCatchList(expr, classes, parentenv, handlers)
 8: tryCatch(eval(c.expr, envir = args, enclos = envir), error = function(e) e)
 9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
11:  6: tryCatchOne(expr, names, parentenv, handlers[[1L]])
 7: tryCatchList(expr, classes, parentenv, handlers)
 8: tryCatch(eval(c.expr, envir = args, enclos = envir), error = function(e) e)
 9: FUN(X[[i]], ...)
10: lapply(X = S, FUN = FUN, ...)
doTryCatch(return(expr), name, parentenv, handler)
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: tryCatch(expr, error = function(e) {    call <- conditionCall(e)    if (!is.null(call)) {        if (identical(call[[1L]], quote(doTryCatch)))             call <- sys.call(-4L)        dcall <- deparse(call, nlines = 1L)        prefix <- paste("Error in", dcall, ": ")        LONG <- 75L        sm <- strsplit(conditionMessage(e), "\n")[[1L]]        w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w")        if (is.na(w))             w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L],                 type = "b")        if (w > LONG) 11: doTryCatch(return(expr), name, parentenv, handler)
            prefix <- paste0(prefix, "\n  ")    }    else prefix <- "Error : "    msg <- paste0(prefix, conditionMessage(e), "\n")    .Internal(seterrmessage(msg[1L]))    if (!silent && isTRUE(getOption("show.error.messages"))) {        cat(msg, file = outFile)        .Internal(printDeferredWarnings())    }    invisible(structure(msg, class = "try-error", condition = e))})
12: tryCatchOne(expr, names, parentenv, handlers[[1L]])
13: tryCatchList(expr, classes, parentenv, handlers)
14: tryCatch(expr, error = function(e) {    call <- conditionCall(e)    if (!is.null(call)) {        if (identical(call[[1L]], quote(doTryCatch)))             call <- sys.call(-4L)        dcall <- deparse(call, nlines = 1L)        prefix <- paste("Error in", dcall, ": ")        LONG <- 75L        sm <- strsplit(conditionMessage(e), "\n")[[1L]]        w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w")        if (is.na(w))             w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L],                 type = "b")15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)
        if (w > LONG)             prefix <- paste0(prefix, "\n  ")    }    else prefix <- "Error : "    msg <- paste0(prefix, conditionMessage(e), "\n")    .Internal(seterrmessage(msg[1L]))    if (!silent && isTRUE(getOption("show.error.messages"))) {        cat(msg, file = outFile)        .Internal(printDeferredWarnings())    }    invisible(structure(msg, class = "try-error", condition = e))})
15: try(lapply(X = S, FUN = FUN, ...), silent = TRUE)16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18: lapply(seq_len(cores), inner.do)
19: mclapply(argsList, FUN, mc.preschedule = preschedule, mc.set.seed = set.seed,     mc.silent = silent, mc.cores = cores)
20: e$fun(obj, substitute(ex), parent.frame(), e$data)
21: foreach::foreach(chain = 1:nchains, .combine = list, .multicombine = TRUE, 
16: sendMaster(try(lapply(X = S, FUN = FUN, ...), silent = TRUE))
17: FUN(X[[i]], ...)
18:     .maxcombine = ifelse(nchains >= 2, nchains, 2)) %dopar% {    seed_chain = if (!is.null(seed))         seed + chain    else NULL    return(switch(model, Multi_Laplace = {        multi_laplace_mcmc(X, Y, intercept = !standardize, h = extra_parameters$h,             v = extra_parameters$v, nburn = nburn, npost = npost,             seed = seed_chain, verbose = output_verbose, printevery = printevery,             chain_index = chain)    }, Horseshoe = {lapply(seq_len(cores), inner.do)
19: mclapply(argsList, FUN, mc.preschedule = preschedule, mc.set.seed = set.seed,     mc.silent = silent, mc.cores = cores)
20: e$fun(obj, substitute(ex), parent.frame(), e$data)        horseshoe_mcmc(X, Y, intercept = !standardize, nburn = nburn,             npost = npost, seed = seed_chain, verbose = output_verbose,             printevery = printevery, chain_index = chain)    }, ARD = {        ARD_mcmc(X, Y, intercept = !standardize, nburn = nburn,             npost = npost, seed = seed_chain, verbose = output_verbose,             printevery = printevery, chain_index = chain)    }, Spike_Laplace = {
21: foreach::foreach(chain = 1:nchains, .combine = list, .multicombine = TRUE,     .maxcombine = ifelse(nchains >= 2, nchains, 2)) %dopar% {    seed_chain = if (!is.null(seed))         seed + chain    else NULL        spike_laplace_partially_mcmc(X, Y, intercept = !standardize,             a = extra_parameters$a, b = extra_parameters$b, nburn = nburn,             npost = npost, seed = seed_chain, verbose = output_verbose,             printevery = printevery, chain_index = chain)    }))}
22: withCallingHandlers(expr, warning = function(w) if (inherits(w,     return(switch(model, Multi_Laplace = {        multi_laplace_mcmc(X, Y, intercept = !standardize, h = extra_parameters$h,             v = extra_parameters$v, nburn = nburn, npost = npost,             seed = seed_chain, verbose = output_verbose, printevery = printevery,             chain_index = chain)    }, Horseshoe = {        horseshoe_mcmc(X, Y, intercept = !standardize, nburn = nburn,             npost = npost, seed = seed_chain, verbose = output_verbose,             printevery = printevery, chain_index = chain)    classes)) tryInvokeRestart("muffleWarning"))
23: suppressWarnings(foreach::foreach(chain = 1:nchains, .combine = list,     .multicombine = TRUE, .maxcombine = ifelse(nchains >= 2,         nchains, 2)) %dopar% {    seed_chain = if (!is.null(seed))         seed + chain    else NULL    return(switch(model, Multi_Laplace = {    }, ARD = {        ARD_mcmc(X, Y, intercept = !standardize, nburn = nburn,             npost = npost, seed = seed_chain, verbose = output_verbose,             printevery = printevery, chain_index = chain)    }, Spike_Laplace = {        spike_laplace_partially_mcmc(X, Y, intercept = !standardize,             a = extra_parameters$a, b = extra_parameters$b, nburn = nburn,             npost = npost, seed = seed_chain, verbose = output_verbose,             printevery = printevery, chain_index = chain)    }))}
22: withCallingHandlers(expr, warning = function(w) if (inherits(w,     classes)) tryInvokeRestart("muffleWarning"))
23:         multi_laplace_mcmc(X, Y, intercept = !standardize, h = extra_parameters$h,             v = extra_parameters$v, nburn = nburn, npost = npost,             seed = seed_chain, verbose = output_verbose, printevery = printevery,             chain_index = chain)    }, Horseshoe = {        horseshoe_mcmc(X, Y, intercept = !standardize, nburn = nburn,             npost = npost, seed = seed_chain, verbose = output_verbose,             printevery = printevery, chain_index = chain)    }, ARD = {        ARD_mcmc(X, Y, intercept = !standardize, nburn = nburn,             npost = npost, seed = seed_chain, verbose = output_verbose,             printevery = printevery, chain_index = chain)    }, Spike_Laplace = {        spike_laplace_partially_mcmc(X, Y, intercept = !standardize,             a = extra_parameters$a, b = extra_parameters$b, nburn = nburn,             npost = npost, seed = seed_chain, verbose = output_verbose,             printevery = printevery, chain_index = chain)    }))})
24: BMI_LASSO(data$data_MI$X, data$data_MI$Y, model = "Horseshoe",     nburn = 4000, npost = 4000, output_verbose = FALSE, nchains = 2,     ncores = 2, seed = seed)
25: eval(expr, envir)
26: eval(expr, envir)
27: withVisible(eval(expr, envir))
28: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) {    watcher$capture_plot_and_output()suppressWarnings(foreach::foreach(chain = 1:nchains, .combine = list,     if (on_message$capture) {        watcher$push(cnd)    }    if (on_message$silence) {        invokeRestart("muffleMessage")    }}, warning = function (cnd) {    .multicombine = TRUE, .maxcombine = ifelse(nchains >= 2,         nchains, 2)) %dopar% {    seed_chain = if (!is.null(seed))         seed + chain    if (getOption("warn") >= 2 || getOption("warn") < 0) {        return()    else NULL    return(switch(model, Multi_Laplace = {        multi_laplace_mcmc(X, Y, intercept = !standardize, h = extra_parameters$h,             v = extra_parameters$v, nburn = nburn, npost = npost,             seed = seed_chain, verbose = output_verbose, printevery = printevery,             chain_index = chain)    }, Horseshoe = {        horseshoe_mcmc(X, Y, intercept = !standardize, nburn = nburn,             npost = npost, seed = seed_chain, verbose = output_verbose,             printevery = printevery, chain_index = chain)    }, ARD = {        ARD_mcmc(X, Y, intercept = !standardize, nburn = nburn,             npost = npost, seed = seed_chain, verbose = output_verbose,             printevery = printevery, chain_index = chain)    }, Spike_Laplace = {    }    watcher$capture_plot_and_output()    if (on_warning$capture) {        cnd <- sanitize_call(cnd)        watcher$push(cnd)    }    if (on_warning$silence) {        invokeRestart("muffleWarning")    }}, error = function (cnd) {    watcher$capture_plot_and_output()    cnd <- sanitize_call(cnd)    watcher$push(cnd)    switch(on_error, continue = invokeRestart("eval_continue"),         stop = invokeRestart("eval_stop"), error = NULL)})
29: eval(call)
30:         spike_laplace_partially_mcmc(X, Y, intercept = !standardize,             a = extra_parameters$a, b = extra_parameters$b, nburn = nburn,             npost = npost, seed = seed_chain, verbose = output_verbose,             printevery = printevery, chain_index = chain)    }))})
24: BMI_LASSO(data$data_MI$X, data$data_MI$Y, model = "Horseshoe",     nburn = 4000, npost = 4000, output_verbose = FALSE, nchains = 2,     ncores = 2, seed = seed)eval(call)
31: with_handlers({    for (expr in tle$exprs) {        ev <- withVisible(eval(expr, envir))        watcher$capture_plot_and_output()        watcher$print_value(ev$value, ev$visible, envir)
25: eval(expr, envir)
26:     }    TRUE}, handlers)
32: doWithOneRestart(return(expr), restart)
33: eval(expr, envir)
27: withVisible(eval(expr, envir))
withOneRestart(expr, restarts[[1L]])
34: withRestartList(expr, restarts[-nr])
35: doWithOneRestart(return(expr), restart)
28: withCallingHandlers(code, error = function (e) rlang::entrace(e), message = function (cnd) {    watcher$capture_plot_and_output()36: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
37: withRestartList(expr, restarts)    if (on_message$capture) {        watcher$push(cnd)    }    if (on_message$silence) {        invokeRestart("muffleMessage")
38: withRestarts(with_handlers({    for (expr in tle$exprs) {        ev <- withVisible(eval(expr, envir))        watcher$capture_plot_and_output()        watcher$print_value(ev$value, ev$visible, envir)    }    }}, warning = function (cnd) {    if (getOption("warn") >= 2 || getOption("warn") < 0) {        return()    TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
39: evaluate::evaluate(...)
40: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning,     keep_message = if (is.numeric(options$message)) TRUE else options$message,     }    watcher$capture_plot_and_output()    if (on_warning$capture) {        cnd <- sanitize_call(cnd)        watcher$push(cnd)    }    if (on_warning$silence) {        invokeRestart("muffleWarning")    }}, error = function (cnd) {    watcher$capture_plot_and_output()    stop_on_error = if (is.numeric(options$error)) options$error else {        if (options$error && options$include)             0L        else 2L    }, output_handler = knit_handlers(options$render, options))
41: in_dir(input_dir(), expr)
42:     cnd <- sanitize_call(cnd)    watcher$push(cnd)    switch(on_error, continue = invokeRestart("eval_continue"),         stop = invokeRestart("eval_stop"), error = NULL)})
29: eval(call)
30: eval(call)
31: with_handlers({    for (expr in tle$exprs) {        ev <- withVisible(eval(expr, envir))        watcher$capture_plot_and_output()        watcher$print_value(ev$value, ev$visible, envir)    }    TRUEin_input_dir(evaluate(code, envir = env, new_device = FALSE,     keep_warning = if (is.numeric(options$warning)) TRUE else options$warning,     keep_message = if (is.numeric(options$message)) TRUE else options$message,     stop_on_error = if (is.numeric(options$error)) options$error else {        if (options$error && options$include)             0L}, handlers)
32: doWithOneRestart(return(expr), restart)
33: withOneRestart(expr, restarts[[1L]])
34: withRestartList(expr, restarts[-nr])        else 2L    }, output_handler = knit_handlers(options$render, options)))
43: 
35: doWithOneRestart(return(expr), restart)
36: withOneRestart(withRestartList(expr, restarts[-nr]), restarts[[nr]])
37: eng_r(options)
44: block_exec(params)
45: call_block(x)withRestartList(expr, restarts)
38: withRestarts(with_handlers({    for (expr in tle$exprs) {        ev <- withVisible(eval(expr, envir))        watcher$capture_plot_and_output()        watcher$print_value(ev$value, ev$visible, envir)
46: process_group(group)
    }    TRUE}, handlers), eval_continue = function() TRUE, eval_stop = function() FALSE)
39: evaluate::evaluate(...)47: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group),     error = function(e) {        if (progress && is.function(pb$interrupt))             pb$interrupt()        if (is_R_CMD_build() || is_R_CMD_check())             error <<- format(e)
40: evaluate(code, envir = env, new_device = FALSE, keep_warning = if (is.numeric(options$warning)) TRUE else options$warning,     keep_message = if (is.numeric(options$message)) TRUE else options$message,     stop_on_error = if (is.numeric(options$error)) options$error else {    })
48: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group),     error = function(e) {        if (progress && is.function(pb$interrupt))             pb$interrupt()        if (is_R_CMD_build() || is_R_CMD_check())             error <<- format(e)        if (options$error && options$include)             0L        else 2L    }, output_handler = knit_handlers(options$render, options))
41: in_dir(input_dir(), expr)
    }), list(rlang_trace_top_env = knit_global()))
49: xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), 42: in_input_dir(evaluate(code, envir = env, new_device = FALSE,     keep_warning = if (is.numeric(options$warning)) TRUE else options$warning,     keep_message = if (is.numeric(options$message)) TRUE else options$message,     error = function(e) {        if (progress && is.function(pb$interrupt))             pb$interrupt()        if (is_R_CMD_build() || is_R_CMD_check())     stop_on_error = if (is.numeric(options$error)) options$error else {        if (options$error && options$include)             0L        else 2L    }, output_handler = knit_handlers(options$render, options)))
            error <<- format(e)    }), list(rlang_trace_top_env = knit_global())), function(loc) {    setwd(wd)    write_utf8(res, output %n% stdout())    paste0("\nQuitting from ", loc, if (!is.null(error)) 43: eng_r(options)
44: block_exec(params)
45: call_block(x)
46:         paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
50: process_file(text, output)
51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)process_group(group)
47: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), 
52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(),     output_dir = getwd(), ...)
53: vweave_rmarkdown(...)
54: engine$weave(file, quiet = quiet, encoding = enc)
55:     error = function(e) {        if (progress && is.function(pb$interrupt))             pb$interrupt()        if (is_R_CMD_build() || is_R_CMD_check())             error <<- format(e)doTryCatch(return(expr), name, parentenv, handler)
56: tryCatchOne(expr, names, parentenv, handlers[[1L]])
    })
48: with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group),     error = function(e) {        if (progress && is.function(pb$interrupt))             pb$interrupt()        if (is_R_CMD_build() || is_R_CMD_check()) 57: tryCatchList(expr, classes, parentenv, handlers)
58: tryCatch({    engine$weave(file, quiet = quiet, encoding = enc)    setwd(startdir)    output <- find_vignette_product(name, by = "weave", engine = engine)            error <<- format(e)    }), list(rlang_trace_top_env = knit_global()))
49:     if (!have.makefile && vignette_is_tex(output)) {        texi2pdf(file = output, clean = FALSE, quiet = quiet)        output <- find_vignette_product(name, by = "texi2pdf",             engine = engine)    }    outputs <- c(outputs, output)xfun:::handle_error(with_options(withCallingHandlers(if (tangle) process_tangle(group) else process_group(group),     error = function(e) {        if (progress && is.function(pb$interrupt))             pb$interrupt()        if (is_R_CMD_build() || is_R_CMD_check())             error <<- format(e)    }), list(rlang_trace_top_env = knit_global())), function(loc) {    setwd(wd)}, error = function(e) {    thisOK <<- FALSE    fails <<- c(fails, file)    message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s",         file, conditionMessage(e)))})
59:     write_utf8(res, output %n% stdout())    paste0("\nQuitting from ", loc, if (!is.null(error))         paste0("\n", rule(), error, "\n", rule()))}, if (labels[i] != "") sprintf(" [%s]", labels[i]), get_loc)
50: process_file(text, output)
tools::buildVignettes(dir = "/Volumes/Builds/packages/big-sur-arm64/results/4.5/BMIselect.Rcheck/vign_test/BMIselect",     skip = TRUE, ser_elibs = "/Volumes/Temp/tmp/Rtmp8H9vTc/filee57c4e480192.rds")
An irrecoverable exception occurred. R is aborting now ...
51: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet)
52: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(),     output_dir = getwd(), ...)
53: vweave_rmarkdown(...)
54: engine$weave(file, quiet = quiet, encoding = enc)
55: doTryCatch(return(expr), name, parentenv, handler)
56: tryCatchOne(expr, names, parentenv, handlers[[1L]])
57: tryCatchList(expr, classes, parentenv, handlers)
58: tryCatch({    engine$weave(file, quiet = quiet, encoding = enc)    setwd(startdir)    output <- find_vignette_product(name, by = "weave", engine = engine)    if (!have.makefile && vignette_is_tex(output)) {        texi2pdf(file = output, clean = FALSE, quiet = quiet)        output <- find_vignette_product(name, by = "texi2pdf",             engine = engine)    }    outputs <- c(outputs, output)}, error = function(e) {    thisOK <<- FALSE    fails <<- c(fails, file)    message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s",         file, conditionMessage(e)))})
59: tools::buildVignettes(dir = "/Volumes/Builds/packages/big-sur-arm64/results/4.5/BMIselect.Rcheck/vign_test/BMIselect",     skip = TRUE, ser_elibs = "/Volumes/Temp/tmp/Rtmp8H9vTc/filee57c4e480192.rds")
An irrecoverable exception occurred. R is aborting now ...

Quitting from Introduction.Rmd:164-179 [unnamed-chunk-6]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
<error/rlang_error>
Error in `apply()`:
! dim(X) must have a positive length
---
Backtrace:
    ▆
 1. └─BMIselect::BMI_LASSO(...)
 2.   └─base::lapply(...)
 3.     └─BMIselect (local) FUN(X[[i]], ...)
 4.       └─base::apply(c$post_pool_beta, 2, function(x) mean(abs(x) <= sqrt(stats::var(x))))
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Error: processing vignette 'Introduction.Rmd' failed with diagnostics:
dim(X) must have a positive length
--- failed re-building ‘Introduction.Rmd’

SUMMARY: processing the following file failed:
  ‘Introduction.Rmd’

Error: Vignette re-building failed.
Execution halted