Running examples in 'caMST-Ex.R' failed
The error most likely occurred in:

> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: transition_matrix_plot
> ### Title: Transition Matrix Plot
> ### Aliases: transition_matrix_plot
> 
> ### ** Examples
> 
> # Create a plot for a multistage test with a 1-3-3 design
> data('example_transition_matrix')
> transition_matrix_plot(example_transition_matrix, n_stages =  3)
 ----------- FAILURE REPORT -------------- 
 --- failure: the condition has length > 1 ---
 --- srcref --- 
: 
 --- package (from environment) --- 
caMST
 --- call from context --- 
transition_matrix_plot(example_transition_matrix, n_stages = 3)
 --- call from argument --- 
if (!is.null(object) & (class(object) == "MST" | class(object) == 
    "MAT")) {
    transition_matrix = object@transition.matrix
    n_stages = object@n.stages
} else {
    transition_matrix = object
}
 --- R stacktrace ---
where 1: transition_matrix_plot(example_transition_matrix, n_stages = 3)

 --- value of length: 2 type: logical ---
[1] FALSE FALSE
 --- function from context --- 
function (object = NULL, n_stages = NULL) 
{
    if (!is.null(object) & (class(object) == "MST" | class(object) == 
        "MAT")) {
        transition_matrix = object@transition.matrix
        n_stages = object@n.stages
    }
    else {
        transition_matrix = object
    }
    modules_each_stage = vector("list", length = n_stages)
    modules_each_stage[[1]] = which(colSums(transition_matrix) == 
        0)
    for (i in 2:n_stages) {
        if (is.matrix(transition_matrix[modules_each_stage[[i - 
            1]], ])) {
            modules_each_stage[[i]] = which(colSums(transition_matrix[modules_each_stage[[i - 
                1]], ]) > 0)
        }
        else {
            modules_each_stage[[i]] = which(transition_matrix[modules_each_stage[[i - 
                1]], ] > 0)
        }
    }
    n_each_stage = sapply(modules_each_stage, length)
    source = rep(1:nrow(transition_matrix), times = rowSums(transition_matrix))
    target = vector(length = 0)
    for (i in 1:nrow(transition_matrix)) {
        target = c(target, which(transition_matrix[i, ] == 1))
    }
    paths = data.frame(cbind(source, target))
    diagram::openplotmat()
    pos = diagram::coordinates(n_each_stage)
    for (i in 1:nrow(paths)) {
        diagram::splitarrow(from = pos[paths[i, 1], ], to = pos[paths[i, 
            2], ], endhead = T, dd = 0.55, arr.type = "triangle")
    }
    for (i in 1:nrow(pos)) {
        diagram::textrect(mid = pos[i, ], radx = 0.1, rady = 0.05, 
            cex = 1, lab = paste0("Module ", i), box.col = "#EEEEEE")
    }
}
<bytecode: 0x226f6c0>
<environment: namespace:caMST>
 --- function search by body ---
Function transition_matrix_plot in namespace caMST has this body.
 ----------- END OF FAILURE REPORT -------------- 
Fatal error: the condition has length > 1