What is a Single Sample Z Test?

75
Single-Sample Z Test Theoretical Explanation

description

What is a Single Sample Z Test?

Transcript of What is a Single Sample Z Test?

Page 1: What is a Single Sample Z Test?

Single-Sample Z TestTheoretical Explanation

Page 2: What is a Single Sample Z Test?

A one-sample Z-test for proportions is a test that helps us compare a population proportion with a sample proportion.

Page 3: What is a Single Sample Z Test?

A one-sample Z-test for proportions is a test that helps us compare a population proportion with a sample proportion.

30% Sample Mean

()

30% Population Mean

Page 4: What is a Single Sample Z Test?

A one-sample Z-test for proportions is a test that helps us compare a population proportion with a sample proportion.

This is the symbol for a sample

mean

30% Sample Mean

()

30% Population Mean

Page 5: What is a Single Sample Z Test?

A one-sample Z-test for proportions is a test that helps us compare a population proportion with a sample proportion.

And this is the symbol for a

population mean (called a mew)

30% Sample Mean

()

30% Population Mean

Page 6: What is a Single Sample Z Test?

A one-sample Z-test for proportions is a test that helps us compare a population proportion with a sample proportion.

Here is our question:

30% Sample Mean

()

30% Population Mean

Page 7: What is a Single Sample Z Test?

A one-sample Z-test for proportions is a test that helps us compare a population proportion with a sample proportion.

Here is our question: Are the population and the sample proportions (which supposedly have the same general characteristics as the population) statistically significantly the same or different?

30% Sample Mean

()

30% Population Mean

Page 8: What is a Single Sample Z Test?

Consider the following example:

Page 9: What is a Single Sample Z Test?

Consider the following example:A survey claims that 9 out of 10 doctors recommend aspirin for their patients with headaches. To test this claim, a random sample of 100 doctors is obtained. Of these 100 doctors, 82 indicate that they recommend aspirin. Is this claim accurate? Use alpha = 0.05

Page 10: What is a Single Sample Z Test?

Consider the following example:

Which is the sample?

A survey claims that 9 out of 10 doctors recommend aspirin for their patients with headaches. To test this claim, a random sample of 100 doctors is obtained. Of these 100 doctors, 82 indicate that they recommend aspirin. Is this claim accurate? Use alpha = 0.05

Page 11: What is a Single Sample Z Test?

Consider the following example:

Which is the sample? What is the population?

A survey claims that 9 out of 10 doctors recommend aspirin for their patients with headaches. To test this claim, a random sample of 100 doctors is obtained. Of these 100 doctors, 82 indicate that they recommend aspirin. Is this claim accurate? Use alpha = 0.05

Page 12: What is a Single Sample Z Test?

Consider the following example:

Which is the sample? What is the population?The sample proportion is .82 doctors recommending aspirin.

A survey claims that 9 out of 10 doctors recommend aspirin for their patients with headaches. To test this claim, a random sample of 100 doctors is obtained. Of these 100 doctors, 82 indicate that they recommend aspirin. Is this claim accurate? Use alpha = 0.05

Page 13: What is a Single Sample Z Test?

Consider the following example:

Which is the sample? What is the population?The sample proportion is .82 of doctors recommending aspirin.The population proportion .90 (the claim that 9 out of 10 doctors recommend aspirin).

A survey claims that 9 out of 10 doctors recommend aspirin for their patients with headaches. To test this claim, a random sample of 100 doctors is obtained. Of these 100 doctors, 82 indicate that they recommend aspirin. Is this claim accurate? Use alpha = 0.05

Page 14: What is a Single Sample Z Test?

We begin by stating the null hypothesis:

Page 15: What is a Single Sample Z Test?

We begin by stating the null hypothesis:The proportion of a sample of 100 medical doctors who recommend aspirin for their patients with headaches IS NOT statistically significantly different from the claim that 9 out of 10 doctors recommend aspirin for their patients with headaches.

Page 16: What is a Single Sample Z Test?

We begin by stating the null hypothesis:

The alternative hypothesis would be:

The proportion of a sample of 100 medical doctors who recommend aspirin for their patients with headaches IS NOT statistically significantly different from the claim that 9 out of 10 doctors recommend aspirin for their patients with headaches.

Page 17: What is a Single Sample Z Test?

We begin by stating the null hypothesis:

The alternative hypothesis would be:

The proportion of a sample of 100 medical doctors who recommend aspirin for their patients with headaches IS NOT statistically significantly different from the claim that 9 out of 10 doctors recommend aspirin for their patients with headaches.

