7  Several Measurements, One Category

Some categories need more than one number. A forest isn’t defined by temperature alone, or by rainfall alone, but by the two together. A heat warning depends on the temperature and on how humid the air is. A soil is sandy or clayey according to three fractions that add up to the whole. And a driving test, as Chapter 6 described, turns dozens of observations into a single word: pass or fail.

This chapter is about how several measurements become one category, and what happens to error, and to meaning, along the way.

Show the setup code
## graphics
library(ggplot2)
library(patchwork)
## biome boundaries
library(whittakerr)

7.1 Two ways to combine

There are two basic ways to do it.

The first is to partition the space the measurements make. Plot temperature against rainfall and divide the plane into regions, each one a category. The Whittaker diagram of world biomes works this way. So does the soil texture triangle, which divides every possible mix of sand, silt and clay into twelve named classes. Each measurement keeps its own axis, and the category is a region in the space between them.

Both diagrams are worth seeing whole before we use them.

Show the code
# ch07_fig0_whittaker_soil.R -- MRC chapter 7: two partitioned measurement spaces, shown in full before they are used.
# (a) Whittaker biome diagram (whittakerr: Whittaker_biomes, Ricklefs_colors); (b) USDA soil texture triangle
# (class polygons from the USDA data set shipped with ggtern; projected here to plain x-y so ggplot2 alone draws it).
library(ggplot2); library(patchwork); library(whittakerr)
wb <- Whittaker_biomes
cen <- do.call(rbind, lapply(split(wb, wb$biome), function(d) { a <- d$temp_c; b <- d$precp_cm; a2 <- c(a[-1], a[1]); b2 <- c(b[-1], b[1])
  cr <- a * b2 - a2 * b; A <- sum(cr) / 2; data.frame(biome = d$biome[1], x = sum((a + a2) * cr) / (6 * A), y = sum((b + b2) * cr) / (6 * A)) }))
cen$lab <- c('Boreal\nforest', 'Subtropical\ndesert', 'Temperate grassland/desert', 'Temperate\nrain forest', 'Temperate\nseasonal forest',
             'Tropical\nrain forest', 'Tropical seasonal\nforest/savanna', 'Tundra', 'Woodland/shrubland')[match(cen$biome, sort(unique(wb$biome)))]
cen$y[cen$biome == 'Temperate grassland/desert'] <- 16; cen$x[cen$biome == 'Temperate grassland/desert'] <- 4
cen$y[cen$biome == 'Woodland/shrubland'] <- 58; cen$x[cen$biome == 'Woodland/shrubland'] <- 6
ga <- ggplot() +
  geom_polygon(data = wb, aes(temp_c, precp_cm, group = biome_id, fill = biome), colour = 'white', linewidth = 0.4) +
  scale_fill_manual(values = Ricklefs_colors, guide = 'none') +
  geom_text(data = cen, aes(x, y, label = lab), size = 2.8, lineheight = 0.9, colour = 'grey10') +
  annotate('point', x = 10, y = 100, shape = 21, size = 3, fill = 'black', colour = 'white', stroke = 0.8) +
  annotate('segment', x = 10, y = 100, xend = 0, yend = 330, colour = 'grey20', linewidth = 0.3) +
  annotate('text', x = -15, y = 360, hjust = 0, size = 2.7, lineheight = 0.95, colour = 'grey15',
           label = 'How to read: find a place by its mean\nannual temperature and rainfall. 10 \u00B0C\nand 100 cm: temperate seasonal forest.') +
  scale_x_continuous(breaks = seq(-15, 30, 5)) +
  coord_cartesian(xlim = c(-16, 31), ylim = c(0, 450), expand = FALSE) +
  labs(x = 'mean annual temperature (\u00B0C)', y = 'annual precipitation (cm)', tag = 'a', title = 'Biomes (Whittaker)') +
  theme_minimal(base_size = 10) + theme(panel.grid.minor = element_blank(), plot.title = element_text(size = 10.5, face = 'bold'))
