Studio Matrx Monthly · Volume 1 · Issue 3 · August 2026
Amogh N P
 In loving memory of Amogh N P — Architect · Designer · Visionary 
Charts and VisualizationLesson 4.4
PSD for Architecture, Planning & Urban Design/Module 4 · Working with Design Data

Lesson 4.4 · Working with Design Data

Charts and Visualization

Seeing your data - turn areas, costs and quantities into bar, line and pie charts with matplotlib, and save them as clean images for a report or a board

13 min Interactive lessonFree · open lessonByAmogh N P· Architect & interior designer
The hook

A number in a cell is something you read. A bar chart is something you feel - and clients decide with what they feel.

You have a table of room areas, a cost broken down by trade, a year of energy use. In a spreadsheet these are columns of digits that hide their own story. As a chart, the story is instant: which room dominates, where the money goes, when consumption spikes.

matplotlib is Python's workhorse for turning data into pictures. In this lesson you learn its handful of core plot types - bar for comparing categories, line for change over time, pie for parts of a whole - how to label a chart so it is honest and readable, and how to save a crisp image straight into a report or onto a presentation board. It is the satisfying end of the pipeline: the moment your cleaned, computed data finally becomes something you can show.

figure = canvas, axes = the plot. bar/line/pie by question. Title + units + zero axis. savefig(dpi, tight).

matplotlib and the shape of a plot

matplotlib is the original and most widely used plotting library in Python, and nearly everything else builds on it. You install it once (pip install matplotlib) and import its main module under a standard nickname:

python
import matplotlib.pyplot as plt

Every chart you make has the same two-part anatomy, and understanding it early saves confusion. The figure is the whole image - the canvas, the thing you save to a file. The axes are a single plot inside that figure - the area with the x and y scales where the data is actually drawn. A figure can hold one axes or several side by side. The clearest way to make a chart is to create both explicitly, draw on the axes, and then show or save the figure:

python
rooms = ["living", "kitchen", "bedroom", "study"]
areas = [24, 12, 15, 9]

fig, ax = plt.subplots()      # a figure with one axes
ax.bar(rooms, areas)          # draw the data on the axes
ax.set_ylabel("area (sqm)")
plt.show()                    # open a window to view it

plt.subplots() hands you the figure and the axes together, which is the modern, recommended way to start. You then call methods on ax to draw and label, and finish with plt.show() to view or savefig to write a file. Keep the figure-and-axes picture in mind and matplotlib's large menu of functions stops feeling random - almost all of them are just ways of drawing on, or labelling, an axes.

You will meet matplotlib written two ways online, and it helps to know why. The older style calls functions straight on plt - plt.bar(...), plt.title(...) - which quietly draws on whatever the current axes happens to be. It is fine for a quick one-off, but it gets confusing the moment you have more than one plot, because it is never quite clear which axes you are drawing on. The style this lesson uses - make fig, ax explicitly, then call ax.bar, ax.set_title - is a little more typing but far clearer, because every command names the axes it acts on. When you copy an example from the web that uses the plt.something style, you can almost always translate it by making a fig, ax and moving the drawing calls onto ax; the arguments stay the same.

FIGURE vs AXESfigure (the whole canvas -> savefig)axes (one plot, the x and y scales)y labelx labelfig, ax = plt.subplots()ax.bar(...)ax.set_title(...)ax.set_ylabel(...)fig.savefig(...)Make the figure and axes, draw and label on the axes, then save the figure. Every chart follows this shape.
Zoom
The anatomy of a matplotlib chart. The figure is the whole canvas you save to a file; the axes is the plotting area inside it, carrying the x and y scales, the title and the axis labels. Nearly every matplotlib function is a way of drawing on, or labelling, an axes.

The three charts you will use most

You do not need matplotlib's full gallery; three chart types cover the overwhelming majority of design data. A bar chart compares a value across categories - areas by room, cost by trade, count by supplier - and is the one you will reach for most:

python
fig, ax = plt.subplots()
ax.bar(rooms, areas, color="#7C3AED")
ax.set_title("Room areas")
ax.set_ylabel("area (sqm)")

A line chart shows change over a continuous axis, almost always time - monthly energy use, cost tracked across revisions, temperature over a day:

python
months = ["Jan", "Feb", "Mar", "Apr", "May", "Jun"]
kwh = [820, 760, 910, 1180, 1520, 1680]

