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

> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: nd.centrality
> ### Title: Centrality Distance
> ### Aliases: nd.centrality
> 
> ### ** Examples
> 
> ## generate two types of adjacency matrices of size (3-by-3)
> rbin1 = rbinom(9,1,0.8); mat1 = matrix(rbin1,nrow=3)
> rbin2 = rbinom(9,1,0.2); mat2 = matrix(rbin2,nrow=3)
> 
> mattype1 = ceiling((mat1+t(mat1))/2); diag(mattype1)=0;
> mattype2 = ceiling((mat2+t(mat2))/2); diag(mattype2)=0;
> 
> A = list()
> for (i in 1:3){A[[i]]=mattype1} # first 3 are type-1
> for (i in 4:6){A[[i]]=mattype2} # next  3 are type-2
> 
> ## use 3 types of centrality measures
> out1 <- nd.centrality(A,out.dist=FALSE,mode="Degree")
 ----------- FAILURE REPORT -------------- 
 --- failure: the condition has length > 1 ---
 --- srcref --- 
: 
 --- package (from environment) --- 
NetworkDistance
 --- call from context --- 
graph_transform(A[[i]], NIs = NIflag)
 --- call from argument --- 
if (class(obj) == "igraph") {
    output = as_adjacency_matrix(obj)
} else if (class(obj) == "network") {
    output = Matrix(as.matrix.network(obj, matrix.type = "adjacency"), 
        sparse = TRUE)
} else {
    output = Matrix(obj, sparse = TRUE)
}
 --- R stacktrace ---
where 1: graph_transform(A[[i]], NIs = NIflag)
where 2: list_transform(A, NIflag = "not")
where 3: nd.centrality(A, out.dist = FALSE, mode = "Degree")

 --- value of length: 2 type: logical ---
[1] FALSE FALSE
 --- function from context --- 
function (obj, NIs = "allowed") 
{
    if (class(obj) == "igraph") {
        output = as_adjacency_matrix(obj)
    }
    else if (class(obj) == "network") {
        output = Matrix(as.matrix.network(obj, matrix.type = "adjacency"), 
            sparse = TRUE)
    }
    else {
        output = Matrix(obj, sparse = TRUE)
    }
    if (NIs != "allowed") {
        if ((any(is.na(output))) || (any(is.infinite(output)))) {
            stop("* NetworkDistance : inputs of NA, Inf, or -Inf are not allowed.")
        }
    }
    return(output)
}
<bytecode: 0x9603818>
<environment: namespace:NetworkDistance>
 --- function search by body ---
Function graph_transform in namespace NetworkDistance has this body.
 ----------- END OF FAILURE REPORT -------------- 
Fatal error: the condition has length > 1