Skip to content

pplonski/data-science-portfolio

Repository files navigation

Data Science Portfolio website with Jupyter notebook and Mercury

Data Science Portfolio website contructed from Jupyter notebooks and served with Mercury.

💻 Demo

Demo is running at Heroku free dyno at https://piotr-data-science-portfolio.herokuapp.com.

Mercury Custom Welcome Message

📓 Notebooks

There are three notebooks served. Each notebooks is interactive - they have YAML header defined for Mercury.

⚠️ The GitHub is not displaying the RAW cells when preview notebooks in GitHub. It is the best to clone the repo and open it in Jupyter Notebook/Lab.

🖥️ Run locally

Clone the code

git clone [email protected]:pplonski/data-science-portfolio.git

Add notebooks to Mercury

mercury add hello_notebook.ipynb
mercury add csv_preview.ipynb
mercury add show_image_notebook.ipynb

Run local server

mercury runserver --runworker

Please open a web browser, the website is running at https://127.0.0.1:8000.

🧰 Deploy

The repo can be easily deployed to Heroku with few commands.

Create Heroku app

heroku create my-amazing-app-name

Set environment variables in Heroku

heroku config:set SERVE_STATIC=True
heroku config:set ALLOWED_HOSTS=my-amazing-app-name.herokuapp.com
heroku config:set NOTEBOOKS=*.ipynb
heroku config:set WELCOME=welcome.md

Push the code to Heroku

git push heroku main

Happy coding!

I hope that this example Data Science Portfolio will help you create your own website. Good luck!