Statistics and Quantitative Analysis U 4320 Segment 6

  • Slides: 31
Download presentation
Statistics and Quantitative Analysis U 4320 Segment 6 Prof. Sharyn O’Halloran

Statistics and Quantitative Analysis U 4320 Segment 6 Prof. Sharyn O’Halloran

I. Introduction n A. Review of Population and Sample Estimates n B. Sampling n

I. Introduction n A. Review of Population and Sample Estimates n B. Sampling n 1. Samples n n The sample mean is a random variable with a normal distribution. If you select many samples of a certain size then on average you will probably get close to the true population mean.

I. Introduction (cont. ) n 2. Central Limit Theorem n Definition n If a

I. Introduction (cont. ) n 2. Central Limit Theorem n Definition n If a Random Sample is taken from any population with mean_ and standard deviation_, then the sampling distribution of the sample means will be normally distributed with n n n 1) Sample Mean E() = _, and 2) Standard Error SE() = _/_n As n increases, the sampling distribution of tends toward the true population mean_.

I. Introduction (cont. ) n C. Making Inferences n n To make inferences about

I. Introduction (cont. ) n C. Making Inferences n n To make inferences about the population from a given sample, we have to make one correction, instead of dividing by the standard deviation, we divided by the standard error of the sampling process: Today, we want to develop a tool to determine how confident we are that our estimates lie within a certain range.

II. Confidence Interval n A. Definition of 95% Confidence Interval (_ known) n 1.

II. Confidence Interval n A. Definition of 95% Confidence Interval (_ known) n 1. Motivation n n We know that, on average, is equal to_. We want some way to express how confident we are that a given is near the actual_ of the population. We do this by constructing a confidence interval, which is some range around that most probably contains_. The standard error is a measure of how much error there is in the sampling process. So we can say that is equal to__ the standard error n = X_Standard Error

II. Confidence Interval (cont. ) n 2. Constructing a 95% Confidence Interval n a.

II. Confidence Interval (cont. ) n 2. Constructing a 95% Confidence Interval n a. Graph n First, we know that the sample mean is distributed normally, with mean_ and standard error

II. Confidence Interval (cont. ) n b. Second, we determine how confident we want

II. Confidence Interval (cont. ) n b. Second, we determine how confident we want to be in our estimate of_. n Defining how confident you want to be is called the -level. n So a 95% confidence interval has an associate - level of. 05. n Because we are concerned with both higher and lower values, the relevant range is _/2 probability in each tail.

II. Confidence Interval (cont. ) n C. Define a 95% Confidence Range n n

II. Confidence Interval (cont. ) n C. Define a 95% Confidence Range n n n Now let's take an interval around that contains 95% of the area under the curve. So if we take a random sample of size n from the population, 95% of the time the population mean _ will be within the range: What is a z value associated with a. 025 probability? From the z-table, we find the z-value associated with a . 025 probability is 1. 96. So our range will be bounded by:

II. Confidence Interval (cont. ) n Now, let's take this interval of size [-1.

II. Confidence Interval (cont. ) n Now, let's take this interval of size [-1. 96 * SE , 1. 96 * SE] and use it as a measuring rod. n d. Interpreting Confidence Intervals

II. Confidence Interval (cont. ) n n What's the probability that the population mean

II. Confidence Interval (cont. ) n n What's the probability that the population mean will fall within the interval 1. 96 * SE? e. In General n n We get the actual interval as 1. 96 * SE on either side of the sample mean. We then know that 95% of the time, this interval will contain . This interval is defined by:

II. Confidence Interval (cont. ) n n For a 95% confidence interval: Examples n

II. Confidence Interval (cont. ) n n For a 95% confidence interval: Examples n n 1. Example 1: Calculate a 95% confidence Interval Say we sample n=180 people and see how many times they ate at a fastfood restaurant in a given week. The sample had a mean of 0. 82 and the population standard deviation is 0. 48. Calculate the 95% confidence interval for these data.

II. Confidence Interval (cont. ) n Answer: n Why 95%?

II. Confidence Interval (cont. ) n Answer: n Why 95%?

II. Confidence Interval (cont. ) n 2. Example 2: Calculating a 90% confidence interval

II. Confidence Interval (cont. ) n 2. Example 2: Calculating a 90% confidence interval n A random sample of 16 observations was drawn from a normal population with = 6 and = 25. Find a 90% ( =. 10) confidence interval for the population mean, _. n First, find Z. 10/2 in the standard normal tables

II. Confidence Interval (cont. ) n Second, calculate the 90% confidence interval n 90%

II. Confidence Interval (cont. ) n Second, calculate the 90% confidence interval n 90% of the time, the mean will lie with in this range.

II. Confidence Interval (cont. ) n What if we wanted to be 99% of

II. Confidence Interval (cont. ) n What if we wanted to be 99% of the time sure that the mean falls with in the interval? n What happens when we move from a 90% to a 99% confidence interval?

