AI Hints
Home›Data Science Tutorial›Forecasting and Charts
Data Science · Lesson 26 of 101

Charts That Persuade

Design for one message.

⏱ 2 min read▶ Video at 44:56🎓 Free
Watch this lesson in the Data Science courseWatch on YouTube ↗Full Data Science course

You've found that two cafes are dragging down the business. You put it in a chart, and show it at a meeting. Nobody reacts. The chart was correct, but the message was buried. A good chart doesn't show data. It makes a point.

Charts That Persuade
From the video: Charts That Persuade
  • Two cafes are the problem
  • Nobody reacted
  • A chart must make a point

Before and after

Here's the same data, in two charts. On the left, the default. On the right, we sort it, make it horizontal so that names are readable, colour only the bars that matter, and write the conclusion as the title. Run it. On the left, you have to work it out. On the right, your eye goes straight to the problem. The title says what to think.

story.pypython
import pandas as pd
import matplotlib.pyplot as plt

sales = pd.read_csv("sales.csv")
s = sales.groupby("city")["profit"].sum().sort_values() / 1000

fig, ax = plt.subplots(1, 2, figsize=(10, 4.2))
ax[0].bar(s.index, s.values); ax[0].tick_params(axis="x", rotation=60)
ax[0].set_title("Default chart")

colours = ["tab:orange" if v < s.quantile(0.2) else "lightgray" for v in s.values]
ax[1].barh(s.index, s.values, color=colours)
ax[1].set_title("Two cafes need attention (profit, $k)")
ax[1].spines[["top", "right"]].set_visible(False)
plt.tight_layout(); plt.savefig("story.png", dpi=110)
print("Lowest:", s.index[:2].tolist())
Output
Lowest: ['Cairo', 'Abuja']

Rules for clear charts

Say what you want people to do. Use the title for the conclusion, not the topic. Remove anything that doesn't help, such as grid lines and borders. Use colour to focus attention, not to decorate. Sort your bars. Label directly on the chart. And start bars at zero, or you'll mislead.

Title = conclusionnot the topic
Remove clutterevery mark must earn its place
Colour for focusgrey for the rest
Sort and labelhelp the eye
Bars start at zerostay honest

Which chart?

Pick by what you're trying to show. Change over time, use a line. Compare categories, use sorted bars. Parts of a whole, use a stacked bar, and avoid pies with many slices. Relationships, use a scatter. Distributions, use a histogram or a box plot.

To showUse
Change over timeLine
Compare categoriesSorted bars
Parts of a wholeStacked bar
RelationshipScatter
DistributionHistogram, box plot

Summary

One chart, one message, and a title that states the conclusion. Next, how to turn your analysis into a story that leads to action.

Key takeaways
  • Title states the conclusion
  • Grey out the rest
  • Pick by what you're showing
Next up: Storytelling with Data — from findings to action