Creating Dashboard to Visualise Data In Python
Tags: python, webdev, design, opensource
Published: 2019-11-24 13:05:34

# Introduction
During one of my university project modules which require us to present our data from the sample dataset of the [Scottish Referendum 2014][1]. 

There I was exposed to terms like [Data Wrangling][2] and the use of [D3][3] to create an interactive dashboard. 

Which the process to do **data-wrangling** was a tedious process and creating the dashboard using D3 was quite bad as well. 

So [Data Visualisation][4] always leaves a bad taste for me.  

# Pain in Building Dashboard
For me, the difficulty arises when building a website dashboard in Python. 

Despite there are literally tons of dashboard templates out there. From **bootstrap**, **D3** to **plotly chart** templates to get you started. 

When you want to customise it to fit your need, It can be a **huge learning** curve. 

Especially your focus is not on web development. With the **ever-growing** amount of front-end technologies at your disposal. It can be daunting for anyone.

If you are like most developers with skillsets to **analyse** the data and presenting a **story** out of it. 

This is where I **believe** that using data visualisation libraries can help to speed up the creation process of your dashboard to present data.

# Data Visualisation Libraries for Dashboard 
Till date, I had played with **two**  data visualisation libraries for creating a dashboard in Python.  

Namely, [Dash][5] by [Plotly][6] which has quite a **mature** data visualisation library & **beautiful interactive** charts . 

But it has a **steeper** learning curve and a lot of **boilerplate** code. 

When you are creating your own dashboard using the **HTML components** provided by **Plotly**. 

The 2nd that I had worked with is a new kid on the block that is called [Streamlit][7]. 

Which offers features like **3rd party integration** of charts and **data caching** capabilities along with the use of **markdown** to create your dashboard.

# Conclusion
Despite the ease of use for these dashboards libraries, which helps you to create a dashboard without the need to learn or built using front-end web technologies.

I found out that this does not replace the need for data analysis or data visualisation using plotting libraries like [Bokeh][8], [Plotly][6] or [Matplotlib][9].

Since I was stuck with cleaning and generating the charts needed to display it on my dashboard. 

Never the less, If you are planning to build a website dashboard.

I would strongly recommend you to start with [Streamlit][7] due to its simplicity and ease of us to get started. You can go the [Streamlit video tutorial][10] to learn about how to use it in just under **4 mins**.

If you like my article, please **sign up** for Max [Adventurer's Newsletter](http://eepurl.com/dOUoUb) for awesome content I stumble across weekly in **Python**, **Startup** and **Web Development**.

You can also **follow** me to get the **latest** update of my article on **Dev**

This post was originally posted on Max's blog at [Creating Dashboard To Visualise Data In Python](https://www.maxongzb.com/creating-dashboard-to-visualise-data-in-python/) and [Photo by Stephen Dawson on Unsplash](https://unsplash.com/photos/qwtCeJ5cLYs)

# References
* [Data Visualisation][4]
* [Scottish Referendum 2014][1]
*  [Data Wrangling][2]
* [D3][3] 
* [Streamlit][7]
* [Dash][5]
* [Plotly][6] 
* [Bokeh][8]
* [Streamlit video tutorial][10]


[1]: https://datashare.is.ed.ac.uk/handle/10283/2614
[2]: https://tdwi.org/articles/2017/02/10/data-wrangling-and-etl-differences.aspx
[3]: https://d3js.org/
[4]: https://www.tableau.com/learn/articles/data-visualization
[5]: https://plot.ly/dash/
[6]: https://plot.ly/
[7]: https://streamlit.io/
[8]: https://docs.bokeh.org/en/latest/index.html
[9]: https://matplotlib.org/
[10]: https://youtu.be/B2iAodr0fOo