トップページ -> 最新情報技術の実習と研究ツール -> Linux のインストール,設定,運用保守,便利な使い方 -> Raspberry Pi Desktop (for PC and Mac) で基本ソフトウエア類のインストール
[サイトマップへ]  

Raspberry Pi Desktop (for PC and Mac) で基本ソフトウエア類のインストール

Raspberry Pi Desktop (for PC and Mac) は,Debian 9 ベース.軽量です. このウェブページでは,基本ソフトウエア類のインストール手順について説明します.

サイト内の関連 Web ページなど:

先人に感謝


前準備

RaspDesktop のシステム更新などを行っておく

端末を開き、次を実行

sudo apt update
sudo apt -yV upgrade
sudo apt -yV dist-upgrade
sudo rpi-update
sudo apt -yV autoremove
sudo apt autoclean
sudo shutdown -r now

ここでインストールする基本ソフトウエア


Raspberry Pi で Python の環境を整える

  1. システムの Python について, pip の更新
    cd /tmp
    sudo rm -f get-pip.py
    wget https://bootstrap.pypa.io/get-pip.py
    sudo /usr/bin/python3 get-pip.py
    sudo /usr/bin/python get-pip.py
    

  2. virtualenv, virtualenv wrapperのインストール

    システムの Python とは隔離された Python 環境を作ることができるようにする

    sudo rm -rf $HOME/.virtualenvs
    sudo rm -rf ~/.cache/pip
    sudo pip install virtualenv virtualenvwrapper
    sudo pip3 install virtualenv virtualenvwrapper
    export WORKON_HOME=$HOME/.virtualenvs
    export VIRTUALENVWRAPPER_PYTHON=/usr/bin/python3
    source /usr/local/bin/virtualenvwrapper.sh
    touch ~/.bashrc
    echo -e "\n# virtualenv and virtualenvwrapper" >> ~/.bashrc
    echo "export WORKON_HOME=$HOME/.virtualenvs" >> ~/.bashrc
    echo "export VIRTUALENVWRAPPER_PYTHON=/usr/bin/python3" >> ~/.bashrc
    echo "source /usr/local/bin/virtualenvwrapper.sh" >> ~/.bashrc
    source ~/.bashrc
    

  3. virtualenv を使って、隔離された Python 3 環境を作る
    1. 次の手順で作る
      mkvirtualenv --python=/usr/bin/python3 py35
      lsvirtualenv 
      

    2. 次の手順で確認する
      workon py35
      pip list
      

virtualenv 配下の Python 3 環境 に TenforFlow 1.11, Keras 2.2.4 をインストール

