Data Visualisation with Python · Lesson 1 of 5
A chart is an argument
Decide what the chart is for before drawing it.
Every chart makes a claim. Before writing any code, decide what the claim is, because a chart without one is decoration and it takes exactly as long to produce.
Write the sentence first. "Sales fell in every region except Karachi." Then build the chart that shows that sentence, and the chart is finished when somebody sees the sentence without being told it.
Choose the chart from the question, not from preference.
Comparison between categories: a bar chart, horizontal when the labels are long.
Change over time: a line chart, with time on the horizontal axis.
Relationship between two variables: a scatter plot.
Distribution: a histogram or a box plot, and this is the one people most often skip, showing an average where the distribution was the finding.
Composition: a stacked bar, and almost never a pie chart, which is hard to read beyond three categories and impossible to compare between pies.
What to avoid entirely. Three dimensional anything, which distorts the values it is meant to show. Dual axes, which can be arranged to suggest any relationship you like. And a truncated vertical axis on a bar chart, which exaggerates differences and is recognised immediately.
Then label it so it stands alone. A title that states the conclusion, labelled axes with units, and a source. A chart that needs you standing beside it to be understood will be misread the moment it is forwarded.
Write the sentence your next chart is making before you draw it. If you cannot write it, you are not ready to draw anything.
اگلا چارٹ بنانے سے پہلے وہ جملہ لکھیں جو یہ کہہ رہا ہے۔ اگر جملہ نہ لکھ سکیں تو آپ چارٹ بنانے کے لیے تیار نہیں۔
Check what you learned
Create your free BvLogic ID to take the quiz and record your score.
Create your BvLogic ID