fig, ax = plt.subplots()
ax.plot(months, kwh, marker="o")
ax.set_title("Monthly electricity use")
ax.set_ylabel("kWh")

A pie chart shows parts of a whole - a budget split, an area breakdown by use - and works only when the slices genuinely sum to a meaningful total and there are few of them:

python
fig, ax = plt.subplots()
ax.pie([214000, 30000, 56000], labels=["rcc", "plaster", "finishes"], autopct="%1.0f%%")
ax.set_title("Cost by trade")

Match the chart to the question: comparing categories is a bar, change over time is a line, share of a total is a pie. Choosing the wrong type is the most common way a technically correct chart still misleads - a pie of twelve near-equal slices tells you nothing a bar would not have told you clearly.

A quick way to decide is to name the question in words first. If the sentence is how does X compare across these groups, it is a bar. If it is how does X change over time, it is a line. If it is what share of the total does each part take, and there are only a few parts, it is a pie - and even then a bar often reads more precisely, because people judge lengths far better than they judge the angles of pie slices. There are more specialised charts for other questions - a scatter plot for the relationship between two numbers, a histogram for the distribution of a single one - but for the everyday design data of areas, costs and quantities, the bar-line-pie trio does almost all the work. Master those three and label them well before reaching for anything fancier.

Room areas - Ground floor081624livingkitchenbedroomstudy2412159area (sqm)Bar for comparing categories; y-axis from zero so heights are honest; title, units and labels present.
Zoom
A bar chart of room areas, sketched with the honesty rules that matter: a title, labelled axes with units, and a y-axis that starts at zero so the bar heights are proportional to the real values. Matching the chart type to the question - bar for comparing categories - is half of a good chart.

Labelling honestly - a chart is an argument

An unlabelled chart is not evidence, it is decoration - and a subtly mislabelled one is worse, because it persuades while being wrong. A few habits keep your charts honest and readable. Always give the axes and the chart a title and units, so a reader knows what they are looking at without asking:

python
fig, ax = plt.subplots()
ax.bar(rooms, areas, color="#0D9488")
ax.set_title("Room areas - Ground floor")
ax.set_xlabel("room")
ax.set_ylabel("area (square metres)")

The most important honesty rule for bar charts is to start the y-axis at zero. matplotlib usually does this for you, but if you override it, a bar chart that begins at 20 instead of 0 exaggerates small differences into dramatic ones - a classic way statistics mislead, and one you should never do to a client. Beyond that: rotate crowded x-labels so they stay readable (plt.xticks(rotation=45)), sort the bars so the ranking is obvious, and resist the urge to decorate - a clean chart with clear labels persuades more than a cluttered, colourful one. Because pandas is built to hand data to matplotlib, you can often skip straight from a DataFrame to a chart - by_trade.plot(kind="bar") plots a grouped Series directly - but whichever route you take, the labelling discipline is the same. The chart is making an argument on your behalf; label it so the argument is true.

Colour deserves the same restraint as scale. A single accent colour, used to pick out the one bar your point is about while the rest stay a neutral grey, communicates far more sharply than a rainbow where every bar shouts equally. If your charts sit in a report or a deck, reusing a small, consistent palette across all of them makes the whole document feel considered and lets a reader learn what a colour means once. And spare a thought for colour-blind readers, who are a meaningful share of any audience: never rely on colour alone to carry meaning - back it up with a label, a value printed on the bar, or ordering - so the chart still reads if the colours were stripped away. Honesty in a chart is not only about the numbers; it is about making sure the picture is legible to everyone who has to act on it.

Room areas - Ground floor081624livingkitchenbedroomstudy2412159area (sqm)Bar for comparing categories; y-axis from zero so heights are honest; title, units and labels present.
Zoom
A bar chart of room areas, sketched with the honesty rules that matter: a title, labelled axes with units, and a y-axis that starts at zero so the bar heights are proportional to the real values. Matching the chart type to the question - bar for comparing categories - is half of a good chart.

Title, axis labels, units, y-axis from zero. A chart is an argument - label it so it is honest.

Saving a figure for a report or a board

A chart that only appears in a pop-up window is not much use; the payoff is a clean image file you drop into a report, a drawing sheet or a presentation. savefig writes the figure to disk, and a couple of arguments make the difference between a usable image and a fuzzy, badly-cropped one:

