Update installation instructions

replace/0defd6c654e986e3bd2ff6b97fc84c04a3814c63
JulioV 2019-12-18 17:13:37 -05:00
parent 91214b367a
commit 739d3f0315
1 changed files with 96 additions and 35 deletions

View File

@ -1,49 +1,54 @@
Installation
===============
This instructions have been tested on MacOS Cataline and Ubuntu 16.04. If you find a problem, please report it.
This instructions have been tested on MacOS Catalina and Ubuntu 16.04. If you find a problem, please report it.
Install MySQL
Mac OS (tested on Catalina)
----------------------------
#. Install MySQL
- ``brew install mysql``
- ``brew services start mysql``
Install R and rmarkdown:
#. Install R, pandoc and rmarkdown:
- ``brew install r``
- ``brew install pandoc``
- ``R -e 'install.packages(c( "rmarkdown"))'``
Install miniconda:
For Mac:
- ``R -e 'install.packages(c( "rmarkdown"), repos = "http://cran.us.r-project.org")'``
#. Install miniconda:
- ``brew cask install miniconda``
- ``conda init zsh`` or - ``conda init bash``
- ``conda init zsh`` or ``conda init bash``
- Restart terminal if necessary
Clone our repo:
#. Clone our repo:
- ``git clone https://github.com/carissalow/moshi-aware-pipeline``
Create a python virtual environment:
#. Create a python virtual environment:
- ``conda env create -f environment.yml``
- Restart terminal if necessary
- ``conda activate moshi-env``
- ``conda env create -f environment.yml -n MY_ENV_NAME``
- ``conda activate MY_ENV_NAME``
Install r packages and virtual environment:
#. Install r packages and virtual environment:
- ``snakemake packrat_install``
- ``snakemake packrat_init``
- ``snakemake packrat_restore``
Configure the participants to analyze:
#. Configure the participants to analyze:
- Add a file per participant and name it with the label for that participant, no extension is necessary: ``/data/external/pxx``
- Add a line with the device_id for that participant as it appears on the db
- Add a line with the mobile platform (Android, or iOS)
- Create a file per participant in the ``/data/external`` folder, no extension is necessary, its name will be the label for that participant in the pipeline: ``/data/external/pxx``
- Add a line with the device_id(s) of that participant as it appears on the database. If multiple device ids, all data for this participant will be relabeled with the last one
- Add a line with the mobile platform (android, or ios)
- For example:
.. code-block:: bash
Configure the db connection:
3a7b0d0a-a9ce-4059-ab98-93a7b189da8a,44f20139-50cc-4b13-bdde-0d5a3889e8f9
android
#. Configure the db connection:
- Create an empty .env file in the root folder
- Add and complete the following lines
@ -52,3 +57,59 @@ Configure the db connection:
| ``password=MyPassword``
| ``host=MyIP``
| ``port=3306``
Linux (tested on Ubuntu 16.04)
------------------------------
#. Install MySQL
- ``brew install mysql``
- ``brew services start mysql``
#. Install R, pandoc and rmarkdown:
- ``brew install r``
- ``brew install gcc@6`` (needed due to this bug_)
- ``HOMEBREW_CC=gcc-6 brew install pandoc``
- ``R -e 'install.packages(c( "rmarkdown"), repos = "http://cran.us.r-project.org")'``
#. Install miniconda using these instructions_
#. Clone our repo:
- ``git clone https://github.com/carissalow/moshi-aware-pipeline``
#. Create a python virtual environment:
- ``conda env create -f environment.yml -n MY_ENV_NAME``
- ``conda activate MY_ENV_NAME``
#. Install r packages and virtual environment:
- ``snakemake packrat_install``
- ``snakemake packrat_init``
- ``snakemake packrat_restore``
#. Configure the participants to analyze:
- Create a file per participant in the ``/data/external`` folder, no extension is necessary, its name will be the label for that participant in the pipeline: ``/data/external/pxx``
- Add a line with the device_id(s) of that participant as it appears on the database. If multiple device ids, all data for this participant will be relabeled with the last one
- Add a line with the mobile platform (android, or ios)
- For example:
.. code-block:: bash
3a7b0d0a-a9ce-4059-ab98-93a7b189da8a,44f20139-50cc-4b13-bdde-0d5a3889e8f9
android
#. Configure the db connection:
- Create an empty .env file in the root folder
- Add and complete the following lines
| ``[MY_GROUP_NAME]``
| ``user=MyUSER``
| ``password=MyPassword``
| ``host=MyIP``
| ``port=3306``
.. _bug: https://github.com/Homebrew/linuxbrew-core/issues/17812
.. _instructions: https://docs.conda.io/projects/conda/en/latest/user-guide/install/linux.html