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

--- re-building ‘model-comparison.Rmd’ using rmarkdown
--- finished re-building ‘model-comparison.Rmd’

--- re-building ‘run-conStruct.Rmd’ using rmarkdown
 ----------- FAILURE REPORT -------------- 
 --- failure: the condition has length > 1 ---
 --- srcref --- 
: 
 --- package (from environment) --- 
conStruct
 --- call from context --- 
conStruct::make.structure.plot(w)
 --- call from argument --- 
if (class(admix.proportions) != "matrix") {
    stop("\nyou must specify a matrix of admixture proportions\n")
}
 --- R stacktrace ---
where 1: conStruct::make.structure.plot(w)
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: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet, 
    encoding = encoding)
where 19: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), 
    ...)
where 20: vweave_rmarkdown(...)
where 21: engine$weave(file, quiet = quiet, encoding = enc)
where 22: doTryCatch(return(expr), name, parentenv, handler)
where 23: tryCatchOne(expr, names, parentenv, handlers[[1L]])
where 24: tryCatchList(expr, classes, parentenv, handlers)
where 25: 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)
    }
}, error = function(e) {
    OK <<- FALSE
    message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", 
        file, conditionMessage(e)))
})
where 26: tools:::.buildOneVignette("run-conStruct.Rmd", "/home/hornik/tmp/R.check/r-devel-gcc/Work/PKGS/conStruct.Rcheck/vign_test/conStruct", 
    TRUE, FALSE, "run-conStruct", "UTF-8", "/home/hornik/tmp/scratch/RtmpPDyfPd/file3e592b34bec0.rds")

 --- value of length: 2 type: logical ---
[1] FALSE  TRUE
 --- function from context --- 
function (admix.proportions, mar = c(2, 4, 2, 2), sample.order = NULL, 
    layer.order = NULL, sample.names = NULL, sort.by = NULL, 
    layer.colors = NULL) 
{
    if (class(admix.proportions) != "matrix") {
        stop("\nyou must specify a matrix of admixture proportions\n")
    }
    K <- ncol(admix.proportions)
    N <- nrow(admix.proportions)
    graphics::par(mar = mar)
    if (is.null(layer.order)) {
        layer.order <- seq(1:K)
    }
    if (is.null(sample.order)) {
        sample.order <- seq(1:N)
    }
    if (!is.null(sort.by)) {
        if (sort.by > K) {
            stop("\nyou must specify a layer that exists in your data\n")
        }
        sample.order <- order(admix.proportions[, sort.by])
    }
    if (is.null(layer.colors)) {
        layer.colors <- c("blue", "red", "goldenrod1", "forestgreen", 
            "darkorchid1", "deepskyblue", "darkorange1", "seagreen2", 
            "yellow1", "black")
    }
    else {
        if (K > length(layer.colors)) {
            stop("\nyou must specify one color per layer\n")
        }
    }
    use.colors <- layer.colors[1:K][layer.order]
    graphics::plot(0, xlim = c(0, N), ylim = c(0, 1), type = "n", 
        ylab = "admixture", xlab = "", xaxt = "n")
    plotting.admix.props <- apply(cbind(0, admix.proportions[, 
        layer.order]), 1, cumsum)
    lapply(1:K, function(i) {
        make.structure.polygon.layer(plotting.admix.props, i, 
            use.colors, sample.order)
    })
    if (!is.null(sample.names)) {
        graphics::axis(side = 1, at = seq(1:N) - 0.5, labels = sample.names[sample.order], 
            cex.axis = 0.5, las = 2)
    }
    return(invisible("plotted"))
}
<bytecode: 0x55d016d0bae8>
<environment: namespace:conStruct>
 --- function search by body ---
Function make.structure.plot in namespace conStruct has this body.
 ----------- END OF FAILURE REPORT -------------- 
Fatal error: the condition has length > 1
--- re-building ‘visualize-results.Rmd’ using rmarkdown
 ----------- FAILURE REPORT -------------- 
 --- failure: the condition has length > 1 ---
 --- srcref --- 
