Data Science | Data Visualization
Embed Interactive charts in Medium/Websites using Plotly and Chartstudio with Python
Embed your interactive plots in Medium, Webpages, and other platforms using Plotly and Chartstudio
There is no such thing as information overload. There is only a bad design. — Edward Tufte
We all know a picture is worth a thousand words, data visualization is the visual summary of the information that makes it easier to understand/identify patterns and trends instead of looking at thousands of rows in spreadsheets. A good data visualization place the meaning of complex datasets in a precise and concise way. An interactive data visualization makes it even easier to understand and find insights from the data.
This article covers creating different interactive plots using Plotly and embedding interactive data visualizations in Medium and websites using Chartstudio.
Let’s get started✨
Connect with Chartstudio
Chartstudio is a platform that hosts your interactive plots/charts in the cloud. It has also developed open-source graphing Application Programming Interface (API) libraries for Python, R, MATLAB, Javascript, and other computer programming languages. The important features of Plotly and chartstudio are:
- It produces interactive graphs/charts.
- The graphs are stored in JavaScript Object Notation (JSON) data format so that they can be read using scripts of other programming languages such as R, Julia, MATLAB, etc.
- Graphs can be exported in various raster as well as vector image formats
Let’s see how to connect with chartstudio,
- Signup to chartstudio platform with credentials like Google, Facebook, Github, e.t.c.
- Go to Settings > API Keys, save the username and API Key.
The below code servers the purpose to connect with chartstudio using Python. chartstudio.tools.set_credentials_file
takes username
and api key
to connect with the platform.