Hypothesis Testing in Simple Words

Vishal Sahu
2 min readMar 12, 2023

Hypothesis testing is a statistical method used to determine whether a statement about a population parameter is true or not. It involves testing two mutually exclusive hypotheses: the null hypothesis and the alternative hypothesis.

  • The null hypothesis (H0) states that there is no significant difference between a population parameter and a sample statistic, or that any observed difference is due to chance.
  • The alternative hypothesis (Ha) states that there is a significant difference between a population parameter and a sample statistic, or that any observed difference is not due to chance.

For example, let’s say a company wants to test whether a new ad campaign has increased their website traffic. They collect data on website traffic before and after the ad campaign, and want to determine whether there is a significant difference between the two periods.

  • The null hypothesis in this case would be that there is no significant difference between the website traffic before and after the ad campaign.
  • The alternative hypothesis would be that there is a significant difference between the two periods.
  • To test the hypothesis, the company would perform a t-test or a z-test on the data, depending on the sample size and distribution.
  • If the p-value, which measures the probability of observing a test statistic as extreme as the one observed, is less than the chosen significance level (usually 0.05 or 0.01), the null hypothesis would be rejected in favor of the alternative hypothesis, and the company would conclude that the ad campaign had a significant impact on their website traffic.
  • If the p-value is greater than the chosen significance level, the null hypothesis would be retained, and the company would conclude that there is no significant difference between the website traffic before and after the ad campaign.

--

--

Vishal Sahu

A data enthusiast and machine learning practitioner