If you do this, there is a chance that this package will still fail to install. It has a lot of dependencies and you might need to install those manually; there is further information on the package GitHub repository and you should check that for the latest information. At the time of writing, you'll need to do the following two big steps. First, create the ipak function outlined here, then run the three different package installation steps with the ipak function:
ipak <- function(pkg, repository = c("CRAN", "Bioconductor", "github")) {
new.pkg <- pkg[!(pkg %in% installed.packages()[, "Package"])]
# new.pkg <- pkg
if (length(new.pkg)) {
if (repository == "CRAN") {
install.packages(new.pkg, dependencies = TRUE)
}
if (repository == "Bioconductor") {
if (strsplit(version[["version.string"]], " ")[[1]][3] > "3.5.0") {
if (!requireNamespace("BiocManager")) {
install.packages("BiocManager")
}
BiocManager::install(new.pkg, dependencies = TRUE, ask = FALSE)
}
if (strsplit(version[["version.string"]], " ")[[1]][3] < "3.5.0") {
source("https://bioconductor.org/biocLite.R")
biocLite(new.pkg, dependencies = TRUE, ask = FALSE)
}
}
if (repository == "github") {
devtools::install_github(new.pkg, build_vignettes = FALSE, force = FALSE,
dependencies = TRUE)
}
}
}
# CRAN PACKAGES
cranpackages <- c("broom", "cobs", "cowplot", "data.table", "devtools", "doParallel",
"dplyr", "drc", "DrImpute", "fastICA", "fitdistrplus", "foreach", "gamlss.dist",
"ggExtra", "ggplot2", "ggthemes", "grDevices", "glmnet", "grid", "gtools",
"Hmisc", "kernlab", "MASS", "MBESS", "matrixStats", "mclust", "methods",
"minpack.lm", "moments", "msir", "NBPSeq", "nonnest2", "parallel", "penalized",
"plyr", "pscl", "reshape2", "Rmagic", "rsvd", "Rtsne", "scales", "Seurat",
"snow", "stats", "tibble", "tidyr", "VGAM", "ZIM")
ipak(cranpackages, repository = "CRAN")
# BIOCONDUCTOR
biocpackages <- c("AnnotationDbi", "bayNorm", "baySeq", "Biobase", "BiocGenerics",
"BiocParallel", "DEDS", "DESeq2", "EBSeq", "edgeR", "IHW", "iCOBRA", "limma",
"Linnorm", "MAST", "monocle", "NOISeq", "qvalue", "ROTS", "RUVSeq", "S4Vectors",
"scater", "scDD", "scde", "scone", "scran", "SCnorm", "SingleCellExperiment",
"SummarizedExperiment", "zinbwave")
ipak(biocpackages, repository = "Bioconductor")
# GITHUB
githubpackages <- c("nghiavtr/BPSC", "cz-ye/DECENT", "mohuangx/SAVER", "statOmics/zingeR")
ipak(githubpackages, repository = "github")
When this is done, you should be able to install the package we're after with this code: