Hypothesis Tests for Proportion

Hypothesis Tests for Proportion

This is also called the “p test”

When comparing proportions that are from a population with a fixed number of independent trails and each trial has a constant probability of one or another outcome (Bernoulli experiments) then we can use a p test. p is the probability of success, and 1-p is the probability of failure. Caution: stay consistent once you define success otherwise, like me, you’ll have a bit of confusion. n is the number of trials.

The exact way to solve these problems is with the Binomial distribution, yet when np and n(1-p) is greater than 5, then the normal distribution provides similar results. The use of the Binomial distribution is calculation intensive thus when possible we tend to use the normal distribution for the calculations.

Let’s say we want to compare a proportion, p, to a fixed value, po. Like other hypothesis tests we have three comparisons possible. The null hypothesis, Ho, could be equal to, greater than, or less than the fixed value, po. The alternative hypothesis  Ha, defines the contrary conditions.

The three cases then are:

The population proportion of successes is equal to a fixed (given) value.

\displaystyle \begin{array}{l}{{H}_{o}}:p={{p}_{o}}\\{{H}_{a}}:p\ne {{p}_{o}}\end{array}

The population proportion of successes is less then or equal to a fixed value.

\displaystyle \begin{array}{l}{{H}_{o}}:p\le {{p}_{o}}\\{{H}_{o}}:p>{{p}_{o}}\end{array}

The population proportion of successes is greater than or equal to a fixed value.

\displaystyle \begin{array}{l}{{H}_{o}}:p\ge {{p}_{o}}\\{{H}_{o}}:p<{{p}_{o}}\end{array}

The test statistic is given by

\displaystyle z=\frac{x-n{{p}_{o}}}{\sqrt{n{{p}_{o}}\left( 1-{{p}_{o}} \right)}}


x is the number of successes out of the

n trials

po is the fixed proportion being compared to the data.

A great way to remember the formula for the test statistic is the number of success in the sample is compared to the mean value, npo , and divided by the standard deviation, which is the square root of npo (1- po ).

Example Problem

Let’s consider an example. Let’s say we’re inspecting corn from a test field. If the inspection accepts 30% of the sample or better, we conclude the field produces corn that is as good as or better than an average field of corn. We sample 150 ears of corn and find that 60 of the sample of 150 failed the inspection. Is there convincing evidence the test field has a higher failure rate than an average field? Use alpha = 0.05.


The null and alternative hypothesis are

\displaystyle \begin{array}{l}{{H}_{o}}:p\le 0.30\\{{H}_{o}}:p>0.30\end{array}

The test statistic is

\displaystyle z=\frac{x-n{{p}_{o}}}{\sqrt{n{{p}_{o}}\left( 1-{{p}_{o}} \right)}}

The rejection region for α = 0.05 means we will reject Ho if

\displaystyle z>1.645

Using the sample data, first determine the number of successes, x = 60, (those that fail the test as we defined above).

To be certain we can use the normal approximation, check that npo = 45, and npo(1-po) = 105. Both are greater than 5, so we may proceed with the normal approximation.

The test statistic is then

\displaystyle z=\frac{0.4-0.3}{\sqrt{150\times 0.3\times 0.7}}=2.67

Since the observed z value is greater than the test statistic it is in the rejection region and we reject the null hypothesis. We conclude that there is convincing evidence that the test field has a lower yield (higher inspection failures) then the expected average result.

This entry was posted in II. Probability and Statistics for Reliability and tagged by Fred Schenkelberg. Bookmark the permalink.

About Fred Schenkelberg

I am an experienced reliability engineering and management consultant with FMS Reliability, a consulting firm I founded in 2004. I left Hewlett Packard (HP)’s Reliability Team, where I helped create a culture of reliability across the organization, to assist other organizations. Given the scope of my work, I am considered an international authority on reliability engineering. My passion is working with teams to improve product reliability, customer satisfaction, and efficiencies in product development; and to reduce product risk and warranty costs. I have a Bachelor of Science in Physics from the United States Military Academy and a Master of Science in Statistics from Stanford University.

3 thoughts on “Hypothesis Tests for Proportion

  1. Pingback: Hypothesis Test Selection | CRE preparation notes

  2. Pingback: Sample Size and Z1.4 | Ask the Experts

  3. Pingback: Two Proportions Hypothesis Testing | CRE preparation notes

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s