#set document(title: "8.3 One-Sample Interval for the Mean", author: "Kathryn Kozak") #set page(width: 8.5in, height: auto, margin: 1in) #import "@preview/cetz:0.5.2" #set text(font: ("STIX Two Text", "Libertinus Serif", "New Computer Modern"), size: 10.5pt, lang: "en") #show math.equation: set text(font: ("STIX Two Math", "New Computer Modern Math")) #set par(justify: true, leading: 0.62em, spacing: 0.9em) #set enum(spacing: 1.1em) // room between list items so tall inline fractions don't collide #set list(spacing: 1.1em) #set table(stroke: 0.5pt + rgb("#c7ccd3")) #let BLUE = rgb("#183B6F") // brand navy — section bars + example/solution labels (white on navy 11.09:1) #let ORANGE = rgb("#A94509") // brand primary-700 — AA-safe deep orange for TEXT (5.93:1 on white; raw brand #F37021 is 2.94:1 and must never carry text) #let RED = rgb("#DC2626") // brand error-600 #let GREEN = rgb("#059669") // brand success-600 (decoration only; small green text uses green-text #007942) #show heading.where(level: 1): it => block(width: 100%, above: 0pt, below: 16pt, fill: gradient.linear(BLUE, rgb("#2C5AA0")), inset: (x: 14pt, y: 12pt), radius: 3pt, text(fill: white, weight: "bold", size: 19pt, it.body)) #show heading.where(level: 2): it => block(width: 100%, above: 18pt, below: 10pt, fill: BLUE, inset: (x: 10pt, y: 6pt), radius: 2pt, text(fill: white, weight: "bold", size: 12pt, it.body)) #show heading.where(level: 3): it => text(fill: ORANGE, weight: "bold", size: 12.5pt, it.body) #show heading.where(level: 4): it => text(fill: BLUE, weight: "bold", size: 10.5pt, it.body) #let examplebox(label, title, body) = block(width: 100%, breakable: true, fill: rgb("#EFF1F5"), stroke: 0.5pt + rgb("#CFDDF0"), radius: 4pt, inset: 10pt, above: 12pt, below: 12pt)[ #block(below: 6pt)[#box(fill: BLUE, inset: (x: 6pt, y: 2pt), radius: 2pt, text(fill: white, weight: "bold", size: 8.5pt, label)) #h(0.4em) #strong[#title]] #body] // rail = decorative left rule (raw brand token); labelcolor = AA-safe label text shade #let notebox(label, rail, labelcolor, tint, body) = block(width: 100%, breakable: true, fill: tint, stroke: (left: 3pt + rail), inset: (left: 10pt, rest: 8pt), radius: (right: 4pt), above: 11pt, below: 11pt)[ #text(fill: labelcolor, weight: "bold", size: 7.5pt, tracking: 0.5pt)[#upper(label)] #linebreak() #body] #let solutionbox(body) = block(above: 4pt, below: 8pt)[ #text(fill: BLUE, weight: "bold", size: 8.5pt)[Solution] #linebreak() #body] #let figph(msg) = block(width: 100%, height: 60pt, fill: rgb("#f6f7f9"), stroke: (paint: rgb("#c7ccd3"), dash: "dashed"), radius: 4pt, inset: 10pt)[ #align(center + horizon, text(fill: rgb("#889"), style: "italic", size: 9pt, msg))] // Standardize inlined figure sizes: measure the natural CeTZ canvas, then scale to a // consistent envelope (aspect-aware; see build_typst.py FIG_* constants). Unlike the // print preamble, dimensions are FLOORED: in an editor a user can trim a figure to a // degenerate 1-D shape (a bare line), and w/h or tw/w would then divide by zero. #let _STD_W = 3.5 #let _WIDE_W = 5.6 #let _MAX_H = 3.4 #let _ASPECT_WIDE = 2.2 #let _UPSCALE_MAX = 1.15 #let stdfig(body) = context { let m = measure(body) let w = calc.max(m.width / 1in, 0.01) let h = calc.max(m.height / 1in, 0.01) let tw = if w / h > _ASPECT_WIDE { _WIDE_W } else { _STD_W } let s = calc.min(tw / w, _MAX_H / h, _UPSCALE_MAX) align(center, box(scale(x: s * 100%, y: s * 100%, reflow: true, body))) } #show figure: set block(breakable: false) #set figure(gap: 8pt) #show figure.caption: set text(size: 8.5pt, fill: rgb("#555")) == 8.3#h(0.6em)One-Sample Interval for the Mean Suppose you want to estimate the mean height of Americans, or you want to estimate the mean salary of college graduates. A confidence interval for the mean would be the way to estimate these means. === Confidence Interval for One Population Mean (t-Interval) + State the random variable and the parameter in words. #linebreak() #emph[x] = random variable #linebreak() #math.equation(block: false, alt: "μ")[$μ$] = mean of random variable + State and check the assumptions for a hypothesis test + A random sample of size #emph[n] is taken. + The population of the random variable is normally distributed, though the t-test is fairly robust to the assumption if the sample size is large. This means that if this assumption isn’t met, but your sample size is quite large (over 30), then the results of the t-test are valid. + Find the sample statistic and confidence interval #linebreak() #math.equation(block: false, alt: "x ― minus E less than μ less than x ― plus E")[$limits(x)^(―) − E < μ < limits(x)^(―) + E$] #linebreak() where #linebreak() #math.equation(block: false, alt: "E equals t sub c the fraction s over the square root of n")[$E = t_(c) frac(s, sqrt(n))$] #linebreak() #math.equation(block: false, alt: "x ―")[$limits(x)^(―)$] is the point estimator for #math.equation(block: false, alt: "μ")[$μ$] #linebreak() #math.equation(block: false, alt: "t sub c")[$t_(c)$] is the critical value where degrees of freedom: #emph[df] = #emph[n] - 1 #linebreak() #emph[s]is the sample standard deviation #linebreak() #emph[n] is the sample size + Statistical Interpretation: In general this looks like, “there is a C% chance that the statement #math.equation(block: false, alt: "x ― minus E less than μ less than x ― plus E")[$limits(x)^(―) − E < μ < limits(x)^(―) + E$] contains the true mean.” + Real World Interpretation: This is where you state what interval contains the true mean. The critical value is a value from the Student’s t-distribution. Since a confidence interval is found by adding and subtracting a margin of error amount from the sample mean, and the interval has a probability of containing the true mean, then you can think of this as the statement #math.equation(block: false, alt: "P open parenthesis x ― minus E less than μ less than x ― plus E close parenthesis equals C")[$P ( limits(x)^(―) − E < μ < limits(x)^(―) + E ) = C$]. The critical values are found in table A.2 in the appendix. ==== How to check the assumptions of confidence interval: In order for the confidence interval to be valid, the assumptions of the test must be true. Whenever you run a confidence interval, you must make sure the assumptions are true. You need to check them. Here is how you do this: + For the assumption that the sample is a random sample, describe how you took the sample. Make sure your sampling technique is random. + For the assumption that population is normal, remember the process of assessing normality from chapter 6. #examplebox("Example 1")[confidence interval for the population mean using the formula][ A random sample of 20 IQ scores of famous people was taken information from the website of IQ of Famous People ("IQ of famous," 2013) and then using a random number generator to pick 20 of them. The data are in Example #math.equation(block: false, alt: "1")[$1$] (this is the same data set that was used in Example #math.equation(block: false, alt: "2")[$2$]). Find a 98% confidence interval for the IQ of a famous person. #figure(table( columns: 5, align: left, inset: 6pt, table.header([158], [180], [150], [137], [109]), [225], [122], [138], [145], [180], [118], [118], [126], [140], [165], [150], [170], [105], [154], [118], )) + State the random variable and the parameter in words. + State and check the assumptions for a confidence interval. + Find the sample statistic and confidence interval. + Statistical Interpretation + Real World Interpretation #solutionbox[ 1. #emph[x] = IQ score of a famous person #math.equation(block: false, alt: "μ")[$μ$] = mean IQ score of a famous person 2. + A random sample of 20 IQ scores was taken. This was stated in the problem. + The population of IQ score is normally distributed. This was shown in Example #math.equation(block: false, alt: "2")[$2$]. 3. Sample Statistic: #math.equation(block: true, alt: "x ― equals 145.4")[$limits(x)^(―) = 145.4$] #math.equation(block: true, alt: "s approximately equals 29.27")[$s ≈ 29.27$] Now you need the degrees of freedom, #emph[df] = #emph[n] - 1 = 20 - 1 = 19 and the #emph[C], which is 98%. Now go to table A.2, go down the first column to 19 degrees of freedom. Then go over to the column headed with 98%. Thus #math.equation(block: false, alt: "t sub c equals 2.539")[$t_(c) = 2.539$]. (See Example #math.equation(block: false, alt: "2")[$2$].) #figure(figph[A t-distribution critical-values table shows confidence levels from 80% to 99%, with the 98% column and the row for 19 degrees of freedom highlighted, giving t\_c = 2.539.], alt: "A t-distribution critical-values table shows confidence levels from 80% to 99%, with the 98% column and the row for 19 degrees of freedom highlighted, giving t_c = 2.539.", caption: none) Table #math.equation(block: false, alt: "2")[$2$]#emph[: Excerpt From Table A.2] #math.equation(block: true, alt: "E equals t sub c the fraction s over the square root of n equals 2.539 the fraction 29.27 over the square root of 20 approximately equals 16.6")[$E = t_(c) frac(s, sqrt(n)) = 2.539 frac(29.27, sqrt(20)) ≈ 16.6$] #math.equation(block: true, alt: "x ― minus E less than μ less than x ― plus E")[$limits(x)^(―) − E < μ < limits(x)^(―) + E$] #math.equation(block: true, alt: "145.4 minus 16.6 less than μ less than 145.4 plus 16.6")[$145.4 − 16.6 < μ < 145.4 + 16.6$] #math.equation(block: true, alt: "128.8 less than μ less than 162")[$128.8 < μ < 162$] 4. There is a 98% chance that #math.equation(block: false, alt: "128.8 less than μ less than 162")[$128.8 < μ < 162$] contains the mean IQ score of a famous person. 5. The mean IQ score of a famous person is between 128.8 and 162. ] ] #examplebox("Example 2")[confidence interval for the population mean using technology][ The data in Example #math.equation(block: false, alt: "3")[$3$] are the life expectancies for men in European countries in 2011 ("WHO life expectancy," 2013). Find the 99% confident interval for the mean life expectancy of men in Europe. #notebox("Note", rgb("#8a94a6"), rgb("#556666"), rgb("#f7f8fa"))[ #emph[The TInterval on the life-expectancy data] The 53 life expectancies are pre-loaded; the interval panel opens at the 99% level. Get x̄, Sx, and n from 1-Var Stats first, exactly as the calculator's Data mode does. - 1-Var Stats: x̄ = 73.74, Sx = 5.73, n = 53 - TInterval at 99%: (71.63, 75.84) ] #figure(table( columns: 8, align: left, inset: 6pt, table.header([73], [79], [67], [78], [69], [66], [78], [74]), [71], [74], [79], [75], [77], [71], [78], [78], [68], [78], [78], [71], [81], [79], [80], [80], [62], [65], [69], [68], [79], [79], [79], [73], [79], [79], [72], [77], [67], [70], [63], [82], [72], [72], [77], [79], [80], [80], [67], [73], [73], [60], [65], [79], [66], [], [], [], )) + State the random variable and the parameter in words. + State and check the assumptions for a confidence interval. + Find the sample statistic and confidence interval. + Statistical Interpretation + Real World Interpretation #solutionbox[ 1. #emph[x] = life expectancy for a European man in 2011 #math.equation(block: false, alt: "μ")[$μ$] = mean life expectancy for European men in 2011 2. + A random sample of 53 life expectancies of European men in 2011 was taken. The data is actually all of the life expectancies for every country that is considered part of Europe by the World Health Organization. However, the information is still sample information since it is only for one year that the data was collected. It may not be a random sample, but that is probably not an issue in this case. + The distribution of life expectancies of European men in 2011 is normally distributed. To see if this assumption has been met, look at the histogram, number of outliers, and the normal probability plot. (If you wish, you can look at the normal probability plot first. If it doesn’t look linear, then you may want to look at the histogram and number of outliers at this point.) #figure(figph[Histogram of expectancy values using bins from 60 to 85, with most observations between 75 and 80.], alt: "Histogram of expectancy values using bins from 60 to 85, with most observations between 75 and 80.", caption: [Figure #math.equation(block: false, alt: "1")[$1$]: Histogram for Life Expectancies of European Men in 2011]) Not normally distributed #strong[Number of outliers]: #figure(figph[A horizontal boxplot of European men's 2011 life expectancies, ranging from 60 to 82 years with a median of 74 years.], alt: "A horizontal boxplot of European men's 2011 life expectancies, ranging from 60 to 82 years with a median of 74 years.", caption: [Figure #math.equation(block: false, alt: "2")[$2$]: Modified Box Plot for Life Expectancies of European Men in 2011]) #emph[IQR] = 79 - 69 = 10 1.5 \* #emph[IQR] = 15 #emph[Q]1 - 1.5 \* #emph[IQR] = 69 - 15 = 54 #emph[Q]3 + 1.5 \* #emph[IQR] = 79 + 15 = 94 Outliers are numbers below 54 and above 94. There are no outliers for this data set. #figure(figph[A normal Q-Q plot of 53 sample values from 60 to 82, with points roughly following an increasing linear pattern.], alt: "A normal Q-Q plot of 53 sample values from 60 to 82, with points roughly following an increasing linear pattern.", caption: [Figure #math.equation(block: false, alt: "3")[$3$]: Normal Quantile Plot for Life Expectancies of European Men in 2011]) Not linear This population does not appear to be normally distributed. The t-test is robust for sample sizes larger than 30 so you can go ahead and calculate the interval. 3. Find the sample statistic and confidence interval On the TI-83/84: Go into the STAT menu, and type the data into L1. Then go into STAT and over to TESTS. Choose TInterval. #figure(figph[TI-83/84 TInterval setup screen showing Data input, list L1, frequency 1, confidence level 0.99, and Calculate.], alt: "TI-83/84 TInterval setup screen showing Data input, list L1, frequency 1, confidence level 0.99, and Calculate.", caption: [Figure #math.equation(block: false, alt: "4")[$4$]: Setup for TInterval]) #figure(figph[TI-83/84 calculator screen showing a one-sample t-interval of (71.63, 75.84), sample mean 73.73584906, sample standard deviation 5.728306715, and sample size 53.], alt: "TI-83/84 calculator screen showing a one-sample t-interval of (71.63, 75.84), sample mean 73.73584906, sample standard deviation 5.728306715, and sample size 53.", caption: [Figure #math.equation(block: false, alt: "5")[$5$]: Results for TInterval]) On R: t.test(variable, conf.level = C), where C is given in decimal form. So for this example it would be t.test(expectancy, conf.level = 0.99) One Sample t-test data: expectancy t = 93.711, df = 52, p-value \< 2.2e-16 alternative hypothesis: true mean is not equal to 0 99 percent confidence interval: 71.63204 75.83966 sample estimates: mean of x 73.73585 71.6 years \< #math.equation(block: false, alt: "μ")[$μ$] 75.8 years 4. There is a 99% chance that 71.6 years \< #math.equation(block: false, alt: "μ")[$μ$] 75.8 years contains the mean life expectancy of European men. 5. The mean life expectancy of European men is between 71.6 and 75.8 years. ] ] === Homework #notebox("Your Turn", rgb("#8a94a6"), rgb("#556666"), rgb("#f7f8fa"))[ In each problem show all steps of the confidence interval. If some of the assumptions are not met, note that the results of the interval may not be correct and then continue the process of the confidence interval. + The Kyoto Protocol was signed in 1997, and required countries to start reducing their carbon emissions. The protocol became enforceable in February 2005. Example #math.equation(block: false, alt: "4")[$4$] contains a random sample of CO2 emissions in 2010 ("CO2 emissions," 2013). Compute a 99% confidence interval to estimate the mean CO2 emission in 2010. #figure(table( columns: 7, align: left, inset: 6pt, table.header([1.36], [1.42], [5.93], [5.36], [0.06], [9.11], [7.32]), [7.93], [6.72], [0.78], [1.80], [0.20], [2.27], [0.28], [5.86], [3.46], [1.46], [0.14], [2.62], [0.79], [7.48], [0.86], [7.84], [2.87], [2.45], [], [], [], )) + Many people feel that cereal is healthier alternative for children over glazed donuts. Example #math.equation(block: false, alt: "5")[$5$] contains the amount of sugar in a sample of cereal that is geared towards children ("Healthy breakfast story," 2013). Estimate the mean amount of sugar in children cereal using a 95% confidence level. #figure(table( columns: 7, align: left, inset: 6pt, table.header([10], [14], [12], [9], [13], [13], [13]), [11], [12], [15], [9], [10], [11], [3], [6], [12], [15], [12], [12], [], [], )) + In Florida, bass fish were collected in 53 different lakes to measure the amount of mercury in the fish. The data for the average amount of mercury in each lake is in Table 6 ("Multi-disciplinary niser activity," 2013). Compute a 90% confidence interval for the mean amount of mercury in fish in Florida lakes. #figure(table( columns: 6, align: left, inset: 6pt, table.header([1.23], [1.33], [0.04], [0.44], [1.20], [0.27]), [0.48], [0.19], [0.83], [0.81], [0.81], [0.5], [0.49], [1.16], [0.05], [0.15], [0.19], [0.77], [1.08], [0.98], [0.63], [0.56], [0.41], [0.73], [0.34], [0.59], [0.34], [0.84], [0.50], [0.34], [0.28], [0.34], [0.87], [0.56], [0.17], [0.18], [0.19], [0.04], [0.49], [1.10], [0.16], [0.10], [0.48], [0.21], [0.86], [0.52], [0.65], [0.27], [0.94], [0.40], [0.43], [0.25], [0.27], [], )) + In 1882, Albert Michelson collected measurements on the speed of light ("Student t-distribution," 2013). His measurements are given in Table 7. Find the speed of light value that Michelson estimated from his data using a 95% confidence interval. #figure(table( columns: 5, align: left, inset: 6pt, table.header([299883], [299816], [299778], [299796], [299682]), [299711], [299611], [299599], [300051], [299781], [299578], [299796], [299774], [299820], [299772], [299696], [299573], [299748], [299748], [299797], [299851], [299809], [299723], [], [], )) + Table 8 contains pulse rates after running for 1 minute, collected from females who drink alcohol ("Pulse rates before," 2013). The mean pulse rate after running for 1 minute of females who do not drink is 97 beats per minute. Do the data show that the mean pulse rate of females who do drink alcohol is higher than the mean pulse rate of females who do not drink? Test at the 5% level. #figure(table( columns: 6, align: left, inset: 6pt, table.header([176], [150], [150], [115], [129], [160]), [120], [125], [89], [132], [120], [120], [68], [87], [88], [72], [77], [84], [92], [80], [60], [67], [59], [64], [88], [74], [68], [], [], [], )) + The economic dynamism, which is the index of productive growth in dollars for countries that are designated by the World Bank as middle-income are in Table 9 ("SOCR data 2008," 2013). Countries that are considered high-income have a mean economic dynamism of 60.29. Do the data show that the mean economic dynamism of middle-income countries is less than the mean for high-income countries? Test at the 5% level. #figure(table( columns: 7, align: left, inset: 6pt, table.header([25.8057], [37.4511], [51.915], [43.6952], [47.8506], [43.7178], [58.0767]), [41.1648], [38.0793], [37.7251], [39.6553], [42.0265], [48.6159], [43.8555], [49.1361], [61.9281], [41.9543], [44.9346], [46.0521], [48.3652], [43.6252], [50.9866], [59.1724], [39.6282], [33.6074], [21.6643], [], [], )) + In 1999, the average percentage of women who received prenatal care per country is 80.1%. Table 10 contains the percentage of woman receiving prenatal care in 2009 for a sample of countries ("Pregnant woman receiving," 2013). Do the data show that the average percentage of women receiving prenatal care in 2009 is higher than in 1999? Test at the 5% level. #figure(table( columns: 6, align: left, inset: 6pt, table.header([70.08], [72.73], [74.52], [75.79], [76.28], [76.28]), [76.65], [80.34], [80.60], [81.90], [86.30], [87.70], [87.76], [88.40], [90.70], [91.50], [91.80], [92.10], [92.20], [92.41], [92.47], [93.00], [93.20], [93.40], [93.63], [93.69], [93.80], [94.30], [94.51], [95.00], [95.80], [95.80], [96.23], [96.24], [97.30], [97.90], [97.95], [98.20], [99.00], [99.00], [99.10], [99.10], [100.00], [100.00], [100.00], [100.00], [100.00], [], )) + Maintaining your balance may get harder as you grow older. A study was conducted to see how steady the elderly is on their feet. They had the subjects stand on a force platform and have them react to a noise. The force platform then measured how much they swayed forward and backward, and the data is in Table 11 ("Maintaining balance while," 2013). Do the data show that the elderly sway more than the mean forward sway of younger people, which is 18.125 mm? Test at the 5% level. #figure(table( columns: 9, align: left, inset: 6pt, [19], [30], [20], [19], [29], [25], [21], [24], [50], )) Answer For all confidence intervals, just the interval using technology is given. See solution for the entire answer. 1. 1.7944 \< #math.equation(block: false, alt: "μ")[$μ$] \< 5.1152 metric tons per capita 3. 0.44872 \< #math.equation(block: false, alt: "μ")[$μ$] \< 0.60562 mg/kg 5. 87.2423 \< #math.equation(block: false, alt: "μ")[$μ$] \< 113.795 beats/min 7. 88.8747% \< #math.equation(block: false, alt: "μ")[$μ$] \< 93.0253% ] === Data Sources: Australian Human Rights Commission, (1996). #emph[Indigenous deaths in custody 1989 - 1996.]Retrieved from website: www.humanrights.gov.au/public...deaths-custody #emph[CDC features - new data on autism spectrum disorders.] (2013, November 26). Retrieved from www.cdc.gov/features/countingautism/ Center for Disease Control and Prevention, Prevalence of Autism Spectrum Disorders - Autism and Developmental Disabilities Monitoring Network. (2008). #emph[Autism and developmental disabilities monitoring network-2012.]Retrieved from website: www.cdc.gov/ncbddd/autism/doc...nityReport.pdf #emph[CO2 emissions.] (2013, November 19). Retrieved from #link("http://data.worldbank.org/indicator/EN.ATM.CO2E.PC")[http://data.worldbank.org/indicator/EN.ATM.CO2E.PC] Federal Trade Commission, (2008). #emph[Consumer fraud and identity theft complaint data: January-december 2007.] Retrieved from website: www.ftc.gov/opa/2008/02/fraud.pdf #emph[Gallup news service.] (2013, November 7-10). Retrieved from www.gallup.com/file/poll/1658...acy\_131115.pdf #emph[Healthy breakfast story.] (2013, November 16). Retrieved from lib.stat.cmu.edu/DASL/Stories...Breakfast.html #emph[Maintaining balance while concentrating.] (2013, September 25). Retrieved from #link("http://www.statsci.org/data/general/balaconc.html")[http://www.statsci.org/data/general/balaconc.html] #emph[Morgan Gallup poll on unemployment.] (2013, September 26). Retrieved from #link("http://www.statsci.org/data/oz/gallup.html")[http://www.statsci.org/data/oz/gallup.html] #emph[Multi-disciplinary niser activity - mercury in bass.] (2013, November 16). Retrieved from #link("http://gozips.uakron.edu/~nmimoto/pages/datasets/MercuryInBass")[http://gozips.uakron.edu/~nmimoto/pa.../MercuryInBass] - description.txt #emph[Pregnant woman receiving prenatal care.] (2013, October 14). Retrieved from #link("http://data.worldbank.org/indicator/SH.STA.ANVC.ZS")[http://data.worldbank.org/indicator/SH.STA.ANVC.ZS] #emph[Pulse rates before and after exercise.] (2013, September 25). Retrieved from #link("http://www.statsci.org/data/oz/ms212.html")[http://www.statsci.org/data/oz/ms212.html] #emph[SOCR data 2008 world countries rankings.] (2013, November 16). Retrieved from wiki.stat.ucla.edu/socr/index...ountriesRankin gs #emph[Student t-distribution.] (2013, November 25). Retrieved from lib.stat.cmu.edu/DASL/Stories/student.html #emph[WHO life expectancy.] (2013, September 19). Retrieved from www.who.int/gho/mortality\_bur...n\_trends/en/in dex.html