R/weighted.residuals.manylm.R

weighted.residuals.manylm <- function(obj, drop0 = TRUE){
    w <- weights(obj)
    r <- as.matrix(residuals(obj, type = "deviance"))
    if (drop0 && !is.null(w)) 
        r[w != 0,,drop=FALSE]
    else r

}

#setMethod("weighted.residuals", "manylm", weighted.residuals.manylm)
eddelbuettel/mvabund-tests documentation built on May 15, 2019, 10:30 p.m.