The proportion of a sample of 100 medical doctors who recommend aspirin for their patients with headaches IS statistically significantly different from the claim that 9 out of 10 doctors recommend aspirin for their patients with headaches.

Page 18: What is a Single Sample Z Test?

State the decision rule:

Page 19: What is a Single Sample Z Test?

State the decision rule: We will calculate what is called the z statistic which will make it possible to determine the likelihood that the sample proportion (.82) is a rare or common occurrence with reference to the population proportion (.90).

Page 20: What is a Single Sample Z Test?

State the decision rule: We will calculate what is called the z statistic which will make it possible to determine the likelihood that the sample proportion (.82) is a rare or common occurrence with reference to the population proportion (.90).

If the z-statistic falls outside of the 95% common occurrences and into the 5% rare occurrences then we will conclude that it is a rare event and that the sample is different from the population and therefore reject the null hypothesis.

Page 21: What is a Single Sample Z Test?

Before we calculate this z-statistic, we must locate the z critical values.

Page 22: What is a Single Sample Z Test?

Before we calculate this z-statistic, we must locate the z critical values.

What are the z critical values? These are the values that demarcate what is the rare and the common occurrence.

Page 23: What is a Single Sample Z Test?

Let’s look at the normal distribution:

It has some important properties that make it possible for us to locate the z statistic and compare it to the z critical.

Page 24: What is a Single Sample Z Test?

Here is the mean and the median of a normal distribution.

Page 25: What is a Single Sample Z Test?

50% of the values are above and below the orange line.

50% - 50% +

Page 26: What is a Single Sample Z Test?

68% of the values fall between +1 and -1 standard deviations from the mean.

34% - 34% +

Page 27: What is a Single Sample Z Test?

68% of the values fall between +1 and -1 standard deviations from the mean.

34% - 34% +

68%

mean-1Οƒ +1Οƒ

Page 28: What is a Single Sample Z Test?

68% of the values fall between +1 and -1 standard deviations from the mean.

34% - 34% +

95%

mean-1Οƒ +1Οƒ-2Οƒ +2Οƒ

Page 29: What is a Single Sample Z Test?

Since our decision rule is .05 alpha, this means that if the z value falls outside of the 95% common occurrences we will consider it a rare occurrence.

34% - 34% +

95%

mean-1Οƒ +1Οƒ-2Οƒ +2Οƒ

Page 30: What is a Single Sample Z Test?

Since are decision rule is .05 alpha we will see if the z statistic is rare using this visual

95%

mean-1Οƒ +1Οƒ-2Οƒ +2Οƒ

2.5% 2.5%

rarerare

Page 31: What is a Single Sample Z Test?

Or common

95%

mean-1Οƒ +1Οƒ-2Οƒ +2Οƒ

Common

Page 32: What is a Single Sample Z Test?

Before we can calculate the z – statistic to see if it is rare or common we first must determine the z critical values that are associated with -2Οƒ and +2Οƒ.

95%

mean-1Οƒ +1Οƒ-2Οƒ +2Οƒ

Common

Page 33: What is a Single Sample Z Test?

We look these up in the Z table and find that they are -1.96 and +1.96

95%

mean-1Οƒ +1Οƒ-2Οƒ +2Οƒ

Common

-1.96 +1.96Z values

Page 34: What is a Single Sample Z Test?

So if the z statistic we calculate is less than -1.96 (e.g., -1.99) or greater than +1.96 (e.g., +2.30) then we will consider this to be a rare event and reject the null hypothesis and state that there is a statistically significant difference between .9 (population) and .82 (the sample).

Page 35: What is a Single Sample Z Test?

So if the z statistic we calculate is less than -1.96 (e.g., -1.99) or greater than +1.96 (e.g., +2.30) then we will consider this to be a rare event and reject the null hypothesis and state that there is a statistically significant difference between .9 (population) and .82 (the sample).

Let’s calculate the z statistic and see where if falls!

Page 36: What is a Single Sample Z Test?

So if the z statistic we calculate is less than -1.96 (e.g., -1.99) or greater than +1.96 (e.g., +2.30) then we will consider this to be a rare event and reject the null hypothesis and state that there is a statistically significant difference between .9 (population) and .82 (the sample).

Let’s calculate the z statistic and see where if falls!

We do this by using the following equation:

Page 37: What is a Single Sample Z Test?

So if the z statistic we calculate is less than -1.96 (e.g., -1.99) or greater than +1.96 (e.g., +2.30) then we will consider this to be a rare event and reject the null hypothesis and state that there is a statistically significant difference between .9 (population) and .82 (the sample).

