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

> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: gen.variogram
> ### Title: Semi-variogram with the genetic distance matrix
> ### Aliases: gen.variogram
> ### Keywords: variogram kriging
> 
> ### ** Examples
> 
> 
>     data(vipers)
>     data(d.gen)
> 
>     # create a distance matrix between samples
>     r.dist <- dist(vipers[,1:2])
> 
>     # variogram table with semi-variance and lag centers
>     gv <- gen.variogram(r.dist, d.gen)
 ----------- FAILURE REPORT -------------- 
 --- failure: the condition has length > 1 ---
 --- srcref --- 
: 
 --- package (from environment) --- 
phylin
 --- call from context --- 
gen.variogram(r.dist, d.gen)
 --- call from argument --- 
if (class(y) == "list") {
    multi <- TRUE
    for (i in 1:length(y)) {
        if (!(class(y[[i]]) == "dist")) 
            y[[i]] <- as.dist(y[[i]])
        if (!all(dim(y[[i]]) == dim(x))) 
            stop("Dimensions of x and y do not match.")
    }
} else {
    if (!(class(y) == "dist")) 
        y <- as.dist(y)
    if (!all(dim(y) == dim(x))) 
        stop("Dimensions of x and y do not match.")
}
 --- R stacktrace ---
where 1: gen.variogram(r.dist, d.gen)

 --- value of length: 2 type: logical ---
[1] FALSE FALSE
 --- function from context --- 
function (x, y, lag = quantile(as.matrix(x), 0.05), tol = lag/2, 
    lmax = NA, bootstraps = 999, verbose = FALSE) 
{
    if (!(class(x) == "dist")) 
        x <- as.dist(x)
    multi <- FALSE
    if (class(y) == "list") {
        multi <- TRUE
        for (i in 1:length(y)) {
            if (!(class(y[[i]]) == "dist")) 
                y[[i]] <- as.dist(y[[i]])
            if (!all(dim(y[[i]]) == dim(x))) 
                stop("Dimensions of x and y do not match.")
        }
    }
    else {
        if (!(class(y) == "dist")) 
            y <- as.dist(y)
        if (!all(dim(y) == dim(x))) 
            stop("Dimensions of x and y do not match.")
    }
    if (multi) {
        gv <- .gen.variogram.multi(x, y, lag = lag, tol = tol, 
            lmax = lmax, bootstraps = bootstraps, verbose = verbose)
    }
    else {
        gv <- .gen.variogram.single(x, y, lag = lag, tol = tol, 
            lmax = lmax)
    }
    if (sum(is.na(gv$gamma)) > 0) {
        warning("The variogram contains NAs.", "Consider adjusting the lag.")
    }
    gv
}
<bytecode: 0x23207b0>
<environment: namespace:phylin>
 --- function search by body ---
Function gen.variogram in namespace phylin has this body.
 ----------- END OF FAILURE REPORT -------------- 
Error in if (class(y) == "list") { : the condition has length > 1
Calls: gen.variogram
Execution halted