メインコンテンツに移動
戯れ言の水溜まりΦ

メインナビゲーション

  • ホーム
ユーザーアカウントメニュー
  • ログイン

パンくず

  1. ホーム
  2. R
  3. めも

Rパッケージ ソースダウンロード

By estis , 14 10月, 2018
  • コメントを投稿するにはログインまたは登録をしてください

download.packages("[パッケージ名]", destdir="/download/dir", type="source")
で、ダウンロードできる。

http://d.hatena.ne.jp/t_ume_tky/20120725/1343189052
に記載されているのを発見。

 

??download.package

 

download.packages {utils}	R Documentation
Download Packages from CRAN-like Repositories

Description

These functions can be used to automatically compare the version numbers of installed packages with the newest available version on the repositories and update outdated packages on the fly.

Usage

download.packages(pkgs, destdir, available = NULL,
                  repos = getOption("repos"),
                  contriburl = contrib.url(repos, type),
                  method, type = getOption("pkgType"), ...)
Arguments

pkgs	
character vector of the names of packages whose latest available versions should be downloaded from the repositories.

destdir	
directory where downloaded packages are to be stored.

available	
an object as returned by available.packages listing packages available at the repositories, or NULL which makes an internal call to available.packages.

repos	
character vector, the base URL(s) of the repositories to use, i.e., the URL of the CRAN master such as "https://cran.r-project.org" or its Statlib mirror, "http://lib.stat.cmu.edu/R/CRAN".

contriburl	
URL(s) of the contrib sections of the repositories. Use this argument only if your repository mirror is incomplete, e.g., because you burned only the ‘contrib’ section on a CD. Overrides argument repos.

method	
Download method, see download.file.

type	
character string, indicate which type of packages: see install.packages and ‘Details’.

...	
additional arguments to be passed to download.file and available.packages.

Details

download.packages takes a list of package names and a destination directory, downloads the newest versions and saves them in destdir. If the list of available packages is not given as argument, it is obtained from repositories. If a repository is local, i.e. the URL starts with "file:", then the packages are not downloaded but used directly. Both "file:" and "file:///" are allowed as prefixes to a file path. Use the latter only for URLs: see url for their interpretation. (Other forms of file:// URLs are not supported.)

For download.packages, type = "both" looks at source packages only.

Value

A two-column matrix of names and destination file names of those packages successfully downloaded. If packages are not available or there is a problem with the download, suitable warnings are given.

See Also

available.packages, contrib.url.

The main use is by install.packages.

See download.file for how to handle proxies and other options to monitor file transfers.

The ‘R Installation and Administration’ manual for how to set up a repository.

[Package utils version 3.5.1 Index]

Comments

ブックナビゲーション

  • 関数
  • めも
    • A Layered Grammar of Graphics
    • HTTPSプロトコルでのWebページ読み込み R
    • R RWeka ロード時のエラー
    • R options()関数 出力内容
    • R plot() の ylim と、axis() の at, labels
    • R から Python を使う
    • R インストールしておきたいパッケージ
    • R グラフを画像として保存する
    • R ソースインストール
    • R データフレームをベクトルに変換する
    • R パッケージのインストール・読み込み
    • R パッケージの更新
    • R ファイルの文字コード確認
    • R ベクトル・行列の掛け算
    • R 全てのオブジェクトをsaveする
    • R 文字化け対策
    • R 有効桁数の変更
    • R 関数の引数を確認する
    • RPostgreSQL のインストール
    • RStudio Server インストール
    • RStudio で、データベースに接続する方法
    • RStudio ショートカットメモ
    • RWeka ロード時のエラー 再び
    • Rwebdriver インストール
    • Rではじめるデータサイエンス 1.2 第1ステップ 練習問題
    • Rではじめるデータサイエンス 1.3 エステティックマッピング 練習問題
    • Rによる自動データ収集 読書めも1
    • Rによる自動データ収集 読書めも2
    • Rによる自動データ収集 読書めも3
    • Rによる自動データ収集 読書めも4
    • Rのgrepなどで、( に一致させたい時
    • Rパッケージ ソースダウンロード
    • UsefulR 9 ドキュメント・プレゼンテーション生成 サポートページ
    • dygraph 数値表示をカンマ区切りにしたい
    • pandoc document conversion failed with error 61
    • rgeolocate パッケージ
    • sar コマンドの出力結果から、%iowait の状況を R でグラフにしたり分析したり
    • sar コマンドの出力結果から、%iowait の状況を R でグラフにしたり分析したり ggplot2 でグラフ描画
RSSフィード
Powered by 戯れ言の水溜まりΦ