Command Palette

Search for a command to run...

Hectal
Phase 13: Maps, Hierarchies and Networks
Data Visualization · Exercise 3 of 4 PreviousNext
Intermediate

A treemap that has no rectangles

A small fleet is laid out as a treemap, but no rectangle has a size and the console shows NaN errors.

Make the layout work so that each of the four stations gets a rectangle, and the biggest station gets the biggest area.

What Check tests

  1. Four rectangles are drawn
  2. No NaN in the drawing
  3. The biggest station has the biggest area

Stuck? One hint at a time

The solution unlocks after your first Check. Try first: that is where the learning happens.

Runs in your browser. Your code is saved here.

Your page

Press Run to see the page.

Console

Nothing logged yet.