ETC5521 Worksheet Week 9
Exploring data having a space and time context Part I
Exercise 1: Men’s heights
The heights
data provided in the brolgar
package contains average male heights in 144 countries from 1500-1989.
- What’s the time index for this data? What is the key?
- Filter the data to keep only measurements since 1700, when there are records for many countries. Make a spaghetti plot for the values from Australia. Does it look like Australian males are getting taller?
- Check the number of observations for each country. How many countries have less than five years of measurements? Filter these countries out of the data, because we can’t study temporal trend without sufficient measurements.
- Make a spaghetti plot of all the data, with a smoother overlaid. Does it look like men are generally getting taller?
- Use
facet_strata
to break the data into subsets using theyear
, and plot is several facets. What sort of patterns are there in terms of the earliest year that a country appears in the data?
- Compute the three number summary (min, median, max) for each country. Make density plots of these statistics, overlaid in a single plot, and a parallel coordinate plot of these three statistics. What is the average minimum (median, maximum) height across countries? Are there some countries who have roughly the same minimum, median and maximum height?
- Which country has the tallest men? Which country has highest median male height? Which country has the shortest men? Would you say that the distribution of heights within a country is similar for all countries?