## soil triangle: sand at lower left, silt at lower right, clay at the top
e <- new.env(); data('USDA', package = 'ggtern', envir = e); u <- e$USDA
tx <- function(sand, silt, clay) data.frame(x = silt + clay / 2, y = clay * sqrt(3) / 2)
u <- cbind(u, tx(u$Sand * 100, u$Silt * 100, u$Clay * 100))
uc <- aggregate(cbind(x, y) ~ Label, u, mean)
uc$lab <- sub(' ', '\n', as.character(uc$Label)); uc$lab[uc$Label == 'Sandy Clay Loam'] <- 'Sandy clay\nloam'; uc$lab[uc$Label == 'Silty Clay Loam'] <- 'Silty clay\nloam'
uc$lab <- sub('\nClay', '\nclay', sub('\nLoam', '\nloam', sub('\nSand', '\nsand', uc$lab)))
uc$y[uc$Label == 'Sand'] <- 3.2; uc$x[uc$Label == 'Sand'] <- 6.5; uc$y[uc$Label == 'Loamy Sand'] <- 9.5; uc$x[uc$Label == 'Loamy Sand'] <- 16
uc$y[uc$Label == 'Silt'] <- 4.5; uc$x[uc$Label == 'Silt'] <- 90
grid <- do.call(rbind, lapply(seq(20, 80, 20), function(v) rbind(
  data.frame(g = paste0('c', v), rbind(tx(100 - v, 0, v), tx(0, 100 - v, v))),
  data.frame(g = paste0('s', v), rbind(tx(0, v, 100 - v), tx(100 - v, v, 0))),
  data.frame(g = paste0('a', v), rbind(tx(v, 0, 100 - v), tx(v, 100 - v, 0))))))
pal12 <- c('#E8D5B5', '#D9C29A', '#CDB083', '#E6CF9E', '#F0E0B0', '#F6EBC8', '#C9A97A', '#DDC9A2', '#E3D7B8', '#C7B08F', '#D3BE9C', '#EADFC6')
ex <- tx(40, 40, 20)
gb <- ggplot() +
  geom_polygon(data = u, aes(x, y, group = Label, fill = Label), colour = 'white', linewidth = 0.6) +
  geom_line(data = grid, aes(x, y, group = g), colour = 'grey55', linewidth = 0.2, linetype = 'dotted') +
  scale_fill_manual(values = setNames(pal12, levels(u$Label)), guide = 'none') +
  geom_text(data = uc, aes(x, y, label = lab), size = 2.6, lineheight = 0.9, colour = 'grey10') +
  annotate('text', x = seq(20, 80, 20) / 2 - 3.5, y = seq(20, 80, 20) * sqrt(3) / 2, label = seq(20, 80, 20), size = 2.4, colour = 'grey40') +
  annotate('text', x = 50 + seq(20, 80, 20) / 2 + 3.5, y = (100 - seq(20, 80, 20)) * sqrt(3) / 2, label = seq(20, 80, 20), size = 2.4, colour = 'grey40') +
  annotate('text', x = 100 - seq(20, 80, 20), y = -3.5, label = seq(20, 80, 20), size = 2.4, colour = 'grey40') +
  annotate('text', x = 14, y = 50, label = 'percent clay', angle = 60, size = 3, colour = 'grey25') +
  annotate('text', x = 86, y = 50, label = 'percent silt', angle = -60, size = 3, colour = 'grey25') +
  annotate('text', x = 50, y = -9, label = 'percent sand', size = 3, colour = 'grey25') +
  annotate('point', x = ex$x, y = ex$y, shape = 21, size = 3, fill = 'black', colour = 'white', stroke = 0.8) +
  annotate('segment', x = ex$x, y = ex$y, xend = 16, yend = 78, colour = 'grey20', linewidth = 0.3) +
  annotate('text', x = -5, y = 84, hjust = 0, size = 2.7, lineheight = 0.95, colour = 'grey15',
           label = 'How to read: 40% sand,\n40% silt and 20% clay\nis a loam.') +
  coord_equal(xlim = c(-6, 106), ylim = c(-12, 92), expand = FALSE) +
  labs(tag = 'b', title = 'Soil texture classes (USDA)') + theme_void(base_size = 10) +
  theme(plot.title = element_text(size = 10.5, face = 'bold'), plot.tag = element_text(face = 'bold'))
