<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE document PUBLIC "-//CNX//DTD CNXML 0.5 plus MathML//EN" "http://cnx.rice.edu/cnxml/0.5/DTD/cnxml_mathml.dtd">
<document xmlns="http://cnx.rice.edu/cnxml" xmlns:md="http://cnx.rice.edu/mdml/0.4" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:bib="http://bibtexml.sf.net/" id="id7259670">
  <name>Sample Size</name>
  <metadata>
  <md:version>1.1</md:version>
  <md:created>2008/08/07 16:34:27.733 GMT-5</md:created>
  <md:revised>2008/08/12 15:53:55.538 GMT-5</md:revised>
  <md:authorlist>
      <md:author id="tteegard">
      <md:firstname>Mary</md:firstname>
      <md:othername>T</md:othername>
      <md:surname>Teegarden</md:surname>
      <md:email>tteegard@sdccd.edu</md:email>
    </md:author>
  </md:authorlist>

  <md:maintainerlist>
    <md:maintainer id="tteegard">
      <md:firstname>Mary</md:firstname>
      <md:othername>T</md:othername>
      <md:surname>Teegarden</md:surname>
      <md:email>tteegard@sdccd.edu</md:email>
    </md:maintainer>
  </md:maintainerlist>
  
  <md:keywordlist>
    <md:keyword>confidence intervals</md:keyword>
    <md:keyword>sample size</md:keyword>
  </md:keywordlist>

  <md:abstract>Calculations for determining the required sample sized when calculation a confidence interval for the population mean or population proportion.</md:abstract>
</metadata>
  <content>
    
    <para id="id9278698"><name>Determining Sample Size Required to Estimate μ.</name>Prior to creating a confidence interval a sample must be taken. Often the number of data values needed in a sample to obtain a particular level of confidence within a given error needs to be determined prior to taking the sample. If the sample is too small the result may not be useful and if the sample is too big both time and money are wasted in the sampling.</para>
    <para id="id10044207">From the formula for the error bound, the following formula can be derived:</para>
    
    <equation id="id10107801"><name>Sample Size for Estimating Mean μ</name><m:math>
        <m:semantics>
          <m:mrow>
            <m:mstyle fontsize="12pt">
              <m:mrow>
                <m:mrow>
                  <m:mi>n</m:mi>
                  <m:mo stretchy="false">=</m:mo>
                  <m:msup>
                    <m:mfenced open="[" close="]">
                      <m:mfrac>
                        <m:mrow>
                          <m:msub>
                            <m:mi>z</m:mi>
                            <m:mstyle fontsize="8pt">
                              <m:mrow>
                                <m:mrow>
                                  <m:mi>α</m:mi>
                                  <m:mo stretchy="false">/</m:mo>
                                  <m:mn>2</m:mn>
                                </m:mrow>
                              </m:mrow>
                            </m:mstyle>
                          </m:msub>
                          <m:mi>σ</m:mi>
                        </m:mrow>
                        <m:mi>E</m:mi>
                      </m:mfrac>
                    </m:mfenced>
                    <m:mstyle fontsize="8pt">
                      <m:mrow>
                        <m:mn>2</m:mn>
                      </m:mrow>
                    </m:mstyle>
                  </m:msup>
                </m:mrow>
              </m:mrow>
            </m:mstyle>
            <m:mrow/>
          </m:mrow>
          <m:annotation encoding="StarMath 5.0"> size 12{n= left [ {  {z rSub { size 8{ {α} slash {2} } } σ}  over  {E} }  right ] rSup { size 8{2} } } {}</m:annotation>
        </m:semantics>
      </m:math>
    </equation>
    <list id="element-87" type="bulleted"><item>Where 