python
fig, ax = plt.subplots(figsize=(8, 4.5))
ax.bar(rooms, areas, color="#7C3AED")
ax.set_title("Room areas")
ax.set_ylabel("area (sqm)")

fig.savefig("room_areas.png", dpi=200, bbox_inches="tight")

figsize sets the size in inches, so you control the proportions before anything is drawn. dpi=200 makes it sharp enough to print or project - the default is often too low for a report. bbox_inches="tight" trims the wasteful whitespace matplotlib leaves around the plot, so labels are not clipped and the image sits neatly on a page. Save as .png for slides and screens; save as .pdf or .svg if you need a crisp vector that scales without pixelation on a large printed sheet.

One practical note when you generate many charts in a loop: call plt.close(fig) after saving each one, so matplotlib does not hold every figure in memory. With that, you can script a whole set of charts - one per floor, one per project - and write them all to a folder in a single run. That is the module's final leverage: not one chart made by hand, but a reporting pack regenerated on command every time the underlying schedule changes.

It is worth stepping back at the close of this module to see what you have assembled. You can read a table from a CSV or an Excel workbook, look at it critically with head() and info(), clean its gaps and types and inconsistent labels on purpose, compute the areas, quantities and costs your work actually reports, collapse hundreds of line items into subtotals with groupby, write the result back to a file colleagues can open, and turn any of those numbers into an honest chart saved for a report. That is a complete data workflow - the same one used, in richer forms, across data science and the analysis-heavy corners of computational design. You do not need every function pandas and matplotlib offer; you need this arc, run confidently on your own real files. Everything from here is variation and depth on the moves you now have.

FIGURE vs AXESfigure (the whole canvas -> savefig)axes (one plot, the x and y scales)y labelx labelfig, ax = plt.subplots()ax.bar(...)ax.set_title(...)ax.set_ylabel(...)fig.savefig(...)Make the figure and axes, draw and label on the axes, then save the figure. Every chart follows this shape.
Zoom
The anatomy of a matplotlib chart. The figure is the whole canvas you save to a file; the axes is the plotting area inside it, carrying the x and y scales, the title and the axis labels. Nearly every matplotlib function is a way of drawing on, or labelling, an axes.

savefig(dpi=200, bbox_inches=tight). .png for screens, .pdf/.svg for print. plt.close() in a loop.

Functions & concepts you met in this lesson

matplotlib.pyplot

Python's core plotting library, imported as plt

The foundation nearly every other Python charting tool is built on. Learn it and the rest come easily.

figure vs axes

The whole canvas versus a single plot inside it

plt.subplots() gives you both. You draw and label on the axes, then save the figure.

ax.bar / ax.plot / ax.pie

Bar for categories, line for change over time, pie for parts of a whole

Matching the chart type to the question is half of a good chart. A pie only works for a few slices summing to a real total.

fig.savefig

Write the chart to an image file for a report or board

Use dpi=200 and bbox_inches=tight for a crisp, well-cropped image; .png for screens, .pdf or .svg for print.

Hands-on workshop

Workshop - chart your schedule and save it

You will visualise the data you produced in the last lesson: a bar chart of room areas and a pie of cost by trade, both labelled honestly and saved as sharp images ready for a report.

Python 3 with matplotlib installed (pip install matplotlib), and pandas if you read the data from a file rather than typing lists.

Given & goal
Goal: make and save two honest, labelled charts from real design data
Inputs: your areas by room and costs by trade from lesson 4.3 (or type small lists to stand in)
Time: ~40 minutes
  1. 1Import matplotlib with import matplotlib.pyplot as plt, and put your rooms and areas into two lists (or read them from your schedule with pandas).
  2. 2Make a bar chart: fig, ax = plt.subplots(figsize=(8, 4.5)); ax.bar(rooms, areas, color="#7C3AED"); then set a title, an x-label and a y-label with units.
  3. 3Confirm the y-axis starts at zero (it should by default) and rotate the x-labels if they crowd, using plt.xticks(rotation=45).
  4. 4Save it sharply with fig.savefig("areas.png", dpi=200, bbox_inches="tight"), then open the file to check the labels are not clipped.
  5. 5Make a pie of cost by trade with ax.pie(costs, labels=trades, autopct="%1.0f%%"), give it a title, and save it as trades.png the same way.
  6. 6Change one area value and re-run the whole script to watch both images regenerate - the point of scripting the charts rather than drawing them by hand.