RaspDesktop の TensorFlow は、pip でインストールできないので、ソースコードからビルドする.

  1. virtualenv 配下の Python 3 環境で pip の更新
    workon py35
    cd /tmp
    sudo rm -f get-pip.py
    wget https://bootstrap.pypa.io/get-pip.py
    python get-pip.py
    pip list
    

  2. lib64stdc++6 のインストール
    sudo apt -yV install lib64stdc++6
    sudo ldconfig
    

  3. Bazel のインストール

    Bazel は Tenforflow のビルドに使う

    参考 Web ページ: https://www.quora.com/How-do-I-build-and-install-tensorflow-using-bazel-for-CPU-version

    参考 Web ページ: https://github.com/samjabrahams/tensorflow-on-raspberry-pi/blob/master/GUIDE.md

    wget https://github.com/bazelbuild/bazel/releases/download/0.17.2/bazel-0.17.2-installer-linux-x86_64.sh
    sudo bash bazel-0.17.2-installer-linux-x86_64.sh
    

  4. TensorFlow のソースコードのダウンロードと前準備 (かなりの時間がかかる)

    参考 Web ページ: https://www.tensorflow.org/install/source

    workon py35
    pip install numpy
    cd /tmp
    rm -rf tensorflow
    git clone --recurse-submodules https://github.com/tensorflow/tensorflow.git
    cd tensorflow
    rm -rf /home/pi/.cache/bazel
    

  5. エラーメッセージが出ていないことを確認する

  6. configure の実行
    CC_OPT_FLAGS="-march=native -funsafe-math-optimizations -ftree-vectorize -fomit-frame-pointer" \
      CXX_OPT_FLAGS="-march=native -funsafe-math-optimizations -ftree-vectorize -fomit-frame-pointer" \
      ./configure 
    

  7. configure で質問に答える

    [y/n] の質問には n + Enter

    その他の質問にも Enter

  8. ビルド(かなりの時間がかかる)(1-2時間以上)

    「--local_resources 1024,1.0,1.0」は、ビルド時に使用するメモリサイズを指定するためのもの

    bazel test --config=opt --copt="-march=native -funsafe-math-optimizations -ftree-vectorize -fomit-frame-pointer" --cxxopt="-march=native -funsafe-math-optimizations -ftree-vectorize -fomit-frame-pointer -D_GLIBCXX_USE_CXX11_ABI=0" -- //tensorflow/... 
    bazel build --config=opt --copt="-march=native -funsafe-math-optimizations -ftree-vectorize -fomit-frame-pointer" --cxxopt="-march=native -funsafe-math-optimizations -ftree-vectorize -fomit-frame-pointer -D_GLIBCXX_USE_CXX11_ABI=0" //tensorflow/tools/pip_package:build_pip_package
    ./bazel-bin/tensorflow/tools/pip_package/build_pip_package /tmp/tensorflow_pkg
    pip install /tmp/tensorflow_pkg/tensorflow-version-cp35-cp35mu-linux_x86_64.whl
    exit
    
    bazel test -c opt -- //tensorflow/... -//tensorflow/compiler/... 
    bazel build --config=opt //tensorflow/tools/pip_package:build_pip_package
    ./bazel-bin/tensorflow/tools/pip_package/build_pip_package /tmp/tensorflow_pkg
    pip install /tmp/tensorflow_pkg/tensorflow-version-cp35-cp35mu-linux_x86_64.whl
    # grep -Rl 'lib64' | xargs sed -i 's/lib64/lib/g'
    
    bazel build --cxxopt="-D_GLIBCXX_USE_CXX11_ABI=0" --local_resources 1024,1.0,1.0 //tensorflow/tools/pip_package:build_pip_package
    
    bazel build -c opt --copt="-funsafe-math-optimizations" --copt="-ftree-vectorize" --copt="-fomit-frame-pointer" --local_resources 1024,1.0,1.0 --verbose_failures tensorflow/tools/pip_package:build_pip_package
    

  9. ビルド終了の確認

基本ソフトウエアのインストール手順

ソースコードからのビルドに有用なソフトウエアのインストール

OpenCV などのビルドに役立つと判断されるツールやライブラリをインストール

sudo apt -yV install build-essential gcc g++ dpkg-dev pkg-config python3-dev python3-pip python3-numpy python-dev python-pip python-numpy 
sudo apt -yV install git make cmake cmake-curses-gui autoconf automake flex bison clang binutils swig curl
sudo apt -yV install subversion ccache
sudo apt -yV install zip unzip
sudo apt -yV install libopenblas-dev liblapack-dev nvidia-cuda-dev 
# sudo apt -yV install nvidia-cuda-toolkit 
sudo apt -yV install libxi-dev libsndfile1-dev libopenexr-dev libalut-dev libsdl2-dev libavdevice-dev libavformat-dev libavutil-dev libavcodec-dev libswscale-dev libx264-dev libxvidcore-dev libmp3lame-dev libspnav-dev libglu1-mesa-dev libv4l-dev
sudo apt -yV install libbz2-dev libsqlite3-dev libssl-dev libreadline-dev libpng-dev libtiff-dev zlib1g-dev libx11-dev libgl1-mesa-dev libxrandr-dev libxxf86dga-dev libxcursor-dev libfreetype6-dev libvorbis-dev libeigen3-dev libopenal-dev libode-dev libbullet-dev libgtk2.0-dev
# sudo apt -yV install libjasper-dev
sudo apt -yV install libgtk-3-dev libatlas-base-dev gfortran python2.7-dev python3-dev 
sudo apt -yV install nvidia-cg-toolkit 
# jpeg はソースコードからビルドする
sudo apt -yV install libjpeg62-turbo-dev
cd /tmp
wget http://www.ijg.org/files/jpegsrc.v9c.tar.gz
tar -xvzof jpegsrc.v9c.tar.gz
cd jpeg-9c
./configure
make 
sudo make install