<m:math><m:semantics><m:mrow><m:mstyle fontsize="12pt"><m:mrow><m:msub><m:mi>z</m:mi><m:mstyle fontsize="8pt"><m:mrow><m:mrow><m:mi>α</m:mi><m:mo stretchy="false">/</m:mo><m:mn>2</m:mn></m:mrow></m:mrow></m:mstyle></m:msub></m:mrow></m:mstyle><m:mrow/></m:mrow><m:annotation encoding="StarMath 5.0"> size 12{z rSub { size 8{ {α} slash {2} } } } {}</m:annotation></m:semantics></m:math> = the critical z score based on the desired confidence level</item>
<item>E = desired margin of error</item>
<item>σ = population standard deviation</item></list>
    
    
    <para id="id7825168">Often the population standard deviation is unknown. Often the sample standard deviation from a previous sample of size greater than 30 may be used as an approximation to σ.</para>
    <para id="id9784566"><name>Round Off Rule for Sample Size n</name>Often times the value found by using the formula for sample size is not a whole number. However the sample size must be a whole number, so always round up to the next larger whole number.</para>
    <para id="id9655436"><name>Example</name>Suppose the scores on a statistics final are normally distributed with a standard deviation of 10 points. You have been asked to construct a 95% confidence interval with an error of no more than 2 points.</para>
    <section id="id10035079">
      <para id="id9956488"><m:math><m:semantics><m:mrow><m:mstyle fontsize="12pt"><m:mrow><m:msub><m:mi>z</m:mi><m:mstyle fontsize="8pt"><m:mrow><m:mrow><m:mn>0</m:mn><m:mtext>.</m:mtext><m:mtext>25</m:mtext></m:mrow></m:mrow></m:mstyle></m:msub></m:mrow></m:mstyle><m:mrow/></m:mrow><m:annotation encoding="StarMath 5.0"> size 12{z rSub { size 8{0 "." "25"} } } {}</m:annotation></m:semantics></m:math> = 1.645</para>
      <para id="id10453272">E = 2</para>
      <para id="id10038737">σ = 10</para>
      <para id="id10036850"><m:math><m:semantics><m:mrow><m:mstyle fontsize="12pt"><m:mrow><m:mrow><m:mrow><m:mi>n</m:mi><m:mo stretchy="false">=</m:mo><m:msup><m:mfenced open="[" close="]"><m:mfrac><m:mrow><m:msub><m:mi>z</m:mi><m:mstyle fontsize="8pt"><m:mrow><m:mrow><m:mi>α</m:mi><m:mo stretchy="false">/</m:mo><m:mn>2</m:mn></m:mrow></m:mrow></m:mstyle></m:msub><m:mi>σ</m:mi></m:mrow><m:mi>E</m:mi></m:mfrac></m:mfenced><m:mstyle fontsize="8pt"><m:mrow><m:mn>2</m:mn></m:mrow></m:mstyle></m:msup></m:mrow><m:mo stretchy="false">=</m:mo><m:msup><m:mfenced open="[" close="]"><m:mfrac><m:mrow><m:mo stretchy="false">(</m:mo><m:mn>1</m:mn><m:mtext>.</m:mtext><m:mtext>645</m:mtext><m:mo stretchy="false">)</m:mo><m:mo stretchy="false">(</m:mo><m:mtext>10</m:mtext><m:mo stretchy="false">)</m:mo></m:mrow><m:mn>2</m:mn></m:mfrac></m:mfenced><m:mstyle fontsize="8pt"><m:mrow><m:mn>2</m:mn></m:mrow></m:mstyle></m:msup></m:mrow></m:mrow></m:mstyle><m:mrow/></m:mrow><m:annotation encoding="StarMath 5.0"> size 12{n= left [ {  {z rSub { size 8{ {α} slash {2} } } σ}  over  {E} }  right ] rSup { size 8{2} } = left [ {  { \( 1 "." "645" \)  \( "10" \) }  over  {2} }  right ] rSup { size 8{2} } } {}</m:annotation></m:semantics></m:math>= 67.6506</para>
    </section>
    <section id="id8330364">
      <para id="id8330367">Hence, a sample of size 68, must be taken to create a 95% confidence interval with an error of no more than two points.</para>
      
      <para id="id9974940"><name>Determining Sample Size Required to Estimate p.</name>To determine the sample size necessary to ensure a given error for a particular confidence level, the formula for the error bound can be rewritten as follows:</para>
      <equation id="id9956765">
        <m:math>
          <m:semantics>
            <m:mrow>
              <m:mstyle fontsize="12pt">
                <m:mrow>
                  <m:mrow>
                    <m:mrow>
                      <m:mi>n</m:mi>
                      <m:mo stretchy="false">=</m:mo>
                      <m:msup>
                        <m:mfenced open="[" close="]">
                          <m:mfrac>
                            <m:msub>
                              <m:mi>z</m:mi>
                              <m:mstyle fontsize="8pt">
                                <m:mrow>
                                  <m:mrow>
                                    <m:mi>α</m:mi>
                                    <m:mo stretchy="false">/</m:mo>
                                    <m:mn>2</m:mn>
                                  </m:mrow>
                                </m:mrow>
                              </m:mstyle>
                            </m:msub>
                            <m:mi>E</m:mi>
                          </m:mfrac>
                        </m:mfenced>
                        <m:mstyle fontsize="8pt">
                          <m:mrow>
                            <m:mn>2</m:mn>
                          </m:mrow>
                        </m:mstyle>
                      </m:msup>
                    </m:mrow>
                    <m:mi>p</m:mi>
                    <m:mo stretchy="false">(</m:mo>
                    <m:mrow>
                      <m:mn>1</m:mn>
                      <m:mo stretchy="false">−</m:mo>
                      <m:mi>p</m:mi>
                    </m:mrow>
                    <m:mo stretchy="false">)</m:mo>
                  </m:mrow>
                </m:mrow>
              </m:mstyle>
              <m:mrow/>
            </m:mrow>
            <m:annotation encoding="StarMath 5.0"> size 12{n= left [ {  {z rSub { size 8{ {α} slash {2} } } }  over  {E} }  right ] rSup { size 8{2} } p \( 1 - p \) } {}</m:annotation>
          </m:semantics>
        </m:math>
      </equation>
      <list id="element-195" type="bulleted"><item>Where 