Let’s calculate the z statistic and see where if falls!

We do this by using the following equation:𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=

οΏ½Μ‚οΏ½βˆ’π‘

βˆšπ‘ (1βˆ’π‘)𝑛

Page 38: What is a Single Sample Z Test?

So if the z statistic we calculate is less than -1.96 (e.g., -1.99) or greater than +1.96 (e.g., +2.30) then we will consider this to be a rare event and reject the null hypothesis and state that there is a statistically significant difference between .9 (population) and .82 (the sample).

Let’s calculate the z statistic and see where if falls!

We do this by using the following equation:

Zstatistic is what we are trying to find to see if it is outside or inside the z critical values (-1.96 and +1.96).

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=οΏ½Μ‚οΏ½βˆ’π‘

βˆšπ‘ (1βˆ’π‘)𝑛

Page 39: What is a Single Sample Z Test?

Here’s the problem again:

Page 40: What is a Single Sample Z Test?

A survey claims that 9 out of 10 doctors recommend aspirin for their patients with headaches. To test this claim, a random sample of 100 doctors is obtained. Of these 100 doctors, 82

indicate that they recommend aspirin. Is this claim accurate? Use alpha = 0.05

Page 41: What is a Single Sample Z Test?

A survey claims that 9 out of 10 doctors recommend aspirin for their patients with headaches. To test this claim, a random sample of 100 doctors is obtained. Of these 100 doctors, 82

indicate that they recommend aspirin. Is this claim accurate? Use alpha = 0.05

Page 42: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=οΏ½Μ‚οΏ½βˆ’π‘

βˆšπ‘ (1βˆ’π‘)𝑛

Page 43: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=οΏ½Μ‚οΏ½βˆ’π‘

βˆšπ‘ (1βˆ’π‘)𝑛

Note – this little hat () over the p means that this proportion is an

estimate of a population

Page 44: What is a Single Sample Z Test?

(.90)

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=οΏ½Μ‚οΏ½βˆ’π‘

βˆšπ‘ (1βˆ’π‘)𝑛

Page 45: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=οΏ½Μ‚οΏ½βˆ’π‘

βˆšπ‘ (1βˆ’π‘)𝑛

(100)

Page 46: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=οΏ½Μ‚οΏ½βˆ’π‘

βˆšπ‘ (1βˆ’π‘)𝑛

A survey claims that 9 out of 10 doctors recommend aspirin for their patients with headaches. To test this claim, a random sample of 100 doctors is obtained. Of these 100 doctors, 82

indicate that they recommend aspirin. Is this claim accurate? Use alpha = 0.05

(100)

Page 47: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=οΏ½Μ‚οΏ½βˆ’π‘

βˆšπ‘ (1βˆ’π‘)𝑛

A survey claims that 9 out of 10 doctors recommend aspirin for their patients with headaches. To test this claim, a random sample of 100 doctors is obtained. Of these 100 doctors, 82

indicate that they recommend aspirin. Is this claim accurate? Use alpha = 0.05

(100)

Page 48: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=οΏ½Μ‚οΏ½βˆ’π‘

βˆšπ‘ (1βˆ’π‘)𝑛

Let’s plug in the numbers

Page 49: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=.82βˆ’π‘

βˆšπ‘ (1βˆ’π‘)𝑛

Sample Proportion

Page 50: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=.82βˆ’π‘

βˆšπ‘ (1βˆ’π‘)𝑛

A survey claims that 9 out of 10 doctors recommend aspirin for their patients with headaches. To test this claim, a random sample of 100 doctors is obtained. Of these 100 doctors, 82

indicate that they recommend aspirin. Is this claim accurate? Use alpha = 0.05

Sample Proportion

Page 51: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=.82βˆ’π‘

βˆšπ‘ (1βˆ’π‘)𝑛

A survey claims that 9 out of 10 doctors recommend aspirin for their patients with headaches. To test this claim, a random sample of 100 doctors is obtained. Of these 100 doctors, 82

indicate that they recommend aspirin. Is this claim accurate? Use alpha = 0.05

Sample Proportion

Page 52: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=.82βˆ’ .90

√ .90(1βˆ’ .90)𝑛

Population Proportion

Page 53: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=.82βˆ’ .90

√ .90(1βˆ’ .90)𝑛

A survey claims that 9 out of 10 doctors recommend aspirin for their patients with headaches. To test this claim, a random sample of 100 doctors is obtained. Of these 100 doctors, 82

