Error(s) in re-building vignettes:
  ...
--- re-building 'EMVS_vignette.Rnw' using knitr
 ----------- FAILURE REPORT -------------- 
 --- failure: the condition has length > 1 ---
 --- srcref --- 
: 
 --- package (from environment) --- 
EMVS
 --- call from context --- 
EMVS(Y = Y, X = X, v0 = v0, v1 = v1, type = "betabinomial", independent = TRUE, 
    beta_init = beta_init, sigma_init = sigma_init, a = a, b = b, 
    log_v0 = TRUE)
 --- call from argument --- 
if (class(X) != "matrix") {
    tmp <- try(X <- model.matrix(~0 + ., data = X), silent = TRUE)
    if (class(tmp)[1] == "try-error") 
        stop("X must be a matrix or able to be coerced to a matrix")
}
 --- R stacktrace ---
where 1: EMVS(Y = Y, X = X, v0 = v0, v1 = v1, type = "betabinomial", independent = TRUE, 
    beta_init = beta_init, sigma_init = sigma_init, a = a, b = b, 
    log_v0 = TRUE)
where 2: eval(expr, envir, enclos)
where 3: eval(expr, envir, enclos)
where 4: withVisible(eval(expr, envir, enclos))
where 5: withCallingHandlers(withVisible(eval(expr, envir, enclos)), warning = wHandler, 
    error = eHandler, message = mHandler)
where 6: handle(ev <- withCallingHandlers(withVisible(eval(expr, envir, 
    enclos)), warning = wHandler, error = eHandler, message = mHandler))
where 7: timing_fn(handle(ev <- withCallingHandlers(withVisible(eval(expr, 
    envir, enclos)), warning = wHandler, error = eHandler, message = mHandler)))
where 8: evaluate_call(expr, parsed$src[[i]], envir = envir, enclos = enclos, 
    debug = debug, last = i == length(out), use_try = stop_on_error != 
        2L, keep_warning = keep_warning, keep_message = keep_message, 
    output_handler = output_handler, include_timing = include_timing)
where 9: evaluate::evaluate(...)
where 10: evaluate(code, envir = env, new_device = FALSE, keep_warning = !isFALSE(options$warning), 
    keep_message = !isFALSE(options$message), stop_on_error = if (options$error && 
        options$include) 0L else 2L, output_handler = knit_handlers(options$render, 
        options))
where 11: in_dir(input_dir(), evaluate(code, envir = env, new_device = FALSE, 
    keep_warning = !isFALSE(options$warning), keep_message = !isFALSE(options$message), 
    stop_on_error = if (options$error && options$include) 0L else 2L, 
    output_handler = knit_handlers(options$render, options)))
where 12: block_exec(params)
where 13: call_block(x)
where 14: process_group.block(group)
where 15: process_group(group)
where 16: withCallingHandlers(if (tangle) process_tangle(group) else process_group(group), 
    error = function(e) {
        setwd(wd)
        cat(res, sep = "\n", file = output %n% "")
        message("Quitting from lines ", paste(current_lines(i), 
            collapse = "-"), " (", knit_concord$get("infile"), 
            ") ")
    })
where 17: process_file(text, output)
where 18: (if (grepl("\\.[Rr]md$", file)) knit2html_v1 else if (grepl("\\.[Rr]rst$", 
    file)) knit2pandoc else knit)(file, encoding = encoding, 
    quiet = quiet, envir = globalenv(), ...)
where 19: engine$weave(file, quiet = quiet, encoding = enc)
where 20: doTryCatch(return(expr), name, parentenv, handler)
where 21: tryCatchOne(expr, names, parentenv, handlers[[1L]])
where 22: tryCatchList(expr, classes, parentenv, handlers)
where 23: 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)))
})
where 24: tools:::buildVignettes(dir = "/home/hornik/tmp/R.check/r-devel-clang/Work/PKGS/EMVS.Rcheck/vign_test/EMVS", 
    ser_elibs = "/tmp/RtmpW9tv1S/filecfcb141820.rds")

 --- value of length: 2 type: logical ---
[1] FALSE  TRUE
 --- function from context --- 