<m:math><m:semantics><m:mrow><m:mstyle fontsize="12pt"><m:mrow><m:msub><m:mi>z</m:mi><m:mstyle fontsize="8pt"><m:mrow><m:mrow><m:mi>α</m:mi><m:mo stretchy="false">/</m:mo><m:mn>2</m:mn></m:mrow></m:mrow></m:mstyle></m:msub></m:mrow></m:mstyle><m:mrow/></m:mrow><m:annotation encoding="StarMath 5.0"> size 12{z rSub { size 8{ {α} slash {2} } } } {}</m:annotation></m:semantics></m:math> = the critical z score based on the desired confidence level</item>
<item>E = desired margin of error</item>
<item> p = population proportion</item></list>
      
      
      <para id="id10074668">Generally the population proportion is unknown and p’ is determined using a previous sample. Hence </para>
      <equation id="id9910196">
        <m:math>
          <m:semantics>
            <m:mrow>
              <m:mstyle fontsize="12pt">
                <m:mrow>
                  <m:mrow>
                    <m:mrow>
                      <m:mi>n</m:mi>
                      <m:mo stretchy="false">=</m:mo>
                      <m:msup>
                        <m:mfenced open="[" close="]">
                          <m:mfrac>
                            <m:msub>
                              <m:mi>z</m:mi>
                              <m:mstyle fontsize="8pt">
                                <m:mrow>
                                  <m:mrow>
                                    <m:mi>α</m:mi>
                                    <m:mo stretchy="false">/</m:mo>
                                    <m:mn>2</m:mn>
                                  </m:mrow>
                                </m:mrow>
                              </m:mstyle>
                            </m:msub>
                            <m:mi>E</m:mi>
                          </m:mfrac>
                        </m:mfenced>
                        <m:mstyle fontsize="8pt">
                          <m:mrow>
                            <m:mn>2</m:mn>
                          </m:mrow>
                        </m:mstyle>
                      </m:msup>
                    </m:mrow>
                    <m:mi>p</m:mi>
                    <m:mi>'</m:mi>
                    <m:mo stretchy="false">(</m:mo>
                    <m:mrow>
                      <m:mn>1</m:mn>
                      <m:mo stretchy="false">−</m:mo>
                      <m:mi>p</m:mi>
                    </m:mrow>
                    <m:mi>'</m:mi>
                    <m:mo stretchy="false">)</m:mo>
                  </m:mrow>
                </m:mrow>
              </m:mstyle>
              <m:mrow/>
            </m:mrow>
            <m:annotation encoding="StarMath 5.0"> size 12{n= left [ {  {z rSub { size 8{ {α} slash {2} } } }  over  {E} }  right ] rSup { size 8{2} } p' \( 1 - p' \) } {}</m:annotation>
          </m:semantics>
        </m:math>
      </equation>
      <para id="id9768519">If there is no previous sample then p = 0.5 is used since it maximized the value of p(1 - p). Hence </para>
      <equation id="id10067886">
        <m:math>
          <m:semantics>
            <m:mrow>
              <m:mstyle fontsize="12pt">
                <m:mrow>
                  <m:mrow>
                    <m:mrow>
                      <m:mi>n</m:mi>
                      <m:mo stretchy="false">=</m:mo>
                      <m:msup>
                        <m:mfenced open="[" close="]">
                          <m:mfrac>
                            <m:msub>
                              <m:mi>z</m:mi>
                              <m:mstyle fontsize="8pt">
                                <m:mrow>
                                  <m:mrow>
                                    <m:mi>α</m:mi>
                                    <m:mo stretchy="false">/</m:mo>
                                    <m:mn>2</m:mn>
                                  </m:mrow>
                                </m:mrow>
                              </m:mstyle>
                            </m:msub>
                            <m:mi>E</m:mi>
                          </m:mfrac>
                        </m:mfenced>
                        <m:mstyle fontsize="8pt">
                          <m:mrow>
                            <m:mn>2</m:mn>
                          </m:mrow>
                        </m:mstyle>
                      </m:msup>
                    </m:mrow>
                    <m:mn>0</m:mn>
                    <m:mtext>.</m:mtext>
                    <m:mn>5</m:mn>
                    <m:mo stretchy="false">(</m:mo>
                    <m:mrow>
                      <m:mn>1</m:mn>
                      <m:mo stretchy="false">−</m:mo>
                      <m:mn>0</m:mn>
                    </m:mrow>
                    <m:mtext>.</m:mtext>
                    <m:mn>5</m:mn>
                    <m:mrow>
                      <m:mo stretchy="false">)</m:mo>
                      <m:mo stretchy="false">=</m:mo>
                      <m:msup>
                        <m:mfenced open="[" close="]">
                          <m:mfrac>
                            <m:msub>
                              <m:mi>z</m:mi>
                              <m:mstyle fontsize="8pt">
                                <m:mrow>
                                  <m:mrow>
                                    <m:mi>α</m:mi>
                                    <m:mo stretchy="false">/</m:mo>
                                    <m:mn>2</m:mn>
                                  </m:mrow>
                                </m:mrow>
                              </m:mstyle>
                            </m:msub>
                            <m:mi>E</m:mi>
                          </m:mfrac>
                        </m:mfenced>
                        <m:mstyle fontsize="8pt">
                          <m:mrow>
                            <m:mn>2</m:mn>
                          </m:mrow>
                        </m:mstyle>
                      </m:msup>
                    </m:mrow>
                    <m:mn>0</m:mn>
                    <m:mtext>.</m:mtext>
                    <m:mtext>25</m:mtext>
                  </m:mrow>
                </m:mrow>
              </m:mstyle>
              <m:mrow/>
            </m:mrow>
            <m:annotation encoding="StarMath 5.0"> size 12{n= left [ {  {z rSub { size 8{ {α} slash {2} } } }  over  {E} }  right ] rSup { size 8{2} } 0 "." 5 \( 1 - 0 "." 5 \) = left [ {  {z rSub { size 8{ {α} slash {2} } } }  over  {E} }  right ] rSup { size 8{2} } 0 "." "25"} {}</m:annotation>
          </m:semantics>
        </m:math>
      </equation>
      <para id="id9910177">Suppose Halmark wish to know what proportion of oldest children buy their mothers a Mother’s Day Card. (See example 8 -5) How many people must be sampled is they wish to be 95% certain that the proportion is within 2%?</para>
      <para id="id5885923">a) Use the following sample data as an estimate for the population proportion.</para>
      <para id="id9949731">Given that 421 of 500 responded in the affirmative, p’ = 