indicate that they recommend aspirin. Is this claim accurate? Use alpha = 0.05

Population Proportion

Page 54: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=.82βˆ’ .90

√ .90(1βˆ’ .90)𝑛

A survey claims that 9 out of 10 doctors recommend aspirin for their patients with headaches. To test this claim, a random sample of 100 doctors is obtained. Of these 100 doctors, 82

indicate that they recommend aspirin. Is this claim accurate? Use alpha = 0.05

Population Proportion

Page 55: What is a Single Sample Z Test?

The difference

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=.82βˆ’ .90

√ .90(1βˆ’ .90)𝑛

Page 56: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=βˆ’ .08

√ .90(1βˆ’ .90)𝑛

The difference

Page 57: What is a Single Sample Z Test?

Now for the denominator which is the estimated standard error. This value will help us know how many standard error units .82 and .90 are apart from one another (we already know they are .08 raw units apart)

Page 58: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=βˆ’ .08

√ .90(1βˆ’ .90)𝑛

Now for the denominator which is the estimated standard error. This value will help us know how many standard error units .82 and .90 are apart from one another (we already know they are .08 raw units apart)

Page 59: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=βˆ’ .08

√ .90(1βˆ’ .90)𝑛

Note - If the standard error is small then the z statistic will be larger. The larger the z statistics the more likely that it will exceed the -1.96 or +1.96 boundaries, compelling us to reject the null hypothesis. If it is smaller than we will not.

Page 60: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=βˆ’ .08

√ .90(1βˆ’ .90)𝑛

Let’s continue our calculations and find out:

Page 61: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=βˆ’ .08

√ .90(1βˆ’ .90)𝑛

A survey claims that 9 out of 10 doctors recommend aspirin for their patients with headaches. To test this claim, a random sample of 100 doctors is obtained. Of these 100 doctors, 82

indicate that they recommend aspirin. Is this claim accurate? Use alpha = 0.05

Let’s continue our calculations and find out:

Page 62: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=βˆ’ .08

√ .90( .10)𝑛

Let’s continue our calculations and find out:

Page 63: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=βˆ’ .08

√ .09𝑛

Let’s continue our calculations and find out:

Page 64: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=βˆ’ .08

√ .09100

Sample Size:

Page 65: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=βˆ’ .08

√ .09100

A survey claims that 9 out of 10 doctors recommend aspirin for their patients with headaches. To test this claim, a random sample of 100 doctors is obtained. Of these 100 doctors, 82

indicate that they recommend aspirin. Is this claim accurate? Use alpha = 0.05

Sample Size:

Page 66: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=βˆ’ .08

√.0009

Letβ€˜s continue our calculations:

Page 67: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=βˆ’ .08.03

Letβ€˜s continue our calculations:

Page 68: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=βˆ’2.67

Letβ€˜s continue our calculations:

Page 69: What is a Single Sample Z Test?

𝒛 π’”π’•π’‚π’•π’Šπ’”π’•π’Šπ’„=βˆ’2.67

Letβ€˜s continue our calculations:

Now we have our z statistic.

Page 70: What is a Single Sample Z Test?

Let’s go back to our distribution:

rarerare

95%

mean-1Οƒ +1Οƒ-2Οƒ +2Οƒ

Common

-1.96 +1.96

Page 71: What is a Single Sample Z Test?

Let’s go back to our distribution: So, is this result rare or common?

rarerare

95%

mean-1Οƒ +1Οƒ-2Οƒ +2Οƒ

Common

-1.96 +1.96-2.67

Page 72: What is a Single Sample Z Test?

Let’s go back to our distribution: So, is this result rare or common?

rarerare

95%

mean-1Οƒ +1Οƒ-2Οƒ +2Οƒ

Common

-1.96 +1.96

This is the Z-Statistic we

calculated

-2.67

Page 73: What is a Single Sample Z Test?

Let’s go back to our distribution: So, is this result rare or common?

rarerare

95%

mean-1Οƒ +1Οƒ-2Οƒ +2Οƒ

Common

-1.96 +1.96-2.67

This is the Z – Critical

Page 74: What is a Single Sample Z Test?

Looks like it is a rare event therefore we will reject the null hypothesis in favor of the alternative hypothesis:

Page 75: What is a Single Sample Z Test?

Looks like it is a rare event therefore we will reject the null hypothesis in favor of the alternative hypothesis:

The proportion of a sample of 100 medical doctors who recommend aspirin for their patients with headaches IS statistically significantly different from the claim that 9 out of 10 doctors recommend aspirin for their patients with headaches.