Download Elements of Statistics: Sample Distributions, Confidence Intervals, and Hypothesis Testing and more Study notes Statistics in PDF only on Docsity! ELEMENTS OF STATISTICS OUTLINE • Sample Distributions • Confidence Intervals • Hypothesis Testing Reading: G. R. Cooper & C. D. McGillem 4.4 - 4.5 EE/STAT 322, #14 1 SAMPLE DISTRIBUTIONS • A sample mean X̂ = 1n ∑n i=1 Xi is unbiased and have a variance of σ 2 x/n. • We still want to know the distribution of X̂, and how good it is. • Define a new RV Z = X̂−X σ/ √ n . We can verify that Z has zero mean and unit variance ( σ2z = 1). • If n is large ( n > 30), we can approximate X̂ and Z as Gaussian RVs. FZ(z) = Φ(z) = 1 − Q(z) is a Gaussian distribution function. EE/STAT 322, #14 2 SAMPLE DISTRIBUTIONS (CONT.) If n is small ( n < 30): we approximate it with sample variance σ S̃/ √ n = S/ √ n − 1. Define T = X̂−X S̃/ √ n = X̂−X S/ √ n−1. T has a Student’s distribution with v = n − 1 degrees of freedom, its PDF is given by fT (t) = Γ(v+12 )√ πvΓ(v/2) (1 + t2/v)− v+1 2 . Γ(k + 1) = kΓ(k), any k; Γ(k + 1) = k!, integer k. )(zfZ X )(tfT tor0 1 2 33− 2− 1− Gaussian student's2.0 4.0 PDF of Normalized RV EE/STAT 322, #14 3 CONFIDENCE INTERVAL • Sample mean gives a point estimation; Confidence interval studies the chance that an estimate falls within a certain interval of the true mean X. • q-percent confidence interval is the interval within which the estimate lies in with a probability of q/100. The limits are called confidence limits and q is the confidence level. EE/STAT 322, #14 4 CONFIDENCE INTERVAL (CONT.) Example: (Ex 4-4.2) A large population of resistors whose values have a true mean of 100 Ω and sample STD of 4. Find the confidence limits of the sample mean for a confidence interval of 95 %. for (a) sample size n = 100; (b) n = 9. Solution: (a). Let the resistance value be denoted as X. X = 100, S̃ = 4. Define Z = X̂−X S̃/ √ n . Since n = 100 is large, we know Z ∼ N(0, 1). We get 2Φ(k) − 1 = 1 − 2Q(k) = 0.95, Q(k) = 0.025, ⇒k = 1.96. Thus, the limits are [X − kS̃/√n, X + kS̃/√n] = [100− 1.96 · 4/10, 100 + 1.96 · 4/10] = [99.22, 100.78]. EE/STAT 322, #14 9 CONFIDENCE INTERVAL (CONT.) (b). n = 9 is small, we use Student’s t PDF for Z. 2FT (k) − 1 = 0.95 ⇒FT (k) = 0.975 ⇒k = 2.306. In Table 4-2 of textbook, for v = n−1 = 8, it shows that for FT (t) = 0.975, t = 2.306. Thus, the limits are [X − kS̃/√n,X + kS̃/√n] = [100 − 2.306 · 4/3, 100 + 2.306 · 4/3] = [96.93, 103.07]. If we use Gaussian assumption on Z, we get 2Φ(k)− 1 = 0.95 ⇒k = 1.96. So [X − kS̃/√n,X + kS̃/√n] = [100 − 1.96 · 4/3, 100 + 1.96 · 4/3] = [97.39, 102.61]. EE/STAT 322, #14 10 HYPOTHESIS TESTING • Problem Statement: Given an estimate (e.g., sample mean), we want to know whether or not this estimate is within the given confidence interval. If true, the hypothesis is accepted; otherwise, the hypothesis is rejected. • One-sided and two-sided tests. • Example: A provider claims the bulbs he produced have a mean life of 1000 hours. If we test two bulbs, with a sample mean of 900 hours, can we say the provider’s claim is false? If the sample mean is 1000 hours, can we say the provider’s claim is true? EE/STAT 322, #14 11 HYPOTHESIS TESTING (CONT.) • Approach of hypothesis testing: 1. Find the confidence limits (or interval) given q-percent and other parameters; 2. Compare the sample mean with the interval: if it falls outside, the hypothesis is rejected; otherwise, it is accepted. EE/STAT 322, #14 12 HYPOTHESIS TESTING (CONT.) Example: A provider claims that his capacitors have mean values of 300 V or greater. We test 100 samples and find the sample mean X̂ = 290, and unbiased sample STD is 40. Use a 99% confidence interval, check whether the claim is true. Solution: This is one-sided test. We know that S̃ = 40, n = 100, X ≥ 300. Let us find the confidence lower-limit Xc, then compare X̂ with Xc. Define Z = X̂−X S̃/ √ n . Since n = 100 is large, we know Z ∼ N(0, 1). Equivalently, we compare Z with Zc = Xc−XS̃/√n . z = 290−30040/10 = −2.5, and ∫ ∞ zc fZ(z)dz = 1 − Φ(zc) = 0.99, ⇒zc = −2.33. z ∈ [zc,∞), so the claim is false. EE/STAT 322, #14 13 HYPOTHESIS TESTING (CONT.) Example: Given the same setting as the previous, if we change q to 99.5%, how would the result change? Solution: ∫ ∞ zc fZ(z)dz = 1 − Φ(zc) = 0.995, ⇒zc = −2.575. Now z ∈ [zc,∞), so the claim is true. Large confidence interval leads to less-strict tests. Define: level of significance + level of confidence = 100% EE/STAT 322, #14 14