Survey
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
Confidence Intervals with Means What is the purpose of a confidence interval? To estimate an unknown population parameter Formula: Standard deviation of Critical value statistic Confidence Interval : x z * n statistic Margin of error In a randomized comparative experiment on the effects of calcium on blood pressure, researchers divided 54 healthy, white males at random into two groups, taking calcium or placebo. The paper reports a mean seated systolic blood pressure of 114.9 with standard deviation of 9.3 for the placebo group. Assume systolic blood pressure is normally distributed. Can you find a z-interval for this problem? Why or why not? Student’s t- distribution • Continuous distribution • Unimodal, symmetrical, bell-shaped density curve • Above the horizontal axis • Area under the curve equals 1 • Based on degrees of freedom df = n - 1 Formula: Standard deviation of Standard error – Critical value statistic when you substitute s for . Confidence Interval : s x t * n statistic Margin of error How to find t* • Use B for t distributions CanTable also use invT on the calculator! • Look up confidence level at bottom & Need t* value with 5% is above – df onupper the sides • df = n – 1 so 95% is below invT(p,df) Find these t* 90% confidence when n = 5 95% confidence when n = 15 t* = 2.132 t* = 2.145 Steps for doing a confidence interval: 1) Assumptions – 2) Calculate the interval 3) Write a statement about the interval in the context of the problem. Statement: (memorize!!) We are ________% confident that the true mean context is between ______ and ______. Assumptions for t-inference • Have an SRS from population (or randomly assigned treatments) • unknown • Normal (or approx. normal) distribution – Given – Large sample size – Check graph of data Use only one of these methods to check normality Ex. 1) Find a 95% confidence interval for the true mean systolic blood pressure of the placebo group. Assumptions: • Have randomly assigned males to treatment • Systolic blood pressure is normally distributed (given). • is unknown 9.3 114.9 2.056 (111.22, 118.58) 27 We are 95% confident that the true mean systolic blood pressure is between 111.22 and 118.58. Find a sample size: • If a certain margin of error is wanted, then to find the sample size necessary for that margin of error use: m z * n Always round up to the nearest person! Ex 4) The heights of PWSH male students is normally distributed with = 2.5 inches. How large a sample is necessary to be accurate within + .75 inches with a 95% confidence interval? n = 43 Hypothesis Tests One Sample Means How canagency I tell ifhas they really A government are underweight? received numerous complaints A hypothesis test that will a particular restaurant has allow me to been selling underweight decide if the claim is true or not! hamburgers. restaurant Take The a sample & find x. advertises that it’s patties are “a quarter (4if ounces). But howpound” do I know this x is one that I expect to happen or is it one that is unlikely to happen? Steps for doing a hypothesis test “Since the p-value < (>) a, I reject 1) Assumptions (fail to reject) the H0. There is (is not) sufficient evidence to suggest thathypotheses Ha (in context).” 2) Write & define parameter H0: m = 12 vs Ha: m (<, >, or ≠) 12 3) Calculate the test statistic & p-value 4) Write a statement in the context of the problem. Formulas: unknown: statistic - parameter test statistic standard deviation of statistic t= x m s n Calculating p-values • For z-test statistic – – Use normalcdf(lb,rb) – [using standard normal curve] • For t-test statistic – – Use tcdf(lb, rb, df) Draw & shade a curve & calculate the p-value: 1) right-tail test t = 1.6; n = 20 P-value = .0630 2) two-tail test t = 2.3; n = 25 P-value = (.0152)2 = .0304 Example 1: Bottles of a popular cola are supposed to contain 300 mL of cola. There is some variation from bottle to bottle. An inspector, who suspects that the bottler is under-filling, measures the contents of six randomly selected bottles. Is there sufficient evidence that the bottler is under-filling the bottles? Use a = .1 299.4 297.7 298.9 300.2 297 301 • I have an SRS of bottles SRS? Normal? •Since the boxplot is approximately symmetrical with no outliers, the sampling distribution is approximatelyHow do you know? normally distributed Do you know ? What are your H0: m = 300 where m is the true mean amount hypothesis statements? Is Ha: m < 300 of cola in bottles there a key word? 299 .03 300 t 1.576 p-value =.0880 a = .1 1.503 Plug p-value values to Compare your 6 into decision formula. a & make Since p-value < a, I reject the null hypothesis. Write conclusion in There is sufficient evidence to suggest that the true context in terms of Ha. mean cola in the bottles is less than 300 mL. • is unknown Matched Pairs Test A special type of t-inference Matched Pairs – two forms • Pair individuals by certain characteristics • Randomly select treatment for individual A • Individual B is assigned to other treatment • Assignment of B is dependent on assignment of A • Individual persons or items receive both treatments • Order of treatments are randomly assigned before & after measurements are taken • The two measures are dependent on the individual Is this an example of matched pairs? 1)A college wants to see if there’s a difference in time it took last year’s class to find a job after graduation and the time it took the class from five years ago to find work after graduation. Researchers take a random sample from both classes and measure the number of days between graduation and first day of employment No, there is no pairing of individuals, you have two independent samples Is this an example of matched pairs? 2) In a taste test, a researcher asks people in a random sample to taste a certain brand of spring water and rate it. Another random sample of people is asked to taste a different brand of water and rate it. The researcher wants to compare these samples No, there is no pairing of individuals, you have two independent samples – If you would have the same people taste both brands in random order, then it would be an example of matched pairs. Is this an example of matched pairs? 3) A pharmaceutical company wants to test its new weight-loss drug. Before giving the drug to a random sample, company researchers take a weight measurement on each person. After a month of using the drug, each person’s weight is measured again. Yes, you have two measurements that are dependent on each individual. A whale-watching company noticed that many customers wanted to know whether it was better to book an excursion in the morning or the afternoon. To test this question, the You may subtract either company thewhen following data on 15 way – collected just be careful writing Hadays over the past randomly selected month. (Note: days were not consecutive.) Day 1 2 Morning 8 9 3 4 5 6 7 8 9 10 11 12 13 14 15 7 9 10 13 10 8 2 5 7 7 6 8 7 After8 10 9 8 9 11 8 noon Since you have two values for 10 4 7 8 9 6 6 9 First, you must find the differences for each day. each day, they are dependent on the day – making this data matched pairs Day 1 2 3 Morning 8 9 7 9 10 13 10 Afternoon 8 10 4 5 9 8 9 6 7 8 9 10 11 12 13 14 15 8 2 5 7 7 6 8 7 11 8 10 4 7 8 9 6 6 9 I subtracted: Differenc 0 -1 -2 1 1 Morning 2 2 – -2 -2 -2 -1 -2 0 2 -2 afternoon es You could subtract the other way! • Have an SRS of days for whale-watching You need to state assumptions using the • unknown differences! Assumptions: •Since the normal probability plot is approximately linear, the distribution of difference is approximately Notice the granularity in this normal. plot, it is still displays a nice linear relationship! Differences 0 -1 -2 1 1 2 2 -2 -2 -2 -1 -2 0 2 Is there sufficient evidence that more whales are sighted in the afternoon? H0: mD = 0 Ha: mD < 0 Be careful writing your Ha! Think about how you– If you subtract afternoon subtracted: M-A Hdifferences mD>0should Notice morning; we mthen a:more D foris Ifused afternoon & it equals since the nullbeshould the0 differences + or -? be that there NOat difference. Don’t islook numbers!!!! Where mD is the true mean difference in whale sightings from morning minus afternoon -2 Differences 0 -1 -2 1 1 2 2 -2 finishing the hypothesis test: x m .4 0 t .945 s 1.639 n 15 p .1803 df 14 a .05 -2 -2 -1 -2 0 2 In your calculator, perform t-test Notice athat if the youusing subtracted differences (L3) A-M, then your test statistic t = + .945, but pvalue would be the same Since p-value > a, I fail to reject H0. There is How could I insufficient evidence to suggest that more whales increase theare sighted in the afternoon than in the morning. power of this test? -2