Expected value of a function of X Let

  • Slides: 82
Download presentation

Expected value of a function of X 複 習 • Let X be a

Expected value of a function of X 複 習 • Let X be a discrete random variable, and let Y be any function of X such that Y = g(X). Then the expected value of Y, or the expected value of g(X), is ©蘇國賢 2001 2

Properties of Expectations 複 習 • Theorem 1: if Y=a.X+b, where a and b

Properties of Expectations 複 習 • Theorem 1: if Y=a.X+b, where a and b are constant, then E(Y) = a.E(X) + b =1 E(X) ©蘇國賢 2001 3

Properties of Expectations 複 習 • Theorem 2: if X 1, X 2, X

Properties of Expectations 複 習 • Theorem 2: if X 1, X 2, X 3…Xn are n random variable such that each expectation E(Xi) exists (i = 1, 2, …n), then E(X 1+X 2…+Xn) = E(X 1) +E(X 2) +… E(Xn) ©蘇國賢 2001 4

Properties of Expectations 複 習 • It follows from theorem 1 and theorem 2

Properties of Expectations 複 習 • It follows from theorem 1 and theorem 2 that for any constant a 1, a 2, …an and b, E(a 1 X 1+a 2 X 2…+an. Xn) = a 1 E(X 1) +a 2 E(X 2) +… +an. E(Xn) • 同理: • E(a 1 X 1 -a 2 X 2…-an. Xn) = a 1 E(X 1) -a 2 E(X 2) -… -an. E(Xn) ©蘇國賢 2001 5

Properties of Expectations 複 習 • Theorem 3: • If X 1, …Xn are

Properties of Expectations 複 習 • Theorem 3: • If X 1, …Xn are n independent variables such that each expectation E(Xi) exists, then • E(X 1.X 2.X 3…Xn)=E(X 1)E(X 2)…E(Xn) ©蘇國賢 2001 8

Properties of Expectations 複 習 • Proof • X 1, …Xn are n independent

Properties of Expectations 複 習 • Proof • X 1, …Xn are n independent variables, P(X 1.X 2 .X 3…Xn)= P(X 1)P(X 2)…P(Xn) ©蘇國賢 2001 9

Variance of Discrete Random Variable 複 習 • 非連續隨機變數的變異數 ©蘇國賢 2001 10

Variance of Discrete Random Variable 複 習 • 非連續隨機變數的變異數 ©蘇國賢 2001 10

Properties of the variance 複 習 • Var(c)=0, c 為常數項 • 更正式的陳述:Var(X)=0 if and

Properties of the variance 複 習 • Var(c)=0, c 為常數項 • 更正式的陳述:Var(X)=0 if and only if there exists a constant c such that P(X=c)=1. ©蘇國賢 2001 11

Properties of the variance • • 複 習 Theorem 4: Var(a. X+b)=a 2 Var(X)

Properties of the variance • • 複 習 Theorem 4: Var(a. X+b)=a 2 Var(X) Proof. 因為E(a. X+b)=a. E(X)+b=au+b Var(a. X+b)=E[((a. X+b) – E(a. X+b))2] =E[(a. X+b – au –b)2]=E[(a. X-au)2] =a 2 E[(X-u)2] ©蘇國賢 2001 12

Properties of the variance 複 習 • Theorem 5: • If X 1, …Xn

Properties of the variance 複 習 • Theorem 5: • If X 1, …Xn are independent random variables, then Var(X 1+…+Xn) = Var(X 1)+ …+Var(Xn) ©蘇國賢 2001 13

Properties of the variance • • 複 習 Proof. 以n=2為例,If E(X 1) = u

Properties of the variance • • 複 習 Proof. 以n=2為例,If E(X 1) = u 1 and E(X 2) = u 2 E(X 1+X 2)=u 1+u 2 Var(X 1+X 2)=E[(X 1+X 2 -u 1 -u 2)2] =E[(X 1 -u 1)2+(X 2 -u 2)2+2(X 1 -u 1)(X 2 -u 2)] =Var(X 1) + Var(X 2) +2 E[(X 1 -u 1)(X 2 -u 2)] X 1, X 2 are independent, 根據theorem 3 E[(X 1 -u 1)(X 2 -u 2)]=E(X 1 -u 1)E(X 2 -u 2)=0 ©蘇國賢 2001 14