プログラミング,開発環境

  • Python 3 環境と、Chainer, Tensorflow その他,python パッケージ
    source /usr/local/bin/virtualenvwrapper.sh
    mkvirtualenv --python=/usr/bin/python3 py35
    lsvirtualenv 
    
    source /usr/local/bin/virtualenvwrapper.sh
    workon py35
    #
    cd /tmp
    sudo apt -yV install caffe-cpu
    sudo apt -yV install idle-python3.5
    sudo apt -yV install ipython3
    sudo apt -yV install ipython3-qtconsole
    sudo apt -yV install jupyter-nbextension-jupyter-js-widgets
    sudo apt -yV install libpython3-all-dev
    sudo apt -yV install python3-bleach
    sudo apt -yV install python3-bz2file
    sudo apt -yV install python3-django
    sudo apt -yV install python3-flask
    sudo apt -yV install python3-gdal
    sudo apt -yV install python3-geopandas
    sudo apt -yV install python3-h5py
    sudo apt -yV install python3-hdf5storage
    sudo apt -yV install python3-html5lib
    sudo apt -yV install python3-ipykernel
    sudo apt -yV install python3-ipython
    sudo apt -yV install python3-ipython-genutils
    sudo apt -yV install python3-matplotlib
    sudo apt -yV install python3-msgpack
    sudo apt -yV install python3-numpy
    sudo apt -yV install python3-overpy
    sudo apt -yV install python3-pandas
    sudo apt -yV install python3-protobuf
    sudo apt -yV install python3-psutil
    sudo apt -yV install python3-pydot
    sudo apt -yV install python3-pygame
    sudo apt -yV install python3-pygraphviz
    sudo apt -yV install python3-pylint-common
    sudo apt -yV install python3-pyproj
    sudo apt -yV install python3-redis
    sudo apt -yV install python3-scipy
    sudo apt -yV install python3-seaborn
    sudo apt -yV install python3-six
    sudo apt -yV install python3-skimage
    sudo apt -yV install python3-skimage-lib
    sudo apt -yV install python3-sklearn
    sudo apt -yV install python3-sklearn-lib
    sudo apt -yV install python3-sklearn-pandas
    sudo apt -yV install python3-sympy
    sudo apt -yV install python3-yaml
    # instring using pip3 
    pip3 install --ignore-installed altair
    pip3 install --ignore-installed distributed
    pip3 install --ignore-installed pillow
    pip3 install --ignore-installed sqlite
    pip3 install --ignore-installed gensim
    pip3 install --ignore-installed cython
    # pip3 install --ignore-installed opencv
    pip3 install --ignore-installed cocos2d
    pip3 install git+https://github.com/davisking/dlib
    pip3 install git+https://github.com/ageitgey/face_recognition
    pip3 install -U --ignore-installed mtcnn
    pip3 install git+https://github.com/jrosebr1/imutils
    # pip3 install --ignore-installed --upgrade tensorflow 
    pip3 install git+https://github.com/keras-team/keras
    pip3 install --ignore-installed --upgrade pyglet
    pip3 install --ignore-installed --upgrade cocos2d
    pip3 install git+https://github.com/python-visualization/folium
    pip3 install --ignore-installed --upgrade  exifread
    pip3 install --ignore-installed --upgrade  haversine
    pip3 install --ignore-installed --upgrade  utm
    

  • python 3 の環境に spyder
    sudo apt -yV install python3-qtpy
    sudo apt -yV install python3-spyder
    pip3 install --ignore-installed --upgrade  spyder_kernels
    pip3 install --ignore-installed --upgrade  pycodestyle 
    pip3 install --ignore-installed --upgrade  rope 
    pip3 install --ignore-installed --upgrade  jedi
    cd /tmp
    git clone https://github.com/spyder-ide/spyder.git
    cd spyder 
    git pull 
    ~/.virtualenvs/py35/bin/python3 bootstrap.py
    ~/.virtualenvs/py35/bin/python3 setup.py install 
    

  • Python 2 環境と、Python 2 の環境に いくつかの python パッケージ
    source /usr/local/bin/virtualenvwrapper.sh
    mkvirtualenv --python=/usr/bin/python py27
    lsvirtualenv 
    
    source /usr/local/bin/virtualenvwrapper.sh
    workon py27
    
    cd /tmp
    sudo rm -f get-pip.py
    wget https://bootstrap.pypa.io/get-pip.py
    ~/.virtualenvs/py27/bin/python get-pip.py
    pip install numpy 
    pip install PyOpenGL 
    

  • Java JDK 8, Apache Ant, Java 開発環境 BlueJ, Guava, Java 学習環境 Greenfoot, Java 開発環境 Eclipse, pleiades, Eclipse gef
    cd /tmp
    # sudo apt -yV install oracle-java8-jdk
    sudo apt -yV install ant
    sudo apt -yV install bluej
    sudo apt -yV install libguava-java
    sudo apt -yV install greenfoot
    sudo apt -yV install eclipse pleiades
    echo "-javaagent:/usr/share/eclipse/plugins/jp.sourceforge.mergedoc.pleiades/pleiades.jar " | sudo tee -a /usr/lib/eclipse/eclipse.ini
    java -version
    

  • gcc, g++, gdb, GDB Enhanced Features, R システム, R.Studio (R開発環境), R パッケージ, scratch2, GNU Octave 及び関連パッケージ, Node JS, npm, Android SDK
    cd /tmp
    sudo apt -yV install build-essential
    sudo apt -yV install g++
    # GDB Enhanced Features,
    wget -q -O- https://github.com/hugsy/gef/raw/master/scripts/gef.sh | sh
    #
    sudo apt -yV install libgstreamer1.0-0:amd64 libgstreamer-plugins-base1.0-0:amd64
    sudo apt -yV install r-base
    #
    echo 'options(repos="http://cran.rstudio.com"); update.packages(checkBuilt=TRUE, ask=FALSE)' | sudo R --vanilla 
    sudo rm /tmp/a.$$.r
    echo 'source("http://bioconductor.org/biocLite.R")' > /tmp/a.$$.r 
    echo 'biocLite("EBImage") ' >> /tmp/a.$$.r 
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'install.packages("dplyr", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html"))' | sudo R --vanilla 
    echo 'install.packages("plyr", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html"))' | sudo R --vanilla 
    echo 'install.packages("dplyr", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html"))' | sudo R --vanilla 
    echo 'install.packages("reshape2", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html"))' | sudo R --vanilla 
    echo 'install.packages("ggplot2", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html"))' | sudo R --vanilla 
    echo 'install.packages("knitr", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html"))' | sudo R --vanilla 
    echo 'install.packages("sp", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html"))' | sudo R --vanilla 
    echo 'install.packages("raster", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html"))' | sudo R --vanilla 
    sudo apt -yV install gdal-bin
    echo 'install.packages("rgdal", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html"))' | sudo R --vanilla 
    #
    sudo apt -yV install r-recommended
    # R.Studio は書きかけ
    sudo apt -yV install gdebi-core
    sudo apt -yV install libxi6:amd64 libqt5gui5:amd64
    sudo apt -yV install libgl1-glvnd-nvidia-glx:amd64 libxcomposite1:amd64 libicu-dev:amd64 libxml2-dev:amd64 libxslt-dev:amd64
    sudo apt -yV install rstudio
    if [ ! -x /usr/bin/rstudio ]; then 
        echo /usr/bin/rstudio
        wget https://download1.rstudio.org/rstudio-xenial-1.1.453-amd64.deb 
        sudo dpkg -i rstudio-xenial-1.1.453-amd64.deb
    fi
    sudo apt -yV install scratch2
    sudo apt -yV install octave octave-*
    # nodejs and npm for debian linux
    curl -sL https://deb.nodesource.com/setup_10.x | sudo -E bash -
    sudo apt-get install -y nodejs
    sudo npm install -g n
    sudo apt -yV install android-sdk
    

    ツール

    Git, git-hub (GitHub), CMake, cmake-gui, ImageMagick (画像), FFMpeg (ビデオデータ処理), p7zip (圧縮, 展開), Graphviz (グラフデータ構造可視化), net-tools, hwinfo (ハードウエア情報), gdal (地理情報), tesseract, jq (JSON整形), jsonlint (JSONチェッカ)

    sudo apt -yV install git
    sudo apt -yV install git-hub
    sudo apt -yV install cmake
    sudo apt -yV install cmake-curses-gui
    sudo apt -yV install cmake-gui
    sudo apt -yV install imagemagick
    sudo apt -yV install ffmpeg
    sudo apt -yV install p7zip-full
    sudo apt -yV install graphviz graphviz-dev
    sudo apt -yV install net-tools
    sudo apt -yV install hwinfo
    sudo apt -yV install gdal-bin libgdal-dev
    sudo apt -yV install tesseract-ocr tesseract-ocr-jpn libtesseract-dev libleptonica-dev tesseract-ocr-jpn
    sudo apt -yV install jq
    sudo apt -yV install jsonlint
    

    アクセサリ

    xpdf (PDF リーダ), shutter (画面キャプチャ), catfish (ファイル検索)

    sudo apt -yV install xpdf
    sudo apt -yV install shutter
    sudo apt -yV install libgoo-canvas-perl
    sudo apt -yV install catfish
    

    インターネット

    FileZilla (ファイル転送), firefox (Webブラウザ), Wireshark (ネットワーク), netcat (通信), AWS Command Line Interface (AWS), RealVNCViewer (リモート接続)

    sudo apt -yV install filezilla
    sudo apt -yV install firefox-esr
    sudo apt -yV install firefox-esr-l10n-ja
    sudo apt -yV install wireshark
    sudo apt -yV install netcat
    sudo apt -yV install awscli aws-shell
    # RealVNCViewer
    cd /tmp
    sudo apt -yV install libice6 libsm6
    wget https://www.realvnc.com/download/file/viewer.files/VNC-Viewer-6.17.1113-Linux-x64.deb
    sudo dpkg -i VNC-Viewer-6.17.1113-Linux-x64.deb
    

    エディタ

    Visual Studio Code, Emacs, leafpad, gedit

    # # Visual Studio Code
    # # see https://code.visualstudio.com/docs/setup/linux
    # cd /tmp
    # curl https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > microsoft.gpg
    # sudo mv microsoft.gpg /etc/apt/trusted.gpg.d/microsoft.gpg
    # sudo sh -c 'echo "deb [arch=amd64] https://packages.microsoft.com/repos/vscode stable main" > /etc/apt/sources.list.d/vscode.list'
    # sudo apt update
    # sudo apt -yV install code
    # emacs
    sudo apt -yV install emacs
    # leafpad
    sudo apt -yV install leafpad
    # gedit 
    sudo apt -yV install gedit gedit-plugins 
    sudo apt -yV install gedit-developer-plugins
    

    グラフィックス

    Blender (3次元), POV-ray, MeshLab, MakeHuman, Inkscape, GIMP, pinta, CloudCompare

    sudo apt -yV install blender
    sudo apt -yV install povray povray-examples
    sudo apt -yV install meshlab
    sudo apt -yV install makehuman
    sudo apt -yV install inkscape
    sudo apt -yV install gimp
    sudo apt -yV install pinta
    # CloudCompare 
    sudo apt -yV install qtbase5-dev qtdeclarative5-dev qt5-default qttools5-dev libqt5widgets5 libqwt-qt5-dev libqt5svg5-dev
    cd /tmp
    wget https://github.com/CloudCompare/CloudCompare/archive/master.zip
    unzip master.zip
    rm -f master.zip
    cd CloudCompare-master
    rm -rf build
    mkdir build
    cd build
    cmake ..
    cmake --build .
    sudo make install
    # Blender VR
    cd /tmp
    sudo rm -f blender-2.74-a8adeeb-linux-glibc211-x86_64.tar.bz2
    wget ftp://blendervrdownloads:blendervr@ftp.limsi.fr/compiled/blender-2.74-a8adeeb-linux-glibc211-x86_64.tar.bz2
    cd /usr/local
    sudo rm -rf /usr/local/blender-2.74-a8adeeb-linux-glibc211-x86_64
    sudo tar -xpvjof /tmp/blender-2.74-a8adeeb-linux-glibc211-x86_64.tar.bz2
    sudo chown -R $USER /usr/local/blender-2.74-a8adeeb-linux-glibc211-x86_64
    sudo rm -f /usr/bin/blendervr
    sudo ln -s /usr/local/blender-2.74-a8adeeb-linux-glibc211-x86_64/blender /usr/bin/blendervr
    

    地図情報

    QGIS , Debian GIS Data, Debian GIS OSM

    sudo apt -yV install qgis
    # Debian GIS
    sudo apt -yV install gis-data gis-osm
    

    ビデオ

    VLC media player (メディア), Openshot

    sudo apt -yV install vlc
    sudo apt -yV install openshot
    

    データベース

    SQLite3, DB Browser for SQLite (sqlitebrowser), sqliteman, Redis 64bit

    sudo apt -yV install sqlite3
    sudo apt -yV install sqlitebrowser
    sudo apt -yV install redis-server redis-tools
    #  sqliteman
    sudo apt -yV install libqscintilla2-dev
    cd /tmp
    wget https://sourceforge.net/projects/sqliteman/files/sqliteman/1.2.2/sqliteman-1.2.2.tar.bz2 
    tar -xvjof sqliteman-1.2.2.tar.bz2 
    cd sqliteman-1.2.2
    rm -rf build
    mkdir build
    cd build
    cmake ..
    cmake --build .
    sudo make install
    

    ライブラリ

    OpenCV (コンピュータビジョン), CUDA, OpenALPR, OpenNI2, libPCL, Guava, Dlib

    source /usr/local/bin/virtualenvwrapper.sh
    workon py35 
    #
    sudo apt -yV install nvidia-cuda-dev nvidia-cuda-doc nvidia-cuda-gdb
    # sudo apt -yV install nvidia-cuda-toolkit
    sudo apt -yV install openalpr openalpr-utils libopenalpr-dev
    sudo apt -yV install openni2-utils libopenni2-dev
    sudo apt -yV install libpcl-dev
    sudo apt -yV install libguava-java
    #
    pip install numpy
    cd /tmp
    rm -rf opencv
    rm -rf opencv_contrib
    git clone https://github.com/opencv/opencv.git
    git clone https://github.com/opencv/opencv_contrib.git
    sudo apt install python-dev python3-dev 
    cd opencv
    rm -rf build
    mkdir build
    cd build
    cmake -D CMAKE_BUILD_TYPE=RELEASE \
          -D CMAKE_INSTALL_PREFIX=/usr/local \
          -D INSTALL_PYTHON_EXAMPLES=ON \
          -D OPENCV_EXTRA_MODULES_PATH=/tmp/opencv_contrib/modules \
          -D BUILD_opencv_python2=OFF \
          -D BUILD_opencv_python3=ON \
          -D PYTHON_DEFAULT_EXECUTABLE=python3 \
          -D BUILD_EXAMPLES=ON ..
    make 
    sudo make install
    sudo /sbin/ldconfig
    rm -f ~/.virtualenvs/py35/lib/python3.5/site-packages/
    cp /tmp/opencv/build/lib/python3/cv2*.so ~/.virtualenvs/py35/lib/python3.5/site-packages
    python -c "import cv2; print( cv2.__version__ )"
    

    DLib

    cd /tmp
    wget http://dlib.net/files/dlib-19.15.zip
    unzip dlib-19.15.zip
    cd dlib-19.15 
    rm -rf build
    mkdir build
    cd build
    cmake .. 
    cmake --build .
    sudo make install 
    cd /tmp/dlib-19.15 
    python setup.py install 
    

    設計

    freecad

    sudo apt -yV install freecad
    

    ゲームフレームワーク,ゲームエンジン

    # Panda3d
    cd /tmp
    sudo rm -f master.zip
    wget https://github.com/panda3d/panda3d/archive/master.zip
    unzip master.zip
    rm -f master.zip
    cd panda3d-master
    
    source /usr/local/bin/virtualenvwrapper.sh
    workon py35
    ~/.virtualenvs/py35/bin/python3 makepanda/makepanda.py --everything --installer --no-egl --no-gles --no-gles2 --no-opencv
    sudo dpkg -i panda3d*.deb
    # pip install --pre --extra-index-url https://archive.panda3d.org/ panda3d
    

    Docker類

    Docker, docker-compose

    sudo apt -yV install docker
    sudo apt -yV install docker-compose
    

    Rのパッケージを追加

    cd /tmp
    
    sudo apt -yV install libxml2-dev libfftw3-dev libfreetype6-dev
    sudo apt -yV install libnlopt-dev
    
    echo 'options(repos="http://cran.rstudio.com"); update.packages(checkBuilt=TRUE, ask=FALSE)' | sudo R --vanilla 
    
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    cat /tmp/a.$$.r | sudo R --vanilla 
    
    
    # EBImage
    sudo rm /tmp/a.$$.r
    echo 'source("http://bioconductor.org/biocLite.R")' > /tmp/a.$$.r 
    echo 'biocLite("EBImage") ' >> /tmp/a.$$.r 
    cat /tmp/a.$$.r | sudo R --vanilla 
    
    # dplyr
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("dplyr", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    
    # qvalue
    sudo rm /tmp/a.$$.r
    echo 'source("http://bioconductor.org/biocLite.R")' > /tmp/a.$$.r 
    echo 'biocLite("qvalue") ' >> /tmp/a.$$.r 
    cat /tmp/a.$$.r | sudo R --vanilla 
    
    # pam
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("pam", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    
    # pca3d
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("pca3d", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    
    # tm 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("tm", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    
    # mmand
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("mmand", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    # devtools
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("devtools", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    # ctv
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("ctv", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    # osmar
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("osmar", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    # pi0
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("pi0", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    # leaps
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("leaps", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    # ifs 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("ifa", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    # BMA
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("BMA", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    # WriteXLS
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("WriteXLS", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    # CHsharp
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("CHsharp", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    # brew
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("brew", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    # data.table
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("data.table", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    # pcaPP
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("pcaPP", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    # fastICA
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("fastICA", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    # zoo
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("zoo", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    
    # base 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("abind", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("boot", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("car", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("chron", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("cluster", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("codetools", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("colorspace", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("effects", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("foreign", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("lattice", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("lmtest", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("mgcv", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("multcomp", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("mvtnorm", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("relimp", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("rpart", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("sandwich", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("sm", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("spatial", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("strucchange", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("survival", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    # additional 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("catspec", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("cluster", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("deldir", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("diagram", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("fields", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("fftw", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("gregmisc", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("igraph", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("nlme", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("nnclust", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("png", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("pixmap", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("pvclust", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("rgl", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("scatterplot3d", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("som", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("Hmisc", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("Rcmdr", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("RcmdrPlugin.KMggplot2", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("RSQLite", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("CCA", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("KernSmooth", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("MASS", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("Matrix", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("Rcmdr", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    # more 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("ggplot2", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("xlsxjars", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("xlsx", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("shiny", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("chron", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("sqldf", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("plyr", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("entropy", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("moments", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("spatstat", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("png", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("biOps", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("biOpsGUI", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("maptools", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("caTools", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    # echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    # echo 'install.packages("class", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    # cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("evd", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("its", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("mapproj", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("mnormt", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("sm", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("sp", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("stabledist", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("timeSeries", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("tseries", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("bayesm", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("gdata", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("gmodels", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("rpart", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("Zelig", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("forecast", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    
    # again 
    echo 'options(repos="http://cran.rstudio.com")' > /tmp/a.$$.r 
    echo 'update.packages(checkBuilt=TRUE, ask=FALSE, repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    
    #
    sudo rm /tmp/a.$$.r
    echo 'source("http://bioconductor.org/biocLite.R")' > /tmp/a.$$.r 
    echo 'biocLite("osmar") ' >> /tmp/a.$$.r 
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'source("http://bioconductor.org/biocLite.R")' > /tmp/a.$$.r 
    echo 'biocLite("Rgraphviz") ' >> /tmp/a.$$.r 
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'source("http://bioconductor.org/biocLite.R")' > /tmp/a.$$.r 
    echo 'biocLite("hypergraph") ' >> /tmp/a.$$.r 
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'source("http://bioconductor.org/biocLite.R")' > /tmp/a.$$.r 
    echo 'biocLite("RBGL") ' >> /tmp/a.$$.r 
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'source("http://bioconductor.org/biocLite.R")' > /tmp/a.$$.r 
    echo 'biocLite("GraphPart") ' >> /tmp/a.$$.r 
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("XML", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("gridExtra", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("gridSVG", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("png", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("jpeg", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("igraph", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("Rcpp", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("RcppExamples", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("mvoutlier", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("randomForest", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("plyr", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("reshape2", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("forecast", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("stringr", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("lubridate", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("sqldf", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("ggplot2", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("party", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("gdm", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("survival", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("caTools", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("Epi", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("vcd", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("Rz", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("parallel", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("compiler", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("Imap", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("changepoint", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("gstat", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("sp", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("rgeos", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("maptools", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("shapefiles", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("spsurvey", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("sp", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("RColorBrewer", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("forecast", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("psych", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("xts", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("timeSeries", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("gregmisc", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("mclust", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("topmodel", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("insol", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("rJava", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("RWekajars", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("RWeka", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("Snowball", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("lsa", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    #
    sudo rm /tmp/a.$$.r
    echo 'options(repos="http://cran.rstudio.com") ' > /tmp/a.$$.r 
    echo 'install.packages("stringdist", repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    # again 
    echo 'options(repos="http://cran.rstudio.com")' > /tmp/a.$$.r 
    echo 'update.packages(checkBuilt=TRUE, ask=FALSE, repos="http://cran.rstudio.com/", clean=TRUE, INSTALL_opts=c("--no-docs", "--no-html")) ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla 
    # again and again
    echo 'options(repos="http://cran.rstudio.com")' > /tmp/a.$$.r 
    echo 'update.packages(checkBuilt=TRUE, ask=FALSE, repos="http://cran.rstudio.com/") ' >> /tmp/a.$$.r
    cat /tmp/a.$$.r | sudo R --vanilla