II. Confidence Interval (cont. ) n C. Confidence Intervals (_ unknown) n 1. Characteristics

II. Confidence Interval (cont. ) n C. Confidence Intervals (_ unknown) n 1. Characteristics of a Student-t distribution n n a. Shape the student t-distribution The t-distribution changes shape as the sample size gets larger, and in the limit it becomes identical to the normal.

II. Confidence Interval (cont. ) n n b. When to use t-distribution n i.

II. Confidence Interval (cont. ) n n b. When to use t-distribution n i. is unknown n ii. Sample size n is small 2. Constructing Confidence Intervals Using t-Distribution n A. Confidence Interval n n 95% confidence interval is: B. Using t-tables n Say our sample size is n and we want to know what's the cutoff value to get 95% of the area under the curve.

II. Confidence Interval (cont. ) n i) Find Degrees of Freedom n n ii)

II. Confidence Interval (cont. ) n i) Find Degrees of Freedom n n ii) Look up in the t-table n n n Degree of freedom is the amount of information used to calculate the standard deviation, s. We denote it as d. f. _ d. f. = n-1 Now we go down the side of the table to the degrees of freedom and across to the appropriate t-value. That's the cutoff value that gives you area of . 025 in each tail, leaving 95% under the middle of the curve. iii) Example: n Suppose we have sample size n=15 and t. 025 What is the critical value? 2. 13

II. Confidence Interval (cont. ) n Answer:

II. Confidence Interval (cont. ) n Answer:

II. Confidence Interval (cont. ) n III. Differences of Means n A. Population Variance

II. Confidence Interval (cont. ) n III. Differences of Means n A. Population Variance Known n Now we are interested in estimating the value ( 1 - 2) by the sample means, using 1 - 2. Say we take samples of the size n 1 and n 2 from the two populations. And we want to estimate the differences in two population means. To tell how accurate these estimates are, we can construct the familiar confidence interval around their difference:

II. Confidence Interval n n This would be the formula if the sample size

II. Confidence Interval n n This would be the formula if the sample size were large and we knew both 1 and 2. B. Population Variance Unknown 1. If, as usual, we do not know 1 and 2, then we use the sample standard deviations instead. When the variances of populations are not equal (s 1 s 2): Example: Test scores of two classes where one is from an inner city school and the other is from an affluent suburb.

II. Confidence Interval (cont. ) n 2. Pooled Sample Variances, s 1 = s

II. Confidence Interval (cont. ) n 2. Pooled Sample Variances, s 1 = s 2 ( 2 is unknown) n If both samples come from the same population (e. g. , test scores for two classes in the same school), we can assume that they have the same population variance. Then the formula becomes: or just n In this case, we say that the sample variances are pooled. The formula for is:

II. Confidence Interval (cont. ) n n The degrees of freedom are (n 1

II. Confidence Interval (cont. ) n n The degrees of freedom are (n 1 -1) + (n 2 -1), or (n 1+n 2 -2). 3. Example: n Two classes from the same school take a test. Calculate the 95% confidence interval for the difference between the two class means.

II. Confidence Interval (cont. ) n Answer:

II. Confidence Interval (cont. ) n Answer:

II. Confidence Interval (cont. )

II. Confidence Interval (cont. )

II. Confidence Interval (cont. ) n C. Matched Samples n 1. Definition n n

II. Confidence Interval (cont. ) n C. Matched Samples n 1. Definition n n Matched samples are ones where you take a single individual and measure him or her at two different points and then calculate the difference. 2. Advantage n One advantage of matched samples is that it reduces the variance because it allows the experimenter to control for many other variables which may influence the outcome.

II. Confidence Interval (cont. ) n 3. Calculating a Confidence Interval n n Now

II. Confidence Interval (cont. ) n 3. Calculating a Confidence Interval n n Now for each individual we can calculate their difference D from one time to the next. We then use these D's as the data set to estimate , the population difference. n The sample mean of the differences will be denoted. n The standard error will just be: n Use the t-distribution to construct 95% confidence interval:

II. Confidence Interval (cont. ) n 4. Example:

II. Confidence Interval (cont. ) n 4. Example:

II. Confidence Interval (cont. ) n Notice that the standard error here is much

II. Confidence Interval (cont. ) n Notice that the standard error here is much smaller than in most of our unmatched pair examples.

IV. Confidence Intervals for Proportions n Just before the 1996 presidential election, a Gallup

IV. Confidence Intervals for Proportions n Just before the 1996 presidential election, a Gallup poll of about 1500 voters showed 840 for Clinton and 660 for Dole. Calculate the 95% confidence interval for the population proportion of Clinton supporters. n Answer: n= 1500 n Sample proportion P:

IV. Confidence Intervals for Proportions (cont. ) n Create a 95% confidence interval: n

IV. Confidence Intervals for Proportions (cont. ) n Create a 95% confidence interval: n where and P are the population and sample proportions, and n is the sample size. n That is, with 95% confidence, the proportion for Clinton in the whole population of voters was between 53% and 59%.