Running examples in ‘ctl-Ex.R’ failed
The error most likely occurred in:

> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: ctl.lineplot
> ### Title: Lineplot CTL on multiple traits
> ### Aliases: ctl.lineplot
> ### Keywords: hplot
> 
> ### ** Examples
> 
>   require(ctl)
>   data(ath.result)       # Arabidopsis Thaliana results
>   data(ath.metabolites)  # Arabidopsis Thaliana data set
> 
>   todo <- c(1,3,4,5,6,8,9,10,11,12,14,17,18,19,22,23)
>   op   <- par(mfrow = c(4,4))
>   op   <- par(oma = c(0.1,0.1,0.1,0.1))
>   op   <- par(mai = c(0.1,0.1,0.1,0.1))
>   for(x in todo){ # Overview of the 16 traits with CTLs
+     ctl.lineplot(ath.result, ath.metab$map, phenocol = x, sign=0.1)
+   }
p_above= 2 
p_above= 2 
p_above= 0 
p_above= 0 
p_above= 4 
p_above= 4 
p_above= 4 
p_above= 4 
p_above= 3 
p_above= 3 
p_above= 3 
p_above= 3 
p_above= 0 
p_above= 0 
p_above= 6 
p_above= 6 
p_above= 1 
p_above= 1 
p_above= 1 
p_above= 1 
p_above= 6 
p_above= 6 
p_above= 3 
p_above= 3 
p_above= 1 
p_above= 1 
p_above= 2 
p_above= 2 
p_above= 0 
p_above= 0 
p_above= 0 
p_above= 0 
p_above= 4 
p_above= 4 
p_above= 7 
p_above= 7 
p_above= 1 
p_above= 1 
p_above= 0 
p_above= 0 
p_above= 0 
p_above= 0 
p_above= 3 
p_above= 3 
p_above= 3 
p_above= 3 
p_above= 0 
p_above= 0 
Found 119 significant CTLs
 ----------- FAILURE REPORT -------------- 
 --- failure: the condition has length > 1 ---
 --- srcref --- 
: 
 --- package (from environment) --- 
ctl
 --- call from context --- 
ctl.lineplot(ath.result, ath.metab$map, phenocol = x, sign = 0.1)
 --- call from argument --- 
if (class(ctls) == "numeric") ctls <- t(ctls)
 --- R stacktrace ---
where 1: ctl.lineplot(ath.result, ath.metab$map, phenocol = x, sign = 0.1)

 --- value of length: 2 type: logical ---
[1] FALSE FALSE
 --- function from context --- 
function (CTLobject, mapinfo, phenocol, significance = 0.05, 
    gap = 50, col = "orange", bg.col = "lightgray", cex = 1, 
    verbose = FALSE) 
{
    if (missing(CTLobject) || is.null(CTLobject)) 
        stop("argument 'CTLobject' is missing, with no default")
    if (missing(phenocol)) 
        phenocol <- 1:length(CTLobject)
    n.markers <- nrow(CTLobject[[1]]$ctl)
    ctls <- CTLnetwork(CTLobject, mapinfo, significance, verbose = verbose)
    CTLobject <- CTLobject[phenocol]
    ctls <- ctls[which(ctls[, 1] %in% phenocol), ]
    if (class(ctls) == "numeric") 
        ctls <- t(ctls)
    if (is.null(ctls) || nrow(ctls) < 1) {
        warning(paste("No ctls edges found at significance <", 
            significance))
        plot(c(-1, 1), c(-1, 1), t = "n", axes = FALSE, xlab = "", 
            ylab = "")
        box()
        return()
    }
    markerlocs <- cbind(seq(1, n.markers), rep(0, n.markers))
    total.l <- n.markers
    if (!missing(mapinfo)) {
        markerlocs <- mapinfotomarkerlocs(mapinfo, gap, "line")
        total.l <- max(markerlocs[, 1])
    }
    xdim <- c(min(markerlocs[, 1]), max(markerlocs[, 1]))
    fromlocs <- total.l/(length(nfrom(ctls)) + 1)
    tolocs <- total.l/(length(nto(ctls)) + 1)
    plot(xdim, c(-1.1, 1.1), t = "n", axes = FALSE, xlab = "", 
        ylab = "")
    points(markerlocs, pch = 20, cex = (cex/2))
    for (x in 1:nrow(ctls)) {
        from <- c(which(nfrom(ctls) %in% ctls[x, 1]) * fromlocs, 
            0.6)
        to <- c(which(nto(ctls) %in% ctls[x, 3]) * tolocs, -0.6)
        via <- c(markerlocs[ctls[x, 2]], 0)
        if (!is.na(ctls[x, 5])) {
            draw.spline(from, to, via, lwd = (ctls[x, 4]/5) + 
                1, lty = c(1, 2, 3)[ctls[x, 5] + 2], col = col)
        }
        else {
            cat(paste("Direction of CTL unknown, NA detected:", 
                from[1], via[1], to[1], "\n"))
            draw.spline(from, to, via, lwd = (ctls[x, 4]/5) + 
                1, lty = 2, col = col)
        }
    }
    for (x in 1:length(nfrom(ctls))) {
        px <- which(nfrom(ctls) %in% nfrom(ctls)[x]) * fromlocs
        draw.element(px, 0.6, nfrom(ctls)[x], cex = cex, bg.col = bg.col)
    }
    for (x in 1:length(nto(ctls))) {
        px <- which(nto(ctls) %in% nto(ctls)[x]) * tolocs
        draw.element(px, -0.6, nto(ctls)[x], cex = cex, bg.col = bg.col)
    }
    box()
    invisible(ctls)
}
<bytecode: 0x560389adf9f0>
<environment: namespace:ctl>
 --- function search by body ---
Function ctl.lineplot in namespace ctl has this body.
 ----------- END OF FAILURE REPORT -------------- 
Fatal error: the condition has length > 1