首页 技术 正文
技术 2022年11月7日
0 收藏 580 点赞 271 浏览 3177 个字
 options("repos" = c(CRAN="https://mirrors.tuna.tsinghua.edu.cn/CRAN/"))
if(! require("devtools")) install.packages("devtools")
if(! require("reshape2")) install.packages("reshape2")
if(! require("ggplot2")) install.packages("ggplot2")
if(! require("pheatmap")) install.packages("pheatmap")
if(! require("ggfortify")) install.packages("ggfortify")
if(! require("stringr")) install.packages("stringr")
if(! require("survival")) install.packages("survival")
if(! require("survminer")) install.packages("survminer")
if(! require("lars")) install.packages("lars")
if(! require("glmnet")) install.packages("glmnet") if(! require("timeROC")) install.packages("timeROC")
if(! require("ggpubr")) install.packages("ggpubr") if(! require("randomForest")) install.packages("randomForest")
if(! require("ROCR")) install.packages("ROCR")
if(! require("Hmisc")) install.packages("Hmisc") if(! require("caret")) install.packages("caret")
# if(! require("genefilter")) install.packages("genefilter")
if(! require("ggstatsplot")) install.packages("ggstatsplot") ### 下面的包是为了临床三线表
if(! require("tableone")) install.packages("tableone")
## 网络不好,就不要安装了。
## 而且Windows电脑安装 rJava 也经常是需要人指导的。
# https://github.com/rstudio/rstudio/issues/2254
if(! require("rJava")) install.packages("rJava")
if(require('rJava')){ # https://cran.r-project.org/src/contrib/Archive/ReporteRs/
if(! require("ReporteRs")) install.packages("ReporteRs")
devtools::install_github('davidgohel/ReporteRsjars')
devtools::install_github('davidgohel/ReporteRs')
} library(devtools)
source("http://bioconductor.org/biocLite.R")
## 如果你的网络实在是太差,试试看:
# install.packages("BiocInstaller",repos="http://bioconductor.org/packages/3.7/bioc")
## 很可惜你在中国大陆,不得不承受这个痛苦。 options(BioC_mirror="https://mirrors.ustc.edu.cn/bioc/")
library('BiocInstaller')
if(! require('edgeR')){ biocLite(c('airway','DESeq2','edgeR','limma'))
} if(! require("CLL")) biocLite("CLL")
if(! require("org.Hs.eg.db")) biocLite('org.Hs.eg.db')
library(BiocInstaller)
options(BioC_mirror="https://mirrors.ustc.edu.cn/bioc/")
if(! require("maftools")) biocLite("maftools")
if(! require("RTCGA")) biocLite("RTCGA")
if(! require("RTCGA.clinical")) biocLite("RTCGA.clinical")
# https://bioconductor.org/packages/3.6/data/experiment/src/contrib/RTCGA.clinical_20151101.8.0.tar.gzn
if(! require("RTCGA.miRNASeq")) biocLite("RTCGA.miRNASeq")
if(! require("maftools")) biocLite("maftools")
if(! require("genefilter")) biocLite("genefilter") # Then from : https://github.com/ShixiangWang
# You don't need run the codes below, I will explain to you face to face. source("http://bioconductor.org/biocLite.R")
packs = c("devtools", "reshape2", "ggplot2", "pheatmap", "ggfortify", "stringr", "survival",
"survminer", "lars", "glmnet", "timeROC", "ggpubr", "randomForest", "ROCR", "genefilter",
"Hmisc", "caret", "airway","DESeq2","edgeR","limma", "CLL", "org.Hs.eg.db", "maftools")
if(! require(pacman)) install.packages("pacman", dependencies = TRUE)
pacman::p_load(packs, dependencies=TRUE, character.only = TRUE)
# check
pacman::p_loaded(packs, character.only = TRUE)
all(pacman::p_loaded(packs, character.only = TRUE))

注:本文转自“生信技能树”

https://mp.weixin.qq.com/s?__biz=MzAxMDkxODM1Ng==&mid=2247487157&idx=1&sn=0540a2788eba7b5a96a6d4f907d92718&chksm=9b484e0eac3fc71864f0e1d5959ac5f768bd3289312c2d0776cbe663a888edd056b092175d5c&mpshare=1&scene=23&srcid=0809lYoGGKt6uOM4j8rCH40P#rd
相关推荐
python开发_常用的python模块及安装方法
adodb:我们领导推荐的数据库连接组件bsddb3:BerkeleyDB的连接组件Cheetah-1.0:我比较喜欢这个版本的cheeta…
日期:2022-11-24 点赞:878 阅读:9,086
Educational Codeforces Round 11 C. Hard Process 二分
C. Hard Process题目连接:http://www.codeforces.com/contest/660/problem/CDes…
日期:2022-11-24 点赞:807 阅读:5,561
下载Ubuntn 17.04 内核源代码
zengkefu@server1:/usr/src$ uname -aLinux server1 4.10.0-19-generic #21…
日期:2022-11-24 点赞:569 阅读:6,410
可用Active Desktop Calendar V7.86 注册码序列号
可用Active Desktop Calendar V7.86 注册码序列号Name: www.greendown.cn Code: &nb…
日期:2022-11-24 点赞:733 阅读:6,183
Android调用系统相机、自定义相机、处理大图片
Android调用系统相机和自定义相机实例本博文主要是介绍了android上使用相机进行拍照并显示的两种方式,并且由于涉及到要把拍到的照片显…
日期:2022-11-24 点赞:512 阅读:7,820
Struts的使用
一、Struts2的获取  Struts的官方网站为:http://struts.apache.org/  下载完Struts2的jar包,…
日期:2022-11-24 点赞:671 阅读:4,903