g <- ga + gb + plot_layout(widths = c(1, 1.05))
out <- 'G:/My Drive/Projects/MRC/figures'
ggsave(file.path(out, 'ch07_fig0_whittaker_soil.png'), g, width = 9.5, height = 5, dpi = 300, bg = 'white')
ggsave(file.path(out, 'ch07_fig0_whittaker_soil.pdf'), g, width = 9.5, height = 5, device = cairo_pdf)
g
Figure 7.1: Two partitioned measurement spaces: (a) Whittaker’s world biomes, by mean annual temperature and annual precipitation; (b) the USDA soil texture classes, by percent sand, silt and clay.

In the biome diagram, a place is located by its long-term mean temperature and rainfall, and the region it lands in names its vegetation: a mean of 10 °C and 100 cm of rain is temperate seasonal forest. In the soil triangle, each corner is a soil made entirely of one fraction, and every point inside is a mix. Read the three percentages along the guide lines: 40 percent sand, 40 percent silt and 20 percent clay lands in loam.

The second is to collapse the measurements into a single index first, and then cut that index into categories. The heat index combines temperature and humidity into one “feels like” number, and the warning levels are lines on that number. Wind chill does the same with temperature and wind. Body mass index divides weight by the square of height, and the familiar categories, underweight, normal, overweight and obese, are cuts at 18.5, 25 and 30.

Both approaches end with one category. They differ in what they keep. A partition remembers where in the space a reading fell. An index forgets: once two readings have the same index value, nothing in the category can tell them apart. A muscular athlete and a sedentary person of the same height and weight have the same body mass index, and the same label.

7.2 A map of measurement space

A partitioned measurement space is a map. The Whittaker diagram looks like one, with regions of color and boundaries between them, and it behaves like one. Its axes happen to be temperature and rainfall instead of longitude and latitude. The companion document in this trilogy, on maps, calls this kind of map a tile map: a surface divided into regions with no gaps and no overlaps. The biome diagram is a tile map of climate.

That also means its boundaries can be judged or computed, just as Chapter 4 described. Whittaker’s lines were judged. He drew them from what he knew of the world’s vegetation, and they are smooth because he drew them smooth. The soil triangle’s boundaries were agreed by a committee and are straight lines. Neither is wrong. Both are choices. The biome boundaries in this chapter’s figure come from my R package, whittakerr, which follows Whittaker’s lines.

The soil triangle shows one more subtlety. Sand, silt and clay are three measurements, but they must add up to 100 percent. Know two and the third is fixed. So the triangle is really a two-dimensional space drawn with three axes, which is why it’s a triangle rather than a cube.

7.3 Year by year

A category built from long-term averages describes a place’s typical climate. But no single year is typical. Each year has its own temperature and its own rainfall, and each falls somewhere on the Whittaker diagram.

Show the code
# ch07_fig1_whittaker_years.R -- MRC chapter 7: two measurements, one category, read year by year.
# Each year's mean temperature and total precipitation placed on the Whittaker biome diagram (whittakerr 0.2.0),
# against the long-term mean. Data: GHCN-Daily (NCEI) -- Denver Central Park USW00023062 (1948-2025),
# Corvallis State University USC00351862 (1896-2024; replaced Eugene 2026-11-03 -- Eugene's gauge record has an instrument shift). Years with >= 330 days of both TMAX/TMIN and PRCP; precip scaled to 365 days.
library(ggplot2); library(patchwork); library(whittakerr)
rd <- function(id) { x <- read.csv(file.path("G:/My Drive/Projects/MRC/data", paste0("GHCND_", id, ".csv")), stringsAsFactors = FALSE)
  x$yr <- as.integer(substr(x$DATE, 1, 4)); tm <- (x$TMAX + x$TMIN) / 20
  a <- do.call(rbind, lapply(split(seq_len(nrow(x)), x$yr), function(i) data.frame(yr = x$yr[i[1]],
       nT = sum(!is.na(tm[i])), nP = sum(!is.na(x$PRCP[i])), T = mean(tm[i], na.rm = TRUE), P = sum(x$PRCP[i], na.rm = TRUE) / 100)))
  a <- a[a$nT >= 330 & a$nP >= 330, ]; a$P <- a$P * 365 / a$nP; a$biome <- mapply(name_biome, a$T, a$P); a }