function (Y, X, v0, v1, type = c("betabinomial", "fixed"), independent = TRUE, 
    beta_init, sigma_init = 1, epsilon = 10^(-5), temperature, 
    theta = 0.5, a = 1, b = 1, v1_g, direction = c("backward", 
        "forward", "null"), standardize = TRUE, log_v0 = FALSE) 
{
    type <- match.arg(type)
    direction <- match.arg(direction)
    if (missing(beta_init)) 
        beta_init = numeric(ncol(X))
    if (missing(v1_g)) {
        v1_g = v1
    }
    if (missing(temperature)) {
        temperature = 1
    }
    else {
        temperature = 1/temperature
    }
    if (class(Y) != "numeric") {
        tmp <- try(Y <- as.numeric(Y), silent = TRUE)
        if (class(tmp)[1] == "try-error") 
            stop("Y must numeric or able to be coerced to numeric")
    }
    if (class(X) != "matrix") {
        tmp <- try(X <- model.matrix(~0 + ., data = X), silent = TRUE)
        if (class(tmp)[1] == "try-error") 
            stop("X must be a matrix or able to be coerced to a matrix")
    }
    if (any(is.na(Y)) | any(is.na(X))) 
        stop("Missing data (NA's) detected.  Take actions (e.g., removing cases, removing features, imputation) to eliminate missing data before passing Y and X to EMVS")
    if (is.unsorted(v0)) 
        stop("Ladder of v0 values must be increasing")
    if (sum(v1 < v0) > 0) 
        stop("v1 has to be larger than v0")
    if (class(beta_init) != "numeric") {
        tmp <- try(beta_init <- as.numeric(beta_init), silent = TRUE)
        if (class(tmp)[1] == "try-error") 
            stop("beta_init must numeric or able to be coerced to numeric")
    }
    if (length(beta_init) != ncol(X)) 
        stop("beta_init has to be of length ncol(X)")
    if (length(a) > 1) 
        stop("a has to be a scalar")
    if (length(b) > 1) 
        stop("b has to be a scalar")
    if (length(v1) > 1) 
        stop("v1 has to be a scalar")
    if (length(theta) > 1) 
        stop("theta has to be a scalar")
    if (length(v1_g) > 1) 
        stop("v1_g has to be a scalar")
    if (length(sigma_init) > 1) 
        stop("sigma_init has to be a scalar")
    if (length(temperature) > 1) 
        stop("temperature has to be a scalar")
    if (standardize) {
        XX <- t(X)
        center <- apply(XX, 1, mean)
        XX <- XX - center
        scale <- sqrt(apply(XX, 1, function(x) sum(x^2))/nrow(X))
        XX <- 1/scale * XX
        XX <- t(XX)
        nz <- which(scale > 1e-06)
        if (length(nz) != ncol(XX)) 
            XX <- XX[, nz, drop = FALSE]
    }
    else {
        XX <- X
    }
    p <- ncol(XX)
    YY <- Y - mean(Y)
    n <- nrow(XX)
    if (n != length(Y)) 
        stop("length of Y has to be nrow(X)")
    if (independent == T) {
        res <- .ind_EMVS(YY, XX, v0, v1, type, beta_init, sigma_init, 
            epsilon, temperature, theta, a, b, direction)
    }
    else {
        res <- .conj_EMVS(YY, XX, v0, v1, type, beta_init, sigma_init, 
            epsilon, temperature, theta, a, b, v1_g, direction)
    }
    if (standardize) {
        betas <- res$betas
        betas <- t(res$betas)
        bbb <- betas/scale[nz]
        res$betas <- t(bbb)
    }
    if (independent == T) {
        res$independent = T
    }
    else {
        res$independent = F
    }
    if (log_v0 == T) {
        res$log_v0 = T
    }
    else {
        res$log_v0 = F
    }
    return(res)
}
<bytecode: 0x3366be8>
<environment: namespace:EMVS>
 --- function search by body ---
Function EMVS in namespace EMVS has this body.
 ----------- END OF FAILURE REPORT -------------- 
Fatal error: the condition has length > 1