title: "day4note"
output: html_document
date: "2024-03-09"
找所有R包使用的规律
生物信息学R包的三个来源
install.packages("tidyr") #CRAN网站
install.packages('BiocManager') #Bioconductor网站
BiocManager::install("limma")
install.packages('devtools')#github网站
devtools::install_github("jmzeng1314/idmap1") #括号里写作者用户名加包名
#安装 TwoSampleMR,在bing上搜属于哪个网站
devtools::install_github("MRCIEU/TwoSampleMR")
.libPaths()
## [1] "/Library/Frameworks/R.framework/Versions/4.3-x86_64/Resources/library"
发给自己
.libPaths()
## [1] "/Library/Frameworks/R.framework/Versions/4.3-x86_64/Resources/library"
实现快速下载的方法
方法一:
方法二:代码设置镜像
options("repos"=c(CRAN="http://mirrors.tuna.tsinghua.edu.cn/CRAN/"))
options(BioC_mirror="http://mirrors.ustc.edu.cn/bioc/")
3.检查包有没有安装成功
library(tidyr)#安装后需加载
library(stringr)
#library没有error,R包安装成功
require(tidyr)#返回逻辑值
3.1
pheatmap::pheatmap(volcano)#已经安装的包,可以用::快速调用里面的函数
#当一个代码要复制三次,写成循环
4.安装包时存在提示信息
R语言版本只追求第二位最新
4.1问是否更新的、“不存在”的是依赖包
使用包里的函数,要先安装或加载包
小理一下,,
if(!require(stringr))install.packages("stringr")
?sd#1.快速查看函数帮助文档
#2.找R包介绍页面(直接搜)
library(limma)
browseVignettes("limma") #3.browseVignettes("")
#不是每个包都有的 #在线帮助文档
ls("package:limma") #列出一个包里都有哪些函数或数据
## [1] "[.EList" "[.EListRaw"
## [3] "[.MAList" "[.MArrayLM"
## [5] "[.RGList" "[.TestResults"
## [7] "alias2Symbol" "alias2SymbolTable"
## [9] "alias2SymbolUsingNCBI" "anova.MAList"
## [11] "arrayWeights" "arrayWeightsQuick"
## [13] "as.data.frame.EList" "as.data.frame.EListRaw"
## [15] "as.data.frame.MAList" "as.data.frame.MArrayLM"
## [17] "as.MAList" "as.matrix.EList"
## [19] "as.matrix.EListRaw" "as.matrix.ExpressionSet"
## [21] "as.matrix.LumiBatch" "as.matrix.MAList"
## [23] "as.matrix.MArrayLM" "as.matrix.marrayNorm"
## [25] "as.matrix.PLMset" "as.matrix.RGList"
## [27] "as.matrix.vsn" "asMatrixWeights"
## [29] "auROC" "avearrays"
## [31] "avearrays.default" "avearrays.EList"
## [33] "avearrays.MAList" "avedups"
## [35] "avedups.default" "avedups.EList"
## [37] "avedups.MAList" "avereps"
## [39] "avereps.default" "avereps.EList"
## [41] "avereps.EListRaw" "avereps.MAList"
## [43] "avereps.RGList" "backgroundCorrect"
## [45] "backgroundCorrect.matrix" "barcodeplot"
## [47] "beadCountWeights" "blockDiag"
## [49] "bwss" "bwss.matrix"
## [51] "camera" "camera.default"
## [53] "cameraPR" "cameraPR.default"
## [55] "cbind.EList" "cbind.EListRaw"
## [57] "cbind.MAList" "cbind.RGList"
## [59] "changeLog" "chooseLowessSpan"
## [61] "classifyTestsF" "contrastAsCoef"
## [63] "contrasts.fit" "controlStatus"
## [65] "convest" "coolmap"
## [67] "cumOverlap" "decideTests"
## [69] "decideTests.default" "decideTests.MArrayLM"
## [71] "designI2A" "designI2M"
## [73] "detectionPValues" "detectionPValues.default"
## [75] "detectionPValues.EListRaw" "diffSplice"
## [77] "dim.EList" "dim.EListRaw"
## [79] "dim.MAList" "dim.MArrayLM"
## [81] "dim.RGList" "dimnames.EList"
## [83] "dimnames.EListRaw" "dimnames.MAList"
## [85] "dimnames.MArrayLM" "dimnames.RGList"
## [87] "dimnames<-.EList" "dimnames<-.EListRaw"
## [89] "dimnames<-.MAList" "dimnames<-.RGList"
## [91] "duplicateCorrelation" "eBayes"
## [93] "exprs.MA" "fitFDist"
## [95] "fitFDistRobustly" "fitGammaIntercept"
## [97] "fitmixture" "fitted.MArrayLM"
## [99] "fry" "fry.default"
## [101] "genas" "geneSetTest"
## [103] "getDupSpacing" "getEAWP"
## [105] "getGeneKEGGLinks" "getKEGGPathwayNames"
## [107] "getLayout" "getLayout2"
## [109] "getSpacing" "gls.series"
## [111] "goana" "goana.default"
## [113] "goana.MArrayLM" "goanaTrend"
## [115] "gridc" "gridr"
## [117] "head.EList" "head.EListRaw"
## [119] "head.MAList" "head.MArrayLM"
## [121] "head.RGList" "head.TestResults"
## [123] "heatdiagram" "heatDiagram"
## [125] "helpMethods" "ids2indices"
## [127] "imageplot" "imageplot3by2"
## [129] "interGeneCorrelation" "intraspotCorrelation"
## [131] "is.fullrank" "isNumeric"
## [133] "kegga" "kegga.default"
## [135] "kegga.MArrayLM" "kooperberg"
## [137] "labels.TestResults" "levels.TestResults"
## [139] "limmaUsersGuide" "lm.series"
## [141] "lmFit" "lmscFit"
## [143] "loessFit" "logcosh"
## [145] "logsumexp" "MA.RG"
## [147] "ma3x3.matrix" "ma3x3.spottedarray"
## [149] "makeContrasts" "makeUnique"
## [151] "mdplot" "merge.EList"
## [153] "merge.EListRaw" "merge.MAList"
## [155] "merge.RGList" "mergeScansRG"
## [157] "modelMatrix" "modifyWeights"
## [159] "mrlm" "mroast"
## [161] "mroast.default" "nec"
## [163] "neqc" "nonEstimable"
## [165] "normalizeBetweenArrays" "normalizeCyclicLoess"
## [167] "normalizeForPrintorder" "normalizeForPrintorder.rg"
## [169] "normalizeMedianAbsValues" "normalizeMedianValues"
## [171] "normalizeQuantiles" "normalizeRobustSpline"
## [173] "normalizeVSN" "normalizeVSN.default"
## [175] "normalizeVSN.EListRaw" "normalizeVSN.RGList"
## [177] "normalizeWithinArrays" "normexp.fit"
## [179] "normexp.fit.control" "normexp.fit.detection.p"
## [181] "normexp.signal" "plotDensities"
## [183] "plotDensities.default" "plotDensities.EList"
## [185] "plotDensities.EListRaw" "plotDensities.MAList"
## [187] "plotDensities.RGList" "plotExonJunc"
## [189] "plotExons" "plotFB"
## [191] "plotFB.default" "plotFB.EListRaw"
## [193] "plotFB.RGList" "plotlines"
## [195] "plotMA" "plotMA.default"
## [197] "plotMA.EList" "plotMA.EListRaw"
## [199] "plotMA.MAList" "plotMA.MArrayLM"
## [201] "plotMA.RGList" "plotMA3by2"
## [203] "plotMD" "plotMD.default"
## [205] "plotMD.EList" "plotMD.EListRaw"
## [207] "plotMD.MAList" "plotMD.MArrayLM"
## [209] "plotMD.RGList" "plotMDS"
## [211] "plotMDS.default" "plotMDS.MDS"
## [213] "plotPrintorder" "plotPrintTipLoess"
## [215] "plotRLDF" "plotSA"
## [217] "plotSplice" "plotWithHighlights"
## [219] "poolVar" "predFCm"
## [221] "printHead" "printorder"
## [223] "printtipWeights" "propexpr"
## [225] "propTrueNull" "protectMetachar"
## [227] "qqf" "qqt"
## [229] "rankSumTestWithCorrelation" "rbind.EList"
## [231] "rbind.EListRaw" "rbind.MAList"
## [233] "rbind.RGList" "read.columns"
## [235] "read.idat" "read.ilmn"
## [237] "read.ilmn.targets" "read.imagene"
## [239] "read.maimages" "readGAL"
## [241] "readGenericHeader" "readGPRHeader"
## [243] "readImaGeneHeader" "readSMDHeader"
## [245] "readSpotTypes" "readTargets"
## [247] "removeBatchEffect" "removeExt"
## [249] "residuals.MArrayLM" "RG.MA"
## [251] "roast" "roast.default"
## [253] "romer" "romer.default"
## [255] "sampleInfoFromGEO" "selectModel"
## [257] "show" "spotc"
## [259] "spotr" "squeezeVar"
## [261] "strsplit2" "subsetListOfArrays"
## [263] "summary.EList" "summary.EListRaw"
## [265] "summary.MAList" "summary.MArrayLM"
## [267] "summary.RGList" "summary.TestResults"
## [269] "tail.EList" "tail.EListRaw"
## [271] "tail.MAList" "tail.MArrayLM"
## [273] "tail.RGList" "tail.TestResults"
## [275] "targetsA2C" "tmixture.matrix"
## [277] "tmixture.vector" "topGO"
## [279] "topKEGG" "topRomer"
## [281] "topSplice" "topTable"
## [283] "topTableF" "topTreat"
## [285] "treat" "tricubeMovingAverage"
## [287] "trigammaInverse" "trimWhiteSpace"
## [289] "tZscore" "unique.TestResults"
## [291] "uniquegenelist" "uniqueTargets"
## [293] "unwrapdups" "vennCounts"
## [295] "vennDiagram" "volcanoplot"
## [297] "voom" "vooma"
## [299] "voomaByGroup" "voomWithQualityWeights"
## [301] "weighted.median" "weightedLowess"
## [303] "wilcoxGST" "write.fit"
## [305] "wsva" "wtarea"
## [307] "wtflags" "wtIgnore.Filter"
## [309] "zscore" "zscoreGamma"
## [311] "zscoreHyper" "zscoreT"
最后做个题吧~
answer:A E
引用自生信技能树课程
原创声明:本文系作者授权腾讯云开发者社区发表,未经许可,不得转载。
如有侵权,请联系 cloudcommunity@tencent.com 删除。
原创声明:本文系作者授权腾讯云开发者社区发表,未经许可,不得转载。
如有侵权,请联系 cloudcommunity@tencent.com 删除。