den <- rd("USW00023062_Denver"); den$site <- "Denver"
eug <- rd("USC00351862_Corvallis"); eug$site <- "Corvallis"
yy <- rbind(den, eug)
mn <- aggregate(cbind(T, P) ~ site, yy, mean)
nd <- c(Denver = sum(den$biome != name_biome(mean(den$T), mean(den$P))), Corvallis = sum(eug$biome != name_biome(mean(eug$T), mean(eug$P))))
wb <- Whittaker_biomes
cols <- Ricklefs_colors
ga <- ggplot() +
  geom_polygon(data = wb, aes(temp_c, precp_cm, group = biome_id, fill = biome), colour = "white", linewidth = 0.3) +
  scale_fill_manual(values = cols, name = NULL, breaks = c("Temperate rain forest", "Temperate seasonal forest", "Woodland/shrubland", "Temperate grassland/desert", "Subtropical desert", "Tropical seasonal forest/savanna", "Boreal forest")) +
  geom_label(data = data.frame(x = c(5.6, 5.6, 17.3, 17.6), y = c(192, 132, 85, 10),
             l = c('Temperate rain forest', 'Temperate seasonal forest', 'Woodland/shrubland', 'Subtropical desert')),
             aes(x, y, label = l), hjust = c(0, 0, 1, 1), size = 2.7, label.size = 0, fill = alpha('white', 0.7), colour = 'grey10', label.padding = unit(0.12, 'lines')) +
  geom_label(aes(x = 5.6, y = 10, label = 'Temperate grassland/desert'), hjust = 0, size = 2.7, label.size = 0, fill = alpha('white', 0.7), colour = 'grey10', label.padding = unit(0.12, 'lines')) +
  geom_point(data = yy, aes(T, P, shape = site), size = 1.5, colour = "grey10", fill = "white", stroke = 0.4) +
  geom_point(data = mn, aes(T, P), shape = 21, size = 4.2, stroke = 1.3, colour = "white", fill = "#b0172a") +
  annotate("segment", x = mn$T, xend = c(14.6, 14.6), y = mn$P, yend = ifelse(mn$site == "Denver", 30, 165), colour = "#b0172a", linewidth = 0.4) +
  annotate("text", x = 14.75, y = ifelse(mn$site == "Denver", 30, 165), hjust = 0, size = 3.2, colour = "#b0172a", fontface = "bold", label = paste0(mn$site, " mean")) +
  scale_shape_manual(values = c(Denver = 16, Corvallis = 24), name = "one year") +
  coord_cartesian(xlim = c(4, 19), ylim = c(0, 200), expand = FALSE) +
  labs(x = "mean annual temperature (\u00B0C)", y = "annual precipitation (cm)", tag = "a",
       caption = sprintf("How to read: each symbol is one year, placed by that year's mean temperature and total rainfall; the red dot is the long-term mean.\nDenver's mean sits in temperate grassland/desert, but %d of its %d years fall in woodland/shrubland. Corvallis's mean is temperate\nseasonal forest, but %d of its %d years are not.", nd[["Denver"]], nrow(den), nd[["Corvallis"]], nrow(eug))) +
  theme_minimal(base_size = 10.5) + theme(legend.position = "right", legend.text = element_text(size = 8), panel.grid.minor = element_blank(), plot.caption = element_text(hjust = 0, size = 8, colour = "grey20"))
