美文网首页
airway 安装踩坑总结

airway 安装踩坑总结

作者: 看远方的星 | 来源:发表于2019-01-24 23:58 被阅读18次

    biocLite("airway") 出错:

    1、 image.png

    2、installation of package ‘airway’ had non-zero exit status


    百度搜索,部分匹配 :R的版本过老,需要更新。

    image.png

    遂使用RGUI,进行更新。
    点击图标,启动Rgui


    image.png

    步骤:https://tieba.baidu.com/p/5432367188?red_tag=3391192606

    将R更新至3.5.2,还是出错:


    image.png

    谷歌搜索,完全匹配

    image.png 实践出错: image.png

    探索:

    > .libPaths() 
    [1] "C:/Users/300S/Documents/R/win-library/3.5"
    [2] "C:/Program Files/R/R-3.5.2/library"
    

    删除C:\Users\300S\Documents\R\win-library\3.5的biogenerics再下载airway出错。


    image.png
    > BiocInstaller::biocLite('GenomicRanges') 
    BioC_mirror: https://bioconductor.org
    Using Bioconductor 3.7 (BiocInstaller 1.30.0), R 3.5.2 (2018-12-20).
    Installing package(s) ‘GenomicRanges’
    also installing the dependency ‘BiocGenerics’
    
    Warning: packages ‘BiocGenerics’, ‘GenomicRanges’ are in use and will not be installed
    installation path not writeable, unable to update packages: class, codetools
    

    installation path not writeable,unable to update packages: class, codetools


    先解决第一个错误,第二个错误可能自动消失。一直把第二个错误当成主要错误来解决,拖了不少时间。


    本次的错误主要是airway需要的依赖包老了,需要更新,解决办法: 把bioconductor更新到3.8

    解决代码:

    > remove.packages(bioconductor)
    Error in remove.packages : object 'bioconductor' not found
    Warning message:
    In read.dcf(file.path(p, "DESCRIPTION"), c("Package", "Version")) :
      cannot open compressed file 'C:/Users/300S/Documents/R/win-library/3.5/BiocInstaller/DESCRIPTION', probable reason 'No such file or directory'
    
    > if (!requireNamespace("BiocManager"))
    +     install.packages("BiocManager")
    载入需要的名字空间:BiocManager
    > BiocManager::install()
    Bioconductor version 3.8 (BiocManager 1.30.4), R 3.5.2 (2018-12-20)
    Update old packages: 'Biobase', 'BiocParallel', 'GenomeInfoDb', 'GenomeInfoDbData',
      'GenomicFeatures', 'GenomicRanges', 'IRanges', 'S4Vectors',
      'SummarizedExperiment', 'XVector', 'zlibbioc'
    Update all/some/none? [a/s/n]: 
    a
    trying URL 'https://bioconductor.org/packages/3.8/bioc/bin/windows/contrib/3.5/Biobase_2.42.0.zip'
    Content type 'application/zip' length 2415278 bytes (2.3 MB)
    downloaded 2.3 MB
    
    trying URL 'https://bioconductor.org/packages/3.8/bioc/bin/windows/contrib/3.5/BiocParallel_1.16.5.zip'
    Content type 'application/zip' length 1638900 bytes (1.6 MB)
    downloaded 1.6 MB
    
    trying URL 'https://bioconductor.org/packages/3.8/bioc/bin/windows/contrib/3.5/GenomeInfoDb_1.18.1.zip'
    Content type 'application/zip' length 3836944 bytes (3.7 MB)
    downloaded 3.7 MB
    
    trying URL 'https://bioconductor.org/packages/3.8/bioc/bin/windows/contrib/3.5/GenomicFeatures_1.34.2.zip'
    Content type 'application/zip' length 2234127 bytes (2.1 MB)
    downloaded 2.1 MB
    
    trying URL 'https://bioconductor.org/packages/3.8/bioc/bin/windows/contrib/3.5/GenomicRanges_1.34.0.zip'
    Content type 'application/zip' length 2135888 bytes (2.0 MB)
    downloaded 2.0 MB
    
    trying URL 'https://bioconductor.org/packages/3.8/bioc/bin/windows/contrib/3.5/IRanges_2.16.0.zip'
    Content type 'application/zip' length 2352991 bytes (2.2 MB)
    downloaded 2.2 MB
    
    trying URL 'https://bioconductor.org/packages/3.8/bioc/bin/windows/contrib/3.5/S4Vectors_0.20.1.zip'
    Content type 'application/zip' length 2005904 bytes (1.9 MB)
    downloaded 1.9 MB
    
    trying URL 'https://bioconductor.org/packages/3.8/bioc/bin/windows/contrib/3.5/SummarizedExperiment_1.12.0.zip'
    Content type 'application/zip' length 2848042 bytes (2.7 MB)
    downloaded 2.7 MB
    
    trying URL 'https://bioconductor.org/packages/3.8/bioc/bin/windows/contrib/3.5/XVector_0.22.0.zip'
    Content type 'application/zip' length 703919 bytes (687 KB)
    downloaded 687 KB
    
    trying URL 'https://bioconductor.org/packages/3.8/bioc/bin/windows/contrib/3.5/zlibbioc_1.28.0.zip'
    Content type 'application/zip' length 375173 bytes (366 KB)
    downloaded 366 KB
    
    package ‘Biobase’ successfully unpacked and MD5 sums checked
    package ‘BiocParallel’ successfully unpacked and MD5 sums checked
    package ‘GenomeInfoDb’ successfully unpacked and MD5 sums checked
    package ‘GenomicFeatures’ successfully unpacked and MD5 sums checked
    package ‘GenomicRanges’ successfully unpacked and MD5 sums checked
    package ‘IRanges’ successfully unpacked and MD5 sums checked
    package ‘S4Vectors’ successfully unpacked and MD5 sums checked
    package ‘SummarizedExperiment’ successfully unpacked and MD5 sums checked
    package ‘XVector’ successfully unpacked and MD5 sums checked
    package ‘zlibbioc’ successfully unpacked and MD5 sums checked
    
    The downloaded binary packages are in
        C:\Users\300S\AppData\Local\Temp\RtmpERLX1m\downloaded_packages
    installing the source package ‘GenomeInfoDbData’
    
    trying URL 'https://bioconductor.org/packages/3.8/data/annotation/src/contrib/GenomeInfoDbData_1.2.0.tar.gz'
    Content type 'application/x-gzip' length 9186748 bytes (8.8 MB)
    downloaded 8.8 MB
    
    * installing *source* package 'GenomeInfoDbData' ...
    ** data
    ** inst
    ** help
    *** installing help indices
      converting help for package 'GenomeInfoDbData'
        finding HTML links ... 好了
        GenomeInfoDbData-package                html  
    ** building package indices
    ** testing if installed package can be loaded
    *** arch - i386
    *** arch - x64
    * DONE (GenomeInfoDbData)
    In R CMD INSTALL
    
    The downloaded source packages are in
        ‘C:\Users\300S\AppData\Local\Temp\RtmpERLX1m\downloaded_packages’
    

    成功下载airway并画图:

    > source("http://bioconductor.org/biocLite.R")
    Installing package into ‘C:/Users/300S/Documents/R/win-library/3.5’
    (as ‘lib’ is unspecified)
    trying URL 'https://bioconductor.org/packages/3.7/bioc/bin/windows/contrib/3.5/BiocInstaller_1.30.0.zip'
    Content type 'application/zip' length 102191 bytes (99 KB)
    downloaded 99 KB
    
    package ‘BiocInstaller’ successfully unpacked and MD5 sums checked
    
    The downloaded binary packages are in
        C:\Users\300S\AppData\Local\Temp\RtmpERLX1m\downloaded_packages
    Bioconductor version 3.7 (BiocInstaller 1.30.0), ?biocLite for help
    A newer version of Bioconductor is available for this version of R, ?BiocUpgrade for
      help
    > options(BioC_mirror="http://mirrors.ustc.edu.cn/bioc/") 
    > BiocInstaller::biocLite('airway')
    BioC_mirror: http://mirrors.ustc.edu.cn/bioc/
    Using Bioconductor 3.7 (BiocInstaller 1.30.0), R 3.5.2 (2018-12-20).
    Installing package(s) ‘airway’
    installing the source package ‘airway’
    
    trying URL 'http://mirrors.ustc.edu.cn/bioc//packages/3.7/data/experiment/src/contrib/airway_0.114.0.tar.gz'
    Content type 'application/gzip' length 11756544 bytes (11.2 MB)
    downloaded 11.2 MB
    
    * installing *source* package 'airway' ...
    ** data
    ** inst
    ** help
    *** installing help indices
      converting help for package 'airway'
        finding HTML links ... 好了
        airway                                  html  
    ** building package indices
    ** installing vignettes
    ** testing if installed package can be loaded
    *** arch - i386
    *** arch - x64
    * DONE (airway)
    In R CMD INSTALL
    
    The downloaded source packages are in
        ‘C:\Users\300S\AppData\Local\Temp\RtmpERLX1m\downloaded_packages’
    > library(airway)
    载入需要的程辑包:SummarizedExperiment
    载入需要的程辑包:GenomicRanges
    载入需要的程辑包:stats4
    载入需要的程辑包:BiocGenerics
    载入需要的程辑包:parallel
    
    载入程辑包:‘BiocGenerics’
    
    The following objects are masked from ‘package:parallel’:
    
        clusterApply, clusterApplyLB, clusterCall, clusterEvalQ, clusterExport,
        clusterMap, parApply, parCapply, parLapply, parLapplyLB, parRapply,
        parSapply, parSapplyLB
    
    The following objects are masked from ‘package:stats’:
    
        IQR, mad, sd, var, xtabs
    
    The following objects are masked from ‘package:base’:
    
        anyDuplicated, append, as.data.frame, basename, cbind, colMeans,
        colnames, colSums, dirname, do.call, duplicated, eval, evalq, Filter,
        Find, get, grep, grepl, intersect, is.unsorted, lapply, lengths, Map,
        mapply, match, mget, order, paste, pmax, pmax.int, pmin, pmin.int,
        Position, rank, rbind, Reduce, rowMeans, rownames, rowSums, sapply,
        setdiff, sort, table, tapply, union, unique, unsplit, which, which.max,
        which.min
    
    载入需要的程辑包:S4Vectors
    
    载入程辑包:‘S4Vectors’
    
    The following object is masked from ‘package:base’:
    
        expand.grid
    
    载入需要的程辑包:IRanges
    
    载入程辑包:‘IRanges’
    
    The following object is masked from ‘package:grDevices’:
    
        windows
    
    载入需要的程辑包:GenomeInfoDb
    载入需要的程辑包:Biobase
    Welcome to Bioconductor
    
        Vignettes contain introductory material; view with 'browseVignettes()'.
        To cite Bioconductor, see 'citation("Biobase")', and for packages
        'citation("pkgname")'.
    
    载入需要的程辑包:DelayedArray
    载入需要的程辑包:matrixStats
    
    载入程辑包:‘matrixStats’
    
    The following objects are masked from ‘package:Biobase’:
    
        anyMissing, rowMedians
    
    载入需要的程辑包:BiocParallel
    
    载入程辑包:‘DelayedArray’
    
    The following objects are masked from ‘package:matrixStats’:
    
        colMaxs, colMins, colRanges, rowMaxs, rowMins, rowRanges
    
    The following objects are masked from ‘package:base’:
    
        aperm, apply
    
    > data("airway")
    > exprSet=assay(airway)
    > colnames(exprSet)
    [1] "SRR1039508" "SRR1039509" "SRR1039512" "SRR1039513" "SRR1039516" "SRR1039517"
    [7] "SRR1039520" "SRR1039521"
    > group_list=colData(airway)[,3]
    > 
    > exprSet=exprSet[apply(exprSet, 1,function(x)sum(x>1)>5),]
    > boxplot(exprSet)
    
    图: image.png

    相关文章

      网友评论

          本文标题:airway 安装踩坑总结

          本文链接:https://www.haomeiwen.com/subject/rmspjqtx.html