: 
 --- package (from environment) --- 
conStruct
 --- call from context --- 
make.structure.plot(admix.proportions = admix.props)
 --- call from argument --- 
if (class(admix.proportions) != "matrix") {
    stop("\nyou must specify a matrix of admixture proportions\n")
}
 --- R stacktrace ---
where 1: make.structure.plot(admix.proportions = admix.props)
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: knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet, 
    encoding = encoding)
where 19: rmarkdown::render(file, encoding = encoding, quiet = quiet, envir = globalenv(), 
    ...)
where 20: vweave_rmarkdown(...)
where 21: engine$weave(file, quiet = quiet, encoding = enc)
where 22: doTryCatch(return(expr), name, parentenv, handler)
where 23: tryCatchOne(expr, names, parentenv, handlers[[1L]])
where 24: tryCatchList(expr, classes, parentenv, handlers)
where 25: 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)
    }
}, error = function(e) {
    OK <<- FALSE
    message(gettextf("Error: processing vignette '%s' failed with diagnostics:\n%s", 
        file, conditionMessage(e)))
})
where 26: tools:::.buildOneVignette("visualize-results.Rmd", "/home/hornik/tmp/R.check/r-devel-gcc/Work/PKGS/conStruct.Rcheck/vign_test/conStruct", 
    TRUE, FALSE, "visualize-results", "UTF-8", "/home/hornik/tmp/scratch/RtmpPDyfPd/file3e592af6fb81.rds")

 --- value of length: 2 type: logical ---
[1] FALSE  TRUE
 --- function from context --- 
function (admix.proportions, mar = c(2, 4, 2, 2), sample.order = NULL, 
    layer.order = NULL, sample.names = NULL, sort.by = NULL, 
    layer.colors = NULL) 
{
    if (class(admix.proportions) != "matrix") {
        stop("\nyou must specify a matrix of admixture proportions\n")
    }
    K <- ncol(admix.proportions)
    N <- nrow(admix.proportions)
    graphics::par(mar = mar)
    if (is.null(layer.order)) {
        layer.order <- seq(1:K)
    }
    if (is.null(sample.order)) {
        sample.order <- seq(1:N)
    }
    if (!is.null(sort.by)) {
        if (sort.by > K) {
            stop("\nyou must specify a layer that exists in your data\n")
        }
        sample.order <- order(admix.proportions[, sort.by])
    }
    if (is.null(layer.colors)) {
        layer.colors <- c("blue", "red", "goldenrod1", "forestgreen", 
            "darkorchid1", "deepskyblue", "darkorange1", "seagreen2", 
            "yellow1", "black")
    }
    else {
        if (K > length(layer.colors)) {
            stop("\nyou must specify one color per layer\n")
        }
    }
    use.colors <- layer.colors[1:K][layer.order]
    graphics::plot(0, xlim = c(0, N), ylim = c(0, 1), type = "n", 
        ylab = "admixture", xlab = "", xaxt = "n")
    plotting.admix.props <- apply(cbind(0, admix.proportions[, 
        layer.order]), 1, cumsum)
    lapply(1:K, function(i) {
        make.structure.polygon.layer(plotting.admix.props, i, 
            use.colors, sample.order)
    })
    if (!is.null(sample.names)) {
        graphics::axis(side = 1, at = seq(1:N) - 0.5, labels = sample.names[sample.order], 
            cex.axis = 0.5, las = 2)
    }
    return(invisible("plotted"))
}
<bytecode: 0x5611013e3428>
<environment: namespace:conStruct>
 --- function search by body ---
Function make.structure.plot in namespace conStruct has this body.
 ----------- END OF FAILURE REPORT -------------- 
Fatal error: the condition has length > 1
SUMMARY: processing the following files failed:
  ‘run-conStruct.Rmd’ ‘visualize-results.Rmd’

Error: Vignette re-building failed.
Execution halted