<m:math><m:semantics><m:mrow><m:mstyle fontsize="12pt"><m:mrow><m:mfrac><m:mtext>421</m:mtext><m:mtext>500</m:mtext></m:mfrac></m:mrow></m:mstyle><m:mrow/></m:mrow><m:annotation encoding="StarMath 5.0"> size 12{ {  {"421"}  over  {"500"} } } {}</m:annotation></m:semantics></m:math>= 0.842</para>
    </section>
    <section id="id10052693">
      <para id="id10104754"><m:math><m:semantics><m:mrow><m:mstyle fontsize="12pt"><m:mrow><m:msub><m:mi>z</m:mi><m:mstyle fontsize="8pt"><m:mrow><m:mrow><m:mn>0</m:mn><m:mtext>.</m:mtext><m:mtext>25</m:mtext></m:mrow></m:mrow></m:mstyle></m:msub></m:mrow></m:mstyle><m:mrow/></m:mrow><m:annotation encoding="StarMath 5.0"> size 12{z rSub { size 8{0 "." "25"} } } {}</m:annotation></m:semantics></m:math> = 1.645</para>
      <para id="id9277673">E = 0.02</para>
      <para id="id10106200">p’ = 0.842</para>
      <para id="id10106204"><m:math><m:semantics><m:mrow><m:mstyle fontsize="12pt"><m:mrow><m:mrow><m:mrow><m:mi>n</m:mi><m:mo stretchy="false">=</m:mo><m:msup><m:mfenced open="[" close="]"><m:mfrac><m:mrow><m:mn>1</m:mn><m:mtext>.</m:mtext><m:mtext>645</m:mtext></m:mrow><m:mrow><m:mn>0</m:mn><m:mtext>.</m:mtext><m:mtext>02</m:mtext></m:mrow></m:mfrac></m:mfenced><m:mstyle fontsize="8pt"><m:mrow><m:mn>2</m:mn></m:mrow></m:mstyle></m:msup></m:mrow><m:mn>0</m:mn><m:mtext>.</m:mtext><m:mtext>842</m:mtext><m:mo stretchy="false">(</m:mo><m:mn>0</m:mn><m:mtext>.</m:mtext><m:mtext>158</m:mtext><m:mo stretchy="false">)</m:mo></m:mrow></m:mrow></m:mstyle><m:mrow/></m:mrow><m:annotation encoding="StarMath 5.0"> size 12{n= left [ {  {1 "." "645"}  over  {0 "." "02"} }  right ] rSup { size 8{2} } 0 "." "842" \( 0 "." "158" \) } {}</m:annotation></m:semantics></m:math>= 899.997</para>
    </section>
    <section id="id10049293">
      <para id="id9039362">Hence 900 people need to be surveyed to ensure a 95% confidence interval with an error of at most 2%.</para>
      <para id="id10490625">b) Suppose there is no previous sample. How many people need to be surveyed? </para>
    </section>
    <section id="id9906743">
      <para id="id10071898"><m:math><m:semantics><m:mrow><m:mstyle fontsize="12pt"><m:mrow><m:msub><m:mi>z</m:mi><m:mstyle fontsize="8pt"><m:mrow><m:mrow><m:mn>0</m:mn><m:mtext>.</m:mtext><m:mtext>25</m:mtext></m:mrow></m:mrow></m:mstyle></m:msub></m:mrow></m:mstyle><m:mrow/></m:mrow><m:annotation encoding="StarMath 5.0"> size 12{z rSub { size 8{0 "." "25"} } } {}</m:annotation></m:semantics></m:math> = 1.645</para>
      <para id="id10045796">E = 0.02</para>
      <para id="id9974922">assume p = 0.5</para>
      <para id="id10045679"><m:math><m:semantics><m:mrow><m:mstyle fontsize="12pt"><m:mrow><m:mrow><m:mrow><m:mi>n</m:mi><m:mo stretchy="false">=</m:mo><m:msup><m:mfenced open="[" close="]"><m:mfrac><m:mrow><m:mn>1</m:mn><m:mtext>.</m:mtext><m:mtext>645</m:mtext></m:mrow><m:mrow><m:mn>0</m:mn><m:mtext>.</m:mtext><m:mtext>02</m:mtext></m:mrow></m:mfrac></m:mfenced><m:mstyle fontsize="8pt"><m:mrow><m:mn>2</m:mn></m:mrow></m:mstyle></m:msup></m:mrow><m:mn>0</m:mn><m:mtext>.</m:mtext><m:mtext>25</m:mtext></m:mrow></m:mrow></m:mstyle><m:mrow/></m:mrow><m:annotation encoding="StarMath 5.0"> size 12{n= left [ {  {1 "." "645"}  over  {0 "." "02"} }  right ] rSup { size 8{2} } 0 "." "25"} {}</m:annotation></m:semantics></m:math>= 1691.27</para>
    </section>
    <section id="id9891892">
      <para id="id10107455">Hence 1692 people need to be surveyed to ensure a 95% confidence interval with an error of at most 2%.</para>
      <para id="id9925006">Note that not having a previous sample greatly increases the number of data values needed in a sample. Often a pilot study is done to generate an approximation for p.</para>
    </section>
  </content>
</document>