yy$site <- factor(yy$site, levels = c("Corvallis", "Denver"))
gb <- ggplot(yy, aes(yr, site, fill = biome)) + geom_tile(height = 0.8, colour = "white", linewidth = 0.2) +
  scale_fill_manual(values = cols, guide = "none") +
  scale_x_continuous(breaks = seq(1900, 2020, 20), expand = c(0.005, 0)) +
  labs(x = NULL, y = NULL, tag = "b", subtitle = "The same years in order: each stripe is one year, colored by its biome. Gaps are incomplete years.") +
  theme_minimal(base_size = 10.5) + theme(panel.grid = element_blank(), plot.subtitle = element_text(size = 8.5, colour = "grey25"))
g <- ga / gb + plot_layout(heights = c(4, 1))
out <- "G:/My Drive/Projects/MRC/figures"
ggsave(file.path(out, "ch07_fig1_whittaker_years.png"), g, width = 8, height = 7.2, dpi = 300, bg = "white")
ggsave(file.path(out, "ch07_fig1_whittaker_years.pdf"), g, width = 8, height = 7.2, device = cairo_pdf)
attr(g, "stats") <- list(nd = nd, n = c(nrow(den), nrow(eug)), mn = mn)
g
Figure 7.2: Denver, Colorado (1948-2025), and Corvallis, Oregon (1896-2024), on the Whittaker biome diagram: (a) each year by its mean temperature and total rainfall; (b) the biome of each year in order.

Denver’s long-term mean falls in temperate grassland and desert. But 32 of its 78 years fall instead in woodland and shrubland, the next zone up the rainfall axis. Corvallis’s mean sits comfortably inside temperate seasonal forest, yet 55 of its 120 years fall outside it. Both stations sit close enough to a boundary that ordinary year-to-year variation carries them across it again and again.

The strips in the lower panel show the same years in order. They read like a patient’s temperature chart, taken day after day. One high reading means little. A run of them means something. And just as a doctor watches a patient near the fever line more closely than one far from it, a site near a biome boundary deserves closer watching than one in the middle.

My own reading is ecological. The category describes the conditions the vegetation has developed under, over a long time. Each year that falls outside the category is a year of stress for the plants and animals living there. A site in the middle of its biome rarely leaves it, and its biota rarely face conditions they aren’t suited to. A site near a boundary leaves often. Those boundary places are likely to be the first to show change when the climate shifts, and the strip diagram is a simple way to watch for it.

7.4 A tale of caution

We first drew this figure with Eugene, Oregon, instead of Corvallis, and its strip told a striking story. From 1970 to 1999 only about one year in ten fell outside temperate seasonal forest. Since 2000, more than two years in three have. It looked like a forest slipping toward shrubland.

It was a rain gauge. Set beside two neighbors with long records, Salem and Corvallis, Eugene’s rainfall crept upward from the 1950s until it was running about 40 percent above theirs. Then, in 1995, it dropped abruptly back into line, and it has stayed slightly below them since. That was the year the airport’s staffed weather office closed and an automated station took over. Nothing in the station’s documented history explains the earlier upward drift, and we have to leave that question open.

Neighboring stations share their weather. They don’t share their instruments. A step at one station that its neighbors don’t see points to a change in how the measurement was made, not in what was measured. The category changed because the operation changed, which is Bridgman’s point once again. Long-term monitoring is difficult, and the conditions of measurement do change. A gauge is replaced, a station moves, a tree grows up beside it. Any such change can move a site across a boundary that the vegetation never crossed.

7.5 One index, two very different days

The collapse approach has its own hazard. Take two summer afternoons. In Phoenix it’s 108 °F with 9 percent humidity, dry desert heat. In Tokyo it’s 91 °F with 60 percent humidity, the heavy air of a Japanese summer. The US heat index gives both the same value, 102, and the same category: “Extreme Caution.” The index has done exactly what it was designed to do. It has also erased the difference between the two days.

Whether that matters depends on whether the formula weighs temperature and humidity the way the human body does. And different countries have answered that question differently.

7.6 Same goal, different measurements

