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

> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: QICD
> ### Title: Penalized Quantile Regression with QICD Algorithm
> ### Aliases: QICD
> 
> ### ** Examples
> 
> n = 50
> p = 5
> x <- matrix(rnorm(n*p),nrow=n)
> y <- 0 + x[,1] - 3*x[,5] + rnorm(n)
> fit1 <- QICD(y,x, tau=.5, lambda=1, intercept=TRUE, penalty="SCAD")
 ----------- FAILURE REPORT -------------- 
 --- failure: the condition has length > 1 ---
 --- srcref --- 
: 
 --- package (from environment) --- 
rqPen
 --- call from context --- 
cleanInputs(y, x, lambda, initial_beta, intercept, penalty, a)
 --- call from argument --- 
if (class(x) != "matrix") {
    stop("x needs to be a matrix")
}
 --- R stacktrace ---
where 1: cleanInputs(y, x, lambda, initial_beta, intercept, penalty, a)
where 2: QICD(y, x, tau = 0.5, lambda = 1, intercept = TRUE, penalty = "SCAD")

 --- value of length: 2 type: logical ---
[1] FALSE  TRUE
 --- function from context --- 
function (y, x, lambda, initial_beta = NULL, intercept = TRUE, 
    penalty, a, ...) 
{
    if (class(x) != "matrix") {
        stop("x needs to be a matrix")
    }
    if (any(lambda <= 0)) {
        stop("lambda must be positive")
    }
    if (nrow(x) != length(y)) {
        stop("length of y and rows of x do not match")
    }
    if (!is.null(initial_beta) & (length(initial_beta) < (ncol(x) + 
        intercept))) {
        stop("initial_beta must contain initial value for intercept (if TRUE) and each coefficient")
    }
    if (penalty == "SCAD") {
        if (a <= 2) 
            stop("a must be > 2 for SCAD penalty")
    }
    else if (penalty == "MCP") {
        if (a <= 1) 
            stop("a must be > 1 for MCP penalty")
    }
    else {
        if (penalty != "LASSO") 
            stop("wrong penalty function")
    }
    return(NULL)
}
<bytecode: 0xcb69118>
<environment: namespace:rqPen>
 --- function search by body ---
Function cleanInputs in namespace rqPen has this body.
 ----------- END OF FAILURE REPORT -------------- 
Error in if (class(x) != "matrix") { : the condition has length > 1
Calls: QICD -> cleanInputs
Execution halted