112 年 國立清華大學科技管理研究所甲組《統計學》
第 1 題
Market data indicates that smartphone users are very concerned about the battery
life of their smartphones. An experiment is conducted in which the battery life of
two newly designed smartphone batteries are compared to the battery life of an
existing smartphone battery. The following table summarizes the results of the
experiment.
| Smartphone | Sample size | Mean | Standard deviation |
|---|---|---|---|
| Existing | 30 | 19.57 | 0.24 |
| New1 | 30 | 20.13 | 0.18 |
| New2 | 30 | 21.34 | 0.22 |
a. At the 0.05 level of significance, is there evidence of a difference in the battery
life of the smartphones for the three different products? (15%)
b. Which test procedure can be used to determine whether there is a difference in the
variation in the battery life?(5%)
登入後即可作答並保存紀錄。
本題主要在檢定三個獨立樣本的平均數是否相等,以及變異數是否相等。
核心觀念:
- 變異數分析 (ANOVA):用於檢定三個或三個以上獨立樣本的平均數是否相等。
- F 檢定 (F-test for equality of variances):用於檢定兩個或多個獨立樣本的變異數是否相等。
解題過程:
Part a: 檢定電池平均壽命是否存在差異
由於我們有三個獨立的樣本,且欲檢定它們的平均數是否相等,因此適合使用單因子變異數分析 (One-way ANOVA)。
-
設定虛無假說與對立假說:
- : (所有產品的平均電池壽命相同)
- : 至少有一個產品的平均電池壽命不同於其他產品。
-
計算統計量:
- 樣本數
- 樣本平均數 , ,
- 樣本標準差 , ,
- 樣本變異數 , ,
- 總樣本數
- 組間變異數 (Between-group variance, MSB):
- 總平均數
- SSB =
SSB =
SSB =
SSB = - MSB = (其中 是組數)
- 組內變異數 (Within-group variance, MSW):
- SSW =
SSW =
SSW = - MSW =
- SSW =
- F 統計量 =
-
決定臨界值與做出決策:
- 顯著水準
- 自由度:分子自由度 ;分母自由度
- 查 F 分配表,在 , , 的情況下,臨界值 約為 3.09 (使用 或 的近似值)。
- 由於計算出的 F 統計量 (532.4) 遠大於臨界值 (3.09),我們拒絕虛無假說 。
-
結論:
在 0.05 的顯著水準下,有足夠的證據顯示這三個產品的平均電池壽命存在差異。
Part b: 檢定電池壽命變異是否存在差異
由於我們有三個獨立的樣本,且欲檢定它們的變異數是否相等,可以使用 F 檢定來比較變異數。若要同時比較三個樣本的變異數,最常見的方法是 Bartlett's Test 或 Levene's Test。然而,題目僅要求「能夠用來判斷的測試程序」,且在 Part a 中已計算出樣本變異數,最直接的比較方法是成對的 F 檢定。
測試程序:
-
Bartlett's Test for Homogeneity of Variances:
- 此檢定專門用於檢定多個獨立樣本的變異數是否相等,尤其當樣本服從常態分配時。
- 虛無假說 :
- 對立假說 : 至少有一個樣本的變異數不同。
- 此檢定會計算一個統計量,並與卡方分配的臨界值比較。
-
Levene's Test for Homogeneity of Variances:
- 此檢定對樣本是否服從常態分配的假設較為穩健。
- 其原理是計算每個樣本點到其組內平均數的絕對偏差,然後對這些偏差進行變異數分析。
第 2 題
You are trying to develop a strategy for investing in two different stocks. The
anticipated annual return for a $2,000 investment in each stock under four
different economic conditions has the following probability distribution:
| Probability | Stock X | Stock Y |
|---|---|---|
| 0.4 | -200 | 100 |
| 0.4 | 0 | -20 |
| 0.2 | 400 | -150 |
Compute the correlation coefficient of stock X and stock Y. (20%)
登入後即可作答並保存紀錄。
核心觀念
兩隨機變數 與 的線性相關係數 定義為共變異數除以兩變數標準差的乘積:
解題方法
- 由機率分配表計算期望值、變異數與共變異數,可得:
- ,故
- ,故
- 代入相關係數公式:
第 3 題
Past records indicate that the probability of online retail orders that turn out to be
fraudulent is 0.12. Suppose that, on a given day, 50 online retail orders are placed.
Assume that the number of online retail orders that turn out to be fraudulent is
distributed as a binomial random variable. What is the probability that five or
more online retail orders will turn out to be fraudulent? (20%)
登入後即可作答並保存紀錄。
核心觀念
若隨機變數 服從二項分配 ,則其機率質量函數為:
當計算 的累積機率時,可利用補事件關係 簡化運算。
解題方法
本題中 ,,故 。欲求 ,先計算 :
第 4 題
You plan to conduct a marketing experiment in which students are to taste one of
two different brands of soft drink. Their task is to correctly identify the brand
tasted. You select a random sample of 100 students and assume that the students
have no ability to distinguish between the two brands. (Hint: If an individual has
no ability to distinguish between the two soft drinks, then the two brands are
equally likely to be selected.) Which is more likely to occur-more than 65%
correct identifications in the sample of 100 or more than 55% correct
identifications in a sample of 500? Explain. (20%)
登入後即可作答並保存紀錄。
核心觀念
本題考查二項分配、標準化,以及以常態分配近似二項分配。
由於每位學生無法分辨兩種飲料,猜中品牌的機率為
若共有 位學生,令 表示答對人數,則
其平均數與標準差分別為
題目比較的是:
- 100 位學生中答對超過 65 人;
- 500 位學生中答對超過 55%。
解題方法
一、100 位學生中超過 65 人答對
令
題意為
其平均數與標準差為
使用常態近似並採用連續性修正:
因此
精確二項分配機率為
二、500 位學生中超過 55% 答對
令
超過 表示答對人數超過
所以事件為
其平均數與標準差為
使用常態近似並進行連續性修正:
因此
精確二項分配機率為
兩者比較
而
第 5 題
How common are financial cost or contractual constraints associated with
smartphone ownership? A survey of smartphone owners found that 48% of the
18- to 29-year-olds, 38% of the 30- to 49-year-olds, 25% of the 50- to 64-year-
olds, and 19% of those age 65 or older have reached the maximum amount of data
they are allowed to use as part of their plan, at least on occasion. Suppose the
survey was based on 200 smartphone owners in each of the four age
groups: 18 to 29, 30 to 49, 50 to 64, and 65+.
a. At the 0.05 level of significance, is there evidence of a difference among the
age groups in the proportion of smartphone owners who have reached the
maximum amount of data they are allowed to use as part of their plan, at least on
occasion? (Usinga = 0.05, the x² critical value with 2 degrees of freedom is 5.991.)
(15%)
b. Which test procedure can be used to determine which age groups differ? (5%)
登入後即可作答並保存紀錄。
本題主要在檢定四個不同年齡層群體中,達到數據流量上限的比例是否存在顯著差異,並詢問事後比較的方法。
核心觀念:
- 卡方檢定 (Chi-Squared Test for Independence/Homogeneity):用於檢定兩個類別變數之間是否獨立,或比較不同群體在某類別變數上的比例分佈是否相同。
- 多重比較 (Multiple Comparisons) / 事後檢定 (Post-hoc tests):在整體檢定結果顯著後,用於找出具體是哪些群體之間存在差異。
解題過程:
Part a: 檢定不同年齡層群體比例是否存在差異
這是一個典型的比例檢定問題,我們有四個獨立的群體(年齡層),每個群體都有一個比例(達到數據流量上限的比例)。我們需要檢定這四個比例是否相等。適合使用卡方檢定 (Chi-squared test for homogeneity)。
-
設定虛無假說與對立假說:
- : 四個年齡層群體中,達到數據流量上限的比例均相等。()
- : 至少有一個年齡層群體的比例不同於其他群體。
-
整理數據:
- 樣本大小:每個群體 (i=1: 18-29, i=2: 30-49, i=3: 50-64, i=4: 65+)
- 觀察比例:, , ,
- 計算各組達到上限的人數 (觀察次數 ):
- 18-29歲:
- 30-49歲:
- 50-64歲:
- 65+歲:
- 計算各組未達到上限的人數 (觀察次數 ):
- 18-29歲:
- 30-49歲:
- 50-64歲:
- 65+歲:
-
計算總體比例與預期次數:
- 總樣本數
- 總體達到上限的比例
- 總體未達到上限的比例
- 計算各組的預期次數 (達到上限) 和 (未達到上限):
-
計算卡方統計量 ():
-
決定臨界值與做出決策:
- 顯著水準
- 自由度 。
- 題目提供的卡方臨界值是 5.991,但這適用於 。對於 ,在 下,臨界值 約為 7.815。
第 1a 題
At the 0.05 level of significance, is there evidence of a difference in the battery
life of the smartphones for the three different products? (15%)
登入後即可作答並保存紀錄。
本題要求在 0.05 的顯著水準下,檢定三種不同手機產品的平均電池壽命是否存在差異。這是一個典型的單因子變異數分析 (One-way ANOVA) 問題。
核心觀念:
- 單因子變異數分析 (One-way ANOVA):用於檢定三個或三個以上獨立樣本的平均數是否相等。
解題過程:
-
設定虛無假說與對立假說:
- : (所有產品的平均電池壽命相同)
- : 至少有一個產品的平均電池壽命不同於其他產品。
-
資料整理:
- 樣本數:, ,
- 樣本平均數:, ,
- 樣本標準差:, ,
- 樣本變異數:, ,
- 總樣本數
- 組數
-
計算變異數分析所需統計量:
- 總平均數 :
- 組間平方和 (Sum of Squares Between, SSB):
SSB
SSB
SSB
SSB - 組間均方 (Mean Square Between, MSB):
MSB - 組內平方和 (Sum of Squares Within, SSW):
- 總平均數 :
第 1b 題
Which test procedure can be used to determine whether there is a difference in the
variation in the battery life?(5%)
登入後即可作答並保存紀錄。
本題要求找出可以用來檢定電池壽命變異是否存在差異的統計測試程序。
核心觀念:
- 變異數同質性檢定 (Tests for Homogeneity of Variances):用於檢定兩個或多個樣本的變異數是否相等。
解題過程:
我們有三個獨立的樣本(Existing, New1, New2),每個樣本都有其變異數的估計值()。我們要判斷這三個變異數之間是否存在顯著差異。
以下是幾種常用的統計測試程序:
-
Bartlett's Test for Homogeneity of Variances:
- 這是最常見的用於檢定多個樣本變異數同質性的方法。
- 它假設樣本是從服從常態分配的母體中抽取的。
- 虛無假說 : (所有群體的變異數相等)。
- 對立假說 : 至少有一個群體的變異數不同。
- 此檢定會計算一個 統計量,並與 分配比較。
-
Levene's Test for Homogeneity of Variances:
- Levene's Test 是一種對樣本是否服從常態分配的假設較為穩健的變異數同質性檢定。
- 它透過計算每個樣本點到其組內平均數的絕對偏差,然後對這些偏差進行單因子變異數分析 (ANOVA)。
- 其虛無假說與 Bartlett's Test 相同。
-
F-test for Equality of Two Variances (Pairwise F-tests):
- 如果我們只想比較兩個樣本的變異數,可以使用 F 檢定。
- 虛無假說 。
第 5a 題
At the 0.05 level of significance, is there evidence of a difference among the
age groups in the proportion of smartphone owners who have reached the
maximum amount of data they are allowed to use as part of their plan, at least on
occasion? (Usinga = 0.05, the x² critical value with 2 degrees of freedom is 5.991.)
(15%)
登入後即可作答並保存紀錄。
本題要求在 0.05 的顯著水準下,檢定四個不同年齡層群體中,達到數據流量上限的比例是否存在顯著差異。這是一個用於檢定兩個類別變數之間關係的卡方檢定問題,具體而言是檢定比例的同質性 (homogeneity of proportions)。
核心觀念:
- 卡方檢定 (Chi-Squared Test):用於檢定觀察頻率與期望頻率之間的差異是否顯著。在此處,用於檢定不同群體(年齡層)在某個類別變數(達到數據流量上限)上的比例分佈是否相同。
解題過程:
-
設定虛無假說與對立假說:
- : 四個年齡層群體中,達到數據流量上限的比例均相等。()
- : 至少有一個年齡層群體的比例不同於其他群體。
-
整理數據:
- 樣本大小:每個群體 。
- 觀察到的比例(達到上限):
- 18-29歲:
- 30-49歲:
- 50-64歲:
- 65+歲:
- 計算各組達到上限的人數 (觀察次數 ):
- 計算各組未達到上限的人數 (觀察次數 ):
-
計算總體比例與期望次數:
- 總樣本數
- 總體達到上限的比例
- 總體未達到上限的比例
- 計算各組的期望次數 :
- (18-29歲,達到上限)
- (18-29歲,未達上限)
- (30-49歲,達到上限)
- (30-49歲,未達上限)
- (50-64歲,達到上限)
- (50-64歲,未達上限)
- (65+歲,達到上限)
- (65+歲,未達上限)
-
計算卡方統計量 ():
卡方統計量為觀察值與期望值差異的平方和,除以期望值,並對所有儲存格求和:
第 5b 題
Which test procedure can be used to determine which age groups differ? (5%)
登入後即可作答並保存紀錄。
本題在 Part a 的卡方檢定結果顯著之後,要求找出能夠進一步確定具體是哪些年齡組之間比例存在差異的統計測試程序。這涉及到事後檢定(Post-hoc tests)或多重比較(Multiple Comparisons)。
核心觀念:
- 事後檢定 (Post-hoc Tests):當整體檢定(如卡方檢定或 ANOVA)顯示群體間存在顯著差異時,用於確定哪些具體群體對此差異有貢獻。
- 多重比較校正 (Multiple Comparison Correction):由於進行多次檢定會增加第一類錯誤(誤判為顯著)的機率,需要對顯著水準進行調整。
解題過程:
在 Part a 中,我們使用了卡方檢定來檢定四個年齡組的比例是否相同。檢定結果顯示比例存在顯著差異。現在需要找出是哪些年齡組之間的比例不同。
以下是常用的方法:
-
成對卡方檢定 (Pairwise Chi-Squared Tests) 配合 Bonferroni 校正:
- 方法: 對所有可能的年齡組配對進行獨立的 2x2 卡方檢定。共有 對配對:
- 18-29 vs 30-49
- 18-29 vs 50-64
- 18-29 vs 65+
- 30-49 vs 50-64
- 30-49 vs 65+
- 50-64 vs 65+
- Bonferroni 校正: 由於進行了 6 次檢定,為了控制整體第一類錯誤率(Family-wise error rate, FWER)在 ,我們需要將每次檢定的顯著水準降低。新的顯著水準 為 ,其中 是檢定的次數。
- 。
- 判斷: 對每一對的卡方檢定,如果其 p-value 小於 0.00833,則認為該兩組的比例存在顯著差異。
- 方法: 對所有可能的年齡組配對進行獨立的 2x2 卡方檢定。共有 對配對:
-
標準化殘差分析 (Standardized Residuals Analysis):
- 在進行整體卡方檢定時,我們可以計算每個儲存格的標準化殘差。