Japan doesn’t use the heat index. Its heat-stress warnings are based on the wet-bulb globe temperature, or WBGT, which combines air temperature, humidity, sunshine and wind, and gives humidity much more weight than the US formula does. Both systems aim at the same thing: warning people when heat becomes dangerous. They measure it in different ways, with different instruments, and they draw different categories.

Show the code
# ch07_fig2_heat_index_wbgt.R -- MRC chapter 7: two measurements collapsed into one index, then categorised --
# and two countries collapse them DIFFERENTLY (a Bridgman example).
# Data: Iowa Environmental Mesonet ASOS/METAR archive, Phoenix Sky Harbor (PHX) and Tokyo Haneda (RJTT), Jun-Sep 2021-2025.
# For each day, the hour with the highest US heat index. Heat index: NWS (Rothfusz regression with NWS adjustments; Steadman
# simple formula below 80 F). WBGT: Australian Bureau of Meteorology approximation for average daytime conditions
# (0.567 T + 0.393 e + 3.94; T in C, e vapour pressure in hPa) -- an APPROXIMATION of the shade-free WBGT Japan reports.
library(ggplot2); library(patchwork)
hi_nws <- function(T, RH) { s <- 0.5 * (T + 61 + (T - 68) * 1.2 + RH * 0.094); hi <- (s + T) / 2
  r <- -42.379 + 2.04901523*T + 10.14333127*RH - 0.22475541*T*RH - 6.83783e-3*T^2 - 5.481717e-2*RH^2 + 1.22874e-3*T^2*RH + 8.5282e-4*T*RH^2 - 1.99e-6*T^2*RH^2
  a1 <- ifelse(RH < 13 & T >= 80 & T <= 112, ((13 - RH) / 4) * sqrt(pmax(0, (17 - abs(T - 95)) / 17)), 0)
  a2 <- ifelse(RH > 85 & T >= 80 & T <= 87, ((RH - 85) / 10) * ((87 - T) / 5), 0)
  ifelse(hi >= 80, r - a1 + a2, hi) }
wbgt_bom <- function(Tf, RH) { Tc <- (Tf - 32) * 5/9; e <- RH / 100 * 6.105 * exp(17.27 * Tc / (237.7 + Tc)); 0.567 * Tc + 0.393 * e + 3.94 }
hx <- read.csv("G:/My Drive/Projects/MRC/data/iem_hourly_PHX_RJTT_JunSep_2021_2025.csv", stringsAsFactors = FALSE)
hx <- hx[is.finite(hx$tmpf) & is.finite(hx$relh), ]
hx$hi <- hi_nws(hx$tmpf, hx$relh)
hx$tz <- ifelse(hx$station == "PHX", "America/Phoenix", "Asia/Tokyo")
hx$day <- mapply(function(v, z) format(as.POSIXct(v, tz = "UTC"), "%Y-%m-%d", tz = z), hx$valid, hx$tz)
pk <- do.call(rbind, lapply(split(hx, paste(hx$station, hx$day)), function(d) d[which.max(d$hi), ]))
pk$city <- ifelse(pk$station == "PHX", "Phoenix", "Tokyo")
pk$wbgt <- wbgt_bom(pk$tmpf, pk$relh)
gr <- expand.grid(T = seq(70, 120, 0.25), RH = seq(2, 100, 0.5))
gr$hi <- hi_nws(gr$T, gr$RH); gr$wb <- wbgt_bom(gr$T, gr$RH)
gr$hic <- cut(gr$hi, c(-Inf, 80, 90, 103, 125, Inf), right = FALSE, labels = c("below 80", "Caution", "Extreme caution", "Danger", "Extreme danger"))
gr$wbc <- cut(gr$wb, c(-Inf, 21, 25, 28, 31, Inf), right = FALSE, labels = c("Almost safe", "Caution", "Warning", "Severe warning", "Danger"))
pal5 <- c("#f4f1ea", "#fbe3a2", "#f6b26b", "#e06c4f", "#a8233a")
pts <- function() list(geom_point(data = pk, aes(tmpf, relh, shape = city), size = 0.9, stroke = 0.3, colour = "grey15", fill = "white", alpha = 0.7),
  scale_shape_manual(values = c(Phoenix = 16, Tokyo = 24), name = "daily peak hour"),
  scale_x_continuous(limits = c(70, 120), expand = c(0, 0), breaks = seq(70, 120, 10)),
  scale_y_continuous(limits = c(2, 100), expand = c(0, 0)),
  labs(x = "air temperature (\u00B0F)", y = "relative humidity (%)"),
  theme_minimal(base_size = 10.5), theme(legend.text = element_text(size = 8), panel.grid.minor = element_blank()))
ex <- data.frame(city = c("Phoenix", "Tokyo"), T = c(108, 91), RH = c(9, 60))
ex$hi <- round(hi_nws(ex$T, ex$RH)); ex$wb <- round(wbgt_bom(ex$T, ex$RH), 1)
ga <- ggplot() + geom_raster(data = gr, aes(T, RH, fill = hic)) + scale_fill_manual(values = pal5, name = "US heat index\n(NWS)") + pts() +
  annotate("segment", x = ex$T, y = ex$RH, xend = c(112, 84), yend = c(33, 82), colour = "#1b6ca8", linewidth = 0.4) +
  annotate("point", x = ex$T, y = ex$RH, shape = 23, size = 3, fill = "#1b6ca8", colour = "white", stroke = 0.8) +
  annotate("label", x = c(112, 84), y = c(38, 88), hjust = 0.5, size = 2.8, colour = "#1b6ca8", fontface = "bold", fill = "white", label.r = unit(0, "pt"),
           label = sprintf("%s %d\u00B0F, %d%%:\nheat index %d", ex$city, ex$T, ex$RH, ex$hi)) + labs(tag = "a")
# (b) Tokyo only, official data: the same summer days under the US heat index (Haneda airport hourly obs, daily peak hour)
#     and Japan's MEASURED WBGT (Ministry of the Environment, Tokyo station 44132, daily maximum) -- rebuilt 2026-11-03.
mo <- read.csv("G:/My Drive/Projects/MRC/data/moe_wbgt_tokyo44132_JunSep_2021_2025.csv", stringsAsFactors = FALSE)
mo$day <- gsub("/", "-", substr(mo$t, 1, 10)); dmo <- aggregate(wo ~ day, mo[is.finite(mo$wo), ], max)
tk <- merge(pk[pk$city == "Tokyo", c("day", "hi")], dmo, by = "day")
hl <- cut(tk$hi, c(-Inf, 80, 90, 103, 125, Inf), right = FALSE, labels = levels(gr$hic))
wl <- cut(tk$wo, c(-Inf, 21, 25, 28, 31, Inf), right = FALSE, labels = levels(gr$wbc))
bb <- rbind(data.frame(scale = "US heat index", lev = levels(hl), k = 1:5, n = as.vector(table(hl))),
            data.frame(scale = "Japan WBGT (measured)", lev = levels(wl), k = 1:5, n = as.vector(table(wl))))
