Past projects

https://timelinetool.app/notion/event/ECXDAI2291B0HD1T

<aside> 🕑 A 10-minute read.

</aside>

https://embed.notionlytics.com/s/ZDFKaFVHdDJNMGRVWTBnelZEWkJTRU5uYlZnPQ==

Table of Contents

Introduction

Last weekend I was following Alex Freberg's tutorial for Data Analyst Portfolio Projects, in which he showed how to explore data with SQL and make a dashboard in Tableau. It was a fantastic video and I was able to build a dashboard about some basic COVID-19 data. I could have stopped there, but for some reasons, I was not yet satisfied.

First of all, this dashboard is currently "static", which goes against the primary purpose of dashboard: "showing and updating live, incoming data in real time" (Google).. Not to mention that, COVID-19 data is among the most frequently monitored and up-to-the-minute data in the world. That means if the data shown in our dashboard is more than a few days old, it would be almost meaningless. If I want to keep it up-to-date, I would have to repeat the entire process frequently (which, as you might imagine, is really time-consuming)

To remedy this issue, I came up with the idea of an automatically updated dashboard. After some more researches, I sketched out a plan of what needs to be done (repeatedly) to maintain our dashboard.

The plan:

  1. The data is loaded from the source, manipulated and saved to my local drive.
  2. The downloaded data is imported into my SQL Server database.
  3. A query will be performed with the data in SQL, and the output is saved onto a Google Sheets.
  4. The data from Google Sheets will be updated in Tableau once per day.
  5. And repeat.

"That sounds simple enough", I thought. "Just like that movie Edge of Tomorrow, isn't it*?"*

As it turned out, it really is simple with the help of 🐍 Python.

In the following sections, I'll guide you through how I leverage Python programming to automate the necessary tasks. I'll also narrate my thought process (ie: why do this and not that, etc...) so that you can understand the reasons behind each decision. I hope you'll get an idea of how an automation project might work (or at least have some fun reading this).

At the end of this project, we'll have a dashboard that can updates itself:

A snapshot of my "live" dashboard.

A snapshot of my "live" dashboard.

If you want to check out the finished product and the code I've written, you can find them here:

  1. **My live Dashboard**
  2. My Github repository

For more about me, you can refer to these links:

  1. My LinkedIn profile
  2. My other projects

With that out of the way, let's start making a Tableau Dashboard that Updates Automatically with Python.

Project Overview

(This is the part where I describe the project in details for scientific purposes. If you already understand the main ideas behind what we're doing, feel free to skip ahead and dive right into the process.)