About

In the solutions below, we focus on the answers to specific content questions. For code and data manipulations please see the corresponding R script at the course git repo.

Question 1

In this question, we use the 2015 RECS data to answer questions about home heating behavior.

(a) What is the national average home temperature at night in winter, among homes that use space heating?

The national average home temperature at night, in winter, among homes that use space heating is 68.1 (95% CI, 67.9-68.3) °F.

(b) Space heating fuel used, by division and urban type.

Table 1. Percents of home using different types of space heating fuels. Values are shown as percents with 95% confidenceintervals in parentheses.

(c) Comparing day and night temperatures, by division and urban type.

**Figure 1.** *Average household temperatures in winter.* This plot compare winter home temperatures of three types by divison and urban type. Generally, temperatures are warmest during the day when someone is home, cooler at night, and coolest during the day with no one at home.

Figure 1. Average household temperatures in winter. This plot compare winter home temperatures of three types by divison and urban type. Generally, temperatures are warmest during the day when someone is home, cooler at night, and coolest during the day with no one at home.

(d) National, median differences between day and night temperatures by heating equipment behavior

**Figure 2.** *Median national differences in day and night temperatures.* This figure shows the median national difference between household temperatures in winter during the day, with somoone home, and at night. The median differnce is largest, at 3 ºF, among those using a programmable thermostat.  The estimated standard errors are zero for the most commont behvarior types as the distribution of temperature differences has a large point mass near the median for these types.

Figure 2. Median national differences in day and night temperatures. This figure shows the median national difference between household temperatures in winter during the day, with somoone home, and at night. The median differnce is largest, at 3 ºF, among those using a programmable thermostat. The estimated standard errors are zero for the most commont behvarior types as the distribution of temperature differences has a large point mass near the median for these types.


Problem 2

In this question, we analyze (computer) mouse tracking experiments to show that “atypical” examples of various animal species are associated with more curvature on the path to the correct reponse. These curvature measures are a proxy for indecision or cognitive burden.

We analyze these data using linear mixed models with condition (typical vs atypical) as the sole covariate and random intercepts for subject and examplar to account for the repeated measurs nature of the data. Subject level (random) intercepts help to account for subject-to-subject differences in curvature irrespective of condition. Similarly, exmemplar (random) intercepts help to account for the fact that exemplars are repeated across subjects.

Based on the results below, in this experiment the atypcial condition had the largest effect on the average absolute deviation measure which was nearly twice as large, on average, in the atypical condition. However, comparing confidence intervals for the relative effects of condition on each curvature measure, the only statistically meaningful difference is between average absolute deviation and total distance.

**Figure 3.** *Relative effect of atypical condition on each curvature measure.*

Figure 3. Relative effect of atypical condition on each curvature measure.

Table 2. Model summaries. This table shows the relative effect (with 95% Wald confidence intervals) of the atypical condition on each of four curvature measures. Standard deviations for each variance component - subjects, exemplar, and error - are also shown with 95% confidence intervals based on the profile likelihood.
measure Relative Effect Subject Exemplar Error
Total Distance 1.18 (1.09-1.27) 0.10 (0.07-0.12) 0.07 (0.04-0.10) 0.31 (0.29-0.32)
Maximum Absolute Deviation 1.67 (1.32-2.10) 0.37 (0.27-0.47) 0.19 (0.09-0.29) 1.07 (1.03-1.12)
Average Absolute Deviation 1.92 (1.47-2.50) 0.50 (0.39-0.63) 0.22 (0.10-0.34) 1.25 (1.20-1.31)
AUC 1.42 (1.15-1.75) 0.33 (0.22-0.44) 0.14 (0.00-0.24) 1.23 (1.17-1.28)