Skip to content

juanitorduz/btsa

Repository files navigation

Build

Binder Open in Visual Studio Code

GitHub stars GitHub forks

Visits Badge Contributors

Berlin Time Series Analysis (BTSA) Repository

code

This repository contains resources of the Berlin Time Series Analysis Meetup. We encourage everyone to contribute to this repository! Here you can find the schedule and details of the meetup.

contact: [email protected]

You can also visit us on Medium.


Code of Conduct

Important: Make sure you read the Code of Conduct.


Resources

You can find a list of references on the resources section (which we will continuously update).


Environment

As we want to make the code reproducible, here are some options to manage dependencies (choose R or Python as preferred):

Conda Environment (Python)

  • Create conda environment (you can also update the environment from as described here):

    conda env create -f environment.yml

  • Activate conda environment:

    conda activate btsa

  • Run Jupyter Lab:

    jupyter lab


  • Build Docker image:

    docker build -t docker-btsa .

  • Run container

    docker run -p 10000:8888 docker-btsa

Visiting http://<hostname>:10000/?token=<token> in a browser loads the Jupyter Notebook dashboard page, where hostname is the name of the computer running docker and token is the secret token printed in the console.

You can find the python folder under the work directory.


  • From the root (btsa) directory, with R installed, run the following command: Rscript renv/activate.R.

This command will activate the environment and the renv package manager. From there you have two options depending on how you like to edit your projects.

Note: This configuration has been tested on R version 3.6.3.

Option 1. Command Line:

From the root directory type R and hit enter. Then type renv::restore() and respond with 'y' when prompted to install the packages. Your environment is now set up. You can continue writing commands or quit the console, your folder is now set up with the required packages.

Option 2: From RStudio

Open an Rstudio session. Go to RStudio > 'Open Project in New Session'. Navigate to the btsa folder and click open. In the console, type renv::restore() to install the necessary packages. Your RStudio session is now configured.