/********************************************* * Kleinbaum, Chapter 5, Problem #5, p. 70 * *********************************************/ /* Create the Stata dataset */ capture clear input vote tvexp 35.4 28.5 58.2 48.3 46.1 40.2 45.5 34.8 64.8 50.1 52.0 44.0 37.9 27.2 48.2 37.8 41.8 27.2 54.0 46.1 40.8 31.3 61.9 50.1 36.5 31.3 32.7 24.8 53.8 42.2 24.6 23.0 31.2 30.1 42.6 36.5 49.6 40.2 56.6 46.1 end format vote tvexp %9.1f label data "Klenbaum Chapter 5, Problem #5, p. 70" label variable vote "Registered voter turnout" label variable tvexp "Percentage of campaign television expenditures" compress list, noobs sep(10) desc