Linear combinations of normally distributed variables • Theorem 6. If the random variables X

Linear combinations of normally distributed variables • Theorem 6. If the random variables X 1, . . Xk are independent and if Xi has a normal distribution with mean ui and variance σ2, then the sum X 1+X 2+…Xk has a normal distribution with mean u 1+…uk and variance σ12 +…+σk 2 • 兩常態獨立樣本相加減所得到新的分 配仍為常態分配。 ©蘇國賢 2001 15

Page 477, Figure 10. 1 ©蘇國賢 2001 16

Page 477, Figure 10. 1 ©蘇國賢 2001 16

Sampling distribution of the difference between two sample mean 定 義 假設有兩獨立母體 1 1

Sampling distribution of the difference between two sample mean 定 義 假設有兩獨立母體 1 1 如果樣本數 夠大,其樣 本平均數的 抽樣分配必 21/n 1 為常態,且 1 ©蘇國賢 2001 2 2 22/n 2 2 17

Sampling distribution of the difference between two sample mean 定 義 • 當樣本n很大時,樣本平均數差之抽樣分配為近 似常態分配(theorem

Sampling distribution of the difference between two sample mean 定 義 • 當樣本n很大時,樣本平均數差之抽樣分配為近 似常態分配(theorem 6) 22/n 2 21/n 1 1 ©蘇國賢 2001 2 1 - 2 18

Sampling distribution of the difference between two sample mean 根據theorem 2 根據theorem 5 為一平均值,

Sampling distribution of the difference between two sample mean 根據theorem 2 根據theorem 5 為一平均值, 變異數已知的 常態分配 ©蘇國賢 2001 1 - 2 19

例題 • A financial loan officer claims that the mean monthly payment for credit

例題 • A financial loan officer claims that the mean monthly payment for credit cards is $80 and the variance is 1, 400 for female. For males, the mean is $80 and the variance is 1, 320. You take a random sample of 100 females and an independent random sample of 120 males. What is the probability that the sample mean for females will be at least $5 higher than the sample mean for males? ©蘇國賢 2001 20

例題 • The television picture tubes of manufacturer A have a mean lifetime of

例題 • The television picture tubes of manufacturer A have a mean lifetime of 6. 5 years and a standard deviation of 0. 9 year, while those of manufacturer B have a mean lifetime of 6 years and a standard deviation of 0. 8 year. What is the probability that a random sample of 36 tubes from manufacturer A will have a mean lifetime that is at least 1 year more than the mean lifetime of a sample of 49 tubes from manufacturer B? ©蘇國賢 2001 25

Sampling distribution of the difference between two sample mean兩樣本平均數差的 抽樣分配 • 假設有兩獨立分配母體 1 1

Sampling distribution of the difference between two sample mean兩樣本平均數差的 抽樣分配 • 假設有兩獨立分配母體 1 1 2 其樣本平均數的 抽樣分配分別為 21/n 1 ©蘇國賢 2001 1 2 22/n 2 2 30

Sampling distribution of the difference between two sample mean ©蘇國賢 2001 1 - 2

Sampling distribution of the difference between two sample mean ©蘇國賢 2001 1 - 2 32

Sampling distribution of the difference between two sample mean 22/n 2 21/n 1 1

Sampling distribution of the difference between two sample mean 22/n 2 21/n 1 1 2 • 當樣本n>30時,兩樣本平均數差之抽樣分配為近似 常態分配 ©蘇國賢 2001 1 - 2 33

Sampling distribution of the difference between two sample mean, When population variances unknown 如果樣本數夠大(n>30),則我們可以用樣本變

Sampling distribution of the difference between two sample mean, When population variances unknown 如果樣本數夠大(n>30),則我們可以用樣本變 異數s 2來取代未知的母體變異數 2。 如果我們假設D 0=0, 則 ©蘇國賢 2001 35

Confidence intervals for the difference of Two means Confidence interval for (u 1 -u

Confidence intervals for the difference of Two means Confidence interval for (u 1 -u 2) when variance are known— independent sample Suppose we have independent random samples of size n 1 and n 2 from two normal populations having unknown means u 1 and u 2 and known variance 12 and 22. If the observed sample means are x 1 and x 2, a 100(1 - )% confidence interval for (u 1 – u 2) is given by ©蘇國賢 2001 36

Confidence intervals for the difference of Two means If sample sizes are large n>30,

Confidence intervals for the difference of Two means If sample sizes are large n>30, and the population variances are unknown, then ©蘇國賢 2001 37

例題 Reject H 0 ©蘇國賢 2001 41

例題 Reject H 0 ©蘇國賢 2001 41

Confidence intervals for the difference of Two means Confidence interval for (u 1 -u

Confidence intervals for the difference of Two means Confidence interval for (u 1 -u 2) when variance are UNKNOWN and sample sizes are small, population variances are assumed equal Suppose we have independent random samples of size n 1 and n 2 from normal populations having unknown means u 1 and u 2 and a common unknown variance 2. If the observed sample means are x 1 and x 2, a 100(1 - )% confidence interval for (u 1 – u 2) is given by ©蘇國賢 2001 48

Confidence intervals for the difference of Two means Pooled estimate of the common variance

Confidence intervals for the difference of Two means Pooled estimate of the common variance ©蘇國賢 2001 Degree of freedom 49

例題 因為 =5%,d. f. =(n 1 -1)+(n 2 -1) =30,查表求雙尾 的critical value,得 t. 025,

例題 因為 =5%,d. f. =(n 1 -1)+(n 2 -1) =30,查表求雙尾 的critical value,得 t. 025, 30= 2. 042 Failed to reject ©蘇國賢 2001 51

Page 484, Procedure 10. 1 A ©蘇國賢 2001 53

Page 484, Procedure 10. 1 A ©蘇國賢 2001 53

Page 484, Procedure 10. 1 A (cont. ) ©蘇國賢 2001 54

Page 484, Procedure 10. 1 A (cont. ) ©蘇國賢 2001 54

Page 485, Procedure 10. 1 B ©蘇國賢 2001 55

Page 485, Procedure 10. 1 B ©蘇國賢 2001 55

Page 485, Procedure 10. 1 B (cont. ) ©蘇國賢 2001 56

Page 485, Procedure 10. 1 B (cont. ) ©蘇國賢 2001 56

Page 488, Procedure 10. 2 ©蘇國賢 2001 57

Page 488, Procedure 10. 2 ©蘇國賢 2001 57

Nonpooled t-Test for Two population means (unequal variances and small samples) 如果兩母體的變異數為未知且不同,且 樣本數很小,則: ©蘇國賢

Nonpooled t-Test for Two population means (unequal variances and small samples) 如果兩母體的變異數為未知且不同,且 樣本數很小,則: ©蘇國賢 2001 59

Page 497, Procedure 10. 3 A ©蘇國賢 2001 60

Page 497, Procedure 10. 3 A ©蘇國賢 2001 60

Page 497, Procedure 10. 3 A (cont. ) ©蘇國賢 2001 61

Page 497, Procedure 10. 3 A (cont. ) ©蘇國賢 2001 61

Page 498, Procedure 10. 3 B ©蘇國賢 2001 62

Page 498, Procedure 10. 3 B ©蘇國賢 2001 62

Page 498, Procedure 10. 3 B (cont. ) ©蘇國賢 2001 63

Page 498, Procedure 10. 3 B (cont. ) ©蘇國賢 2001 63

Page 501, Procedure 10. 4 ©蘇國賢 2001 64

Page 501, Procedure 10. 4 ©蘇國賢 2001 64

例題10. 6 499頁 • Step 1: state the null and alternative hypotheses • Step

例題10. 6 499頁 • Step 1: state the null and alternative hypotheses • Step 2: Decide on the significant level α • α=. 01 • Step 3: compute the value of test statistic ©蘇國賢 2001 66

例題10. 6 499頁 ©蘇國賢 2001 Reject null hypothesis 67

例題10. 6 499頁 ©蘇國賢 2001 Reject null hypothesis 67