You’ll walk away with
Two saved image files - a labelled bar chart of room areas and a labelled pie of cost by trade - produced by a script you can re-run whenever the data changes.

The worked example

Three altitudes on the same idea

Read the band that fits you — or all three.

For the architectAutomate busywork & build custom tools

Charts turn analysis into something a client or committee actually absorbs. An area breakdown by use, a cost-by-trade bar, a daylight or energy profile across the year - each lands in a meeting far harder as a clean matplotlib figure than as a table. And because the chart is scripted off your schedule, it regenerates the instant the design changes, so the deck you present is never quietly out of date with the model behind it.

For the interior designerScripts for data, schedules & layouts

A budget split as a pie or a cost-by-room bar makes the money conversation concrete. When a client can see that joinery is 40 percent of the spend, the trade-off discussion becomes real in a way a spreadsheet never manages. Plot your FF&E subtotals straight from the grouped data, label them honestly, and save crisp images into the presentation - a five-line script turns the numbers you already computed into the board that wins the decision.

For the studentA hireable computational skill

Clear data visuals lift a thesis, a portfolio and a studio crit noticeably. Being able to generate honest, well-labelled charts from your own analysis - site data, area studies, a survey - signals rigour, and matplotlib is a named skill in analysis and computational-design roles. The figure-and-axes model and the bar-line-pie choice you learn here are the same foundations the Architectural Visualization and GIS courses in this Academy build richer graphics on.

Misconception check

A chart just needs to look good - colours and 3D effects make it more impressive and persuasive.

Decoration is where charts go wrong, not where they get better. The job of a chart is to make a true comparison instantly legible, and almost every embellishment fights that job: 3D effects distort the very lengths and areas the reader is trying to compare, a rainbow of colours adds noise without meaning, and a y-axis that does not start at zero exaggerates differences dishonestly. The most persuasive charts are usually the plainest - one clear comparison, honest scales, a title and labelled axes with units, maybe a single accent colour to highlight the point. Restraint reads as competence and, more importantly, keeps the chart truthful. If a visual trick makes the data look more dramatic than it is, that is precisely the reason not to use it.
Try it

Do it yourself

Think about which chart fits which question, and what makes it honest.

  1. 1What is the difference between a figure and an axes in matplotlib?
  2. 2Which chart type suits comparing areas across rooms, and which suits energy use across twelve months?
  3. 3Why should a bar chart's y-axis start at zero?
  4. 4Which savefig arguments make an image sharp and well-cropped for a report?
  5. 5Give one situation where a pie chart is a poor choice, and say what to use instead.
Take this with you

The one line to carry out

Make a figure and axes, draw the right chart for the question - bar for categories, line for time, pie for parts of a whole - label it honestly with a title, units and a zero-based axis, and save it sharp with savefig. A scripted chart regenerates itself every time the data changes.
Take it further
References & further reading

Peer-reviewed journals & authoritative standards

  1. 01Matplotlib - Visualization with Pythonmatplotlib.org, 2026.
  2. 02MatplotlibWikipedia, 2026.
  3. 03pandas - Python Data Analysis Librarypandas.pydata.org, 2026.
  4. 04NumPyWikipedia, 2026.
Related lessons
Recap
matplotlib turns your computed data into pictures people can read. Every chart has the same anatomy - a figure you save and an axes you draw on - and plt.subplots() gives you both. Three types cover most design work: bar for comparing categories, line for change over time, pie for parts of a whole, matched to the question you are asking. Honest labelling - title, axis labels, units, and a bar axis that starts at zero - is what makes a chart evidence rather than decoration, and savefig with dpi and bbox_inches writes a crisp image straight into a report or board. Scripted, the whole reporting pack regenerates on command.
Carry forward →

That completes Working with Design Data - you can now read, clean, compute, schedule and chart the tabular data that runs a practice. The mastery check pulls the four lessons together; after it, Module 5 turns from tables to geometry, the points, vectors and transformations designers need to make form with code.

A

The author

Amogh N P

Architect, interior designer, and creative polymath. Studio Matrx began in his notebooks — his vision of design made honest, useful, and open to everyone. Its Academy is written and taught in his memory, and free, forever.

More about Amogh →