Introduction

In HCI research, we often compare conditions to answer questions such as “Does a new user interface reduce input errors?” and “Is this novel input method faster than the existing one?” A commonly used tool to address these questions is null hypothesis significance testing (NHST), or simply hypothesis testing.

In hypothesis testing, we begin by assuming there is no difference between conditions—that is, the new interface or interaction method offers no meaningful improvement over the existing one. This assumption is the null hypothesis ($H_0$). We then collect data and ask, “If $H_0$ were true, how unlikely would our observed data be?” If the data would be highly improbable under $H_0$, we reject $H_0$ in favor of the alternative hypothesis ($H_1$), which states that a real difference exists. The logic of hypothesis testing is analogous to proof by contradiction: rather than directly proving the new interface is better, we show that our observations are inconsistent with the assumption that it is not.

In classroom practice today, hypothesis testing is typically presented as a two-phase procedure:

Researchers use various statistical tests to draw conclusions in HCI research. The choice of test depends on the type of data collected and the experimental design. T-tests are commonly used to compare the means of two conditions. A t-test is appropriate when (i) the dependent variable is continuous, (ii) two conditions are being compared, and (iii) the data are approximately normally distributed. The variants of t-test:

Design Tests
Between-subjects: different participants in each condition Independent-samples t-test / Welch’s t-test
Within-subjects: same participants in both conditions Paired t-test

Workflow (Work-in-Progress)

A hypothesis testing workflow begins by formulating a research question and specifying the null and alternative hypotheses. Next, design the study by choosing an appropriate experimental design, defining how variables will be measured, and planning data collection and sample size. After collecting the data, check the relevant assumptions and run the test suited to the design. Interpret the results using the test statistic, p-value, confidence interval, and effect size, considering both statistical and practical significance. Finally, report the study design and results clearly, including enough detail for readers to understand the analysis and its limitations.

Example: Comparing Two Input Methods

Let’s use a running example to see how a t-test is used in HCI research. Suppose a researcher wants to know whether users complete a text-entry task faster on a physical keyboard than on a touchscreen keyboard.

Independent-Samples t-Test

We’ll consider a hypothetical between-subjects study. Twenty-four participants are randomly assigned to one of two groups: 12 use a touchscreen keyboard and 12 use a physical keyboard. The dependent variable is task completion time in seconds. We can generate synthetic data as follows:

install.packages(c("tidyverse", "effectsize", "car"))

library(tidyverse)
library(effectsize)
library(car)

set.seed(42)

keyboard_data <- tibble(
  participant = paste0("P", 1:24),
  condition   = rep(c("touchscreen", "physical"), each = 12),
  time_sec    = c(
    # Touchscreen group: generally slower
    round(rnorm(12, mean = 48.5, sd = 7.2), 1),
    # Physical keyboard group: generally faster
    round(rnorm(12, mean = 39.0, sd = 6.8), 1)
  )
)

print(keyboard_data, n = 24)

We should have a pair of null and alternative hypotheses, which should look something like:

As discussed in the EDA note, always calculate summary statistics and visualize the data before testing: