Two researchers, Peter and Rosemary Grant, went to a small island in the Galápagos called Daphne Major with their students. Every year from 1975 to 2012 they watched the small Geospiza "finches" on that small island, and captured every single one… every single year.
In the plot below is one of those measurements, the depth of the beak, for 943 birds all measured in a single field season. 787 of them are Geospiza fortis; 156 of them are Geospiza scandens. We are going to examine the difference between these two birds the same way we did for male and female body mass.
Find a value of beak depth that minimises your error for fortis. Then find an adjustment between fortis and scandens that minimises the error for scandens.
Does knowing what species of bird you are going to catch clearly improve your prediction of its beak depth?
b <- read.csv("data/clean/finch_individuals.csv")b <- b[b$year == 1987, ]base <- 9.00adj <- 0.00guess <- base + adj * (b$species == "scandens")tapply(b$beak_depth - guess, b$species, mean)# the panel you are looking atboxplot(beak_depth ~ species, data = b, horizontal = TRUE)abline(v = c(base, base + adj))# what the label is worth on a typical birdsc <- b$beak_depth[b$species == "scandens"]mean(abs(sc - base)); mean(abs(sc - (base + adj)))
Part A showed the beak depth for hundreds of birds measured in one year, and we found clear evidence that knowing what species of bird it was improved our estimate of its beak depth. But the Grants didn't catch the birds in one year only! They caught every bird for their focal species on the island every year for 40 years!
So now we ask: does knowing what year a particular bird was caught clearly improve our prediction of beak depth if we also know its species?
We'll fit lines for both species over time separately, to see if the amount of beak-depth information knowing the year a bird was captured in is clearly different for the two species.
d <- read.csv("data/clean/finch_beak.csv")dec <- (d$year - 1973) / 10sc <- d$species == "scandens"fbase <- 9.20frate <- 0.000sadj <- 0.00sradj <- 0.000guess <- fbase + frate*dec + sc*(sadj + sradj*dec)tapply(d$beak_depth - guess, list(d$species, d$year > 1992), mean)# the same four numbers, found for youcoef(lm(beak_depth ~ dec * species, data = d))
In Part B you can see that the trends between the two birds are quite different when you have forty years of data. Which means that if you know what year the Grants were on Daphne Major, you know — from the two lines you fitted in Part B — that you need to make a different prediction for the beak depth of an unobserved Geospiza scandens than you do for an unobserved Geospiza fortis.
Most studies do not last forty years and collate everything. So here we are going to pretend the data are different than they are: instead of getting a full forty, the Grants got some number of field seasons. And we are going to ask what the lines look like, and whether the range of plausible lines still separates the birds out when you have less data.
This is a way of determining how clear the difference is, and how quickly the difference could have been noticed.
| trend estimated falling | trend estimated rising | |
|---|---|---|
| fortis | — | — |
| scandens | — | — |
d <- read.csv("data/clean/finch_beak.csv")k <- 10 # field seasons in each recordrate <- function(sp) { y <- sample(unique(d$year), k, replace = TRUE) s <- d[d$species == sp, ] s <- s[match(y, s$year), ] coef(lm(beak_depth ~ I((year - 1973)/10), data = s))[2]}cloud <- sapply(c("fortis", "scandens"), function(sp) replicate(500, rate(sp)))apply(cloud, 2, quantile, c(.025, .975))
In Parts B and C you observed that the finches changed clearly over time — in the sense that if you know what year a bird was collected, you will be less wrong about its beak depth than if you don't know what year it was collected. You also found that if you know what species a bird from Daphne Major is, you will be less wrong about its beak depth than if you don't know what species it is.
Why does time, itself, improve our ability to predict beak depth? Time doesn't impact finch populations. Geospiza fortis captured in 2010 have smaller beaks than Geospiza fortis captured in 1985… but is that due to something, or just random change? Is there a driver of beak depth?
In addition to catching birds, the Grants also watched them and saw what the birds ate. They counted the types of seeds the birds ate, and classified them into categories based on seed size and hardness.
The Grants had an hypothesis: big beaks take big energy to grow, and big seeds take big beaks to break. So if there are lots of small seeds, every bird eats, but big-beaked birds burn more calories. If there are lots of big seeds, big-beaked birds eat, but small-beaked birds starve.
They tested that idea by looking at the beak depth of birds based on whether last year there were a lot of big, hard seeds or not. You can test that same idea now.
d <- read.csv("data/clean/finch_beak.csv")s <- read.csv("data/clean/finch_seeds.csv")s$year <- s$year + 1 # last year's crop, this year's birdsd <- merge(d, s, by = "year")fresp <- 0.00sresp <- 0.00# each tilt pinned through its own species' averagesfor (sp in c("fortis", "scandens")) { k <- d$species == sp; r <- if (sp == "fortis") fresp else sresp base <- mean(d$beak_depth[k]) - r * mean(d$large_share[k]) print(mean(d$beak_depth[k] - (base + r * d$large_share[k])))}# year, before and after the crop is allowed incoef(lm(beak_depth ~ I(year/10), data = d[d$species == "fortis", ]))coef(lm(beak_depth ~ I(year/10) + large_share, data = d[d$species == "fortis", ]))