bb$scale <- factor(bb$scale, levels = c("Japan WBGT (measured)", "US heat index"))
bb <- bb[order(bb$scale, -bb$k), ]; bb$end <- ave(bb$n, bb$scale, FUN = cumsum); bb$mid <- bb$end - bb$n / 2
gb <- ggplot(bb) + geom_col(aes(x = n, y = scale, fill = factor(k)), width = 0.62, colour = "white", position = position_stack(reverse = FALSE)) +
  scale_fill_manual(values = setNames(pal5, 1:5), guide = "none") +
  geom_text(data = bb[bb$n >= 40, ], aes(x = mid, y = scale, label = paste0(lev, "\n", n)), size = 2.6, lineheight = 0.9,
            colour = ifelse(bb$k[bb$n >= 40] >= 4, "white", "grey15")) +
  scale_x_continuous(expand = c(0, 0)) +
  labs(x = sprintf("Tokyo summer days, June-September 2021-2025 (%d days)", nrow(tk)), y = NULL, tag = "b",
       caption = sprintf("How to read (b): the same %d Tokyo summer days, sorted by each country's scale. The US heat index calls %d of\nthem 'Danger' and puts %d below its first warning level; Japan's measured WBGT calls %d 'Danger' and only %d 'Almost safe'.\nSame air, same goal; different measurement, different categories.\n(a): each symbol is one summer day's hottest hour; colors are the US heat-index categories. Data: Iowa Environmental Mesonet\n(Phoenix, Tokyo Haneda airport observations); Japan Ministry of the Environment, measured WBGT, Tokyo station.",
         nrow(tk), sum(hl %in% c("Danger", "Extreme danger")), sum(hl == "below 80"), sum(wl == "Danger"), sum(wl == "Almost safe"))) +
  theme_minimal(base_size = 10.5) + theme(panel.grid = element_blank(), axis.text.x = element_blank(), plot.caption = element_text(hjust = 0, size = 8, colour = "grey20"))
g <- ga / gb + plot_layout(heights = c(3, 1))
out <- "G:/My Drive/Projects/MRC/figures"
ggsave(file.path(out, "ch07_fig2_heat_index_wbgt.png"), g, width = 8, height = 7.6, dpi = 300, bg = "white")
ggsave(file.path(out, "ch07_fig2_heat_index_wbgt.pdf"), g, width = 8, height = 7.6, device = cairo_pdf)
attr(g, "stats") <- list(n = nrow(tk), hl = table(hl), wl = table(wl))
g
Figure 7.3: Heat categories in Phoenix and Tokyo, June-September 2021-2025: (a) the hottest hour of each summer day on the US heat-index chart; (b) the same Tokyo days sorted by the US heat index and by Japan’s measured WBGT.

The lower panel takes the same 610 Tokyo summer days and sorts them both ways. By the US heat index, 143 of them, nearly a quarter, never reach the first warning level. By Japan’s measured WBGT, only 13 are “almost safe,” and 223 reach “Danger.” Same air, same goal, different measurement, different categories. A Tokyo resident reading an American forecast would be told not to worry on days when the Japanese system says to take care.

This is Bridgman’s lesson applied to a warning. Two operations that claim to measure “heat stress” are measuring different things, and the categories inherit the difference.

None of this is just a matter of comfort. In the summer of 2024, Tokyo’s medical examiner recorded 306 heatstroke deaths in the city’s 23 wards. Almost all of them, 291, happened indoors, and most of those who died indoors had an air conditioner they weren’t using. In the same year, Maricopa County, which includes Phoenix, recorded 602 heat-associated deaths. The categories are meant to change behavior, and the stakes are lives. Both indexes also measure the outdoor air, while the harm depends on where the person is: inside a hot apartment, or outside with no shade at all.

7.7 How many categories can several measurements hold?

George Miller, whose paper opened the Preface, noticed something about judgments made on more than one dimension at once. When people judge several properties of a stimulus together, they can sort it into more categories than with any one property alone. But the gain shrinks with each dimension added. We make crude judgments of several things at once rather than fine judgments of one.

That fits how partitioned categories are built. The Whittaker diagram has about nine biomes, the soil triangle twelve classes. Neither divides its space finely, even though the measurements behind them could support far finer divisions. The categories are sized for people to learn and use, not for the precision of the instruments.

It also suggests why combining measurements is so common for categories meant to make people act. A heat warning that asked people to weigh temperature, humidity, sun and wind for themselves would be ignored. One word, “Danger,” gets through.

7.8 What the combination costs

Combining measurements into one category is unavoidable whenever the thing we care about depends on more than one factor, and most things do. But it has costs. A partition multiplies the boundaries, so a reading near a corner can be one small error away from several different categories. An index hides its inputs, so very different conditions wear the same label. And either way, the category is only as sound as the operations behind each measurement, as Eugene’s rain gauge showed.

The category is one word. It’s worth remembering how many numbers it is standing in for.