113 年 國立臺北大學金融與合作經營學系碩士班《統計學》
第 1 題
Each bag in a large box contain 25 tulip bulbs. Three-fourths of the bags contain bulbs for 5 red and 20 yellow tulips; one-fourths of the bags contain bulbs for 15 red and 10 yellow tulips. A bag is selected at random and one bulb is planted. Give the probability that it will produce a
(a) (5%) Red tulip, say .
(b) (5%) If the tulip is red, find the conditional probability that a bag having 15 red and 10 yellow tulips was selected.
登入後即可作答並保存紀錄。
本題考驗機率的基本概念,包含聯合機率、條件機率以及全機率公式的應用。
首先,我們定義事件:
令 為選到含有 5 顆紅球和 20 顆黃球的袋子。
令 為選到含有 15 顆紅球和 10 顆黃球的袋子。
令 為選到紅球的事件。
根據題目敘述,袋子的比例為:
(a) 求選到紅球的機率 。
我們可以使用全機率公式來計算 :
首先計算條件機率 和 :
在袋子 中,有 5 顆紅球和 20 顆黃球,總共 25 顆。
在袋子 中,有 15 顆紅球和 10 顆黃球,總共 25 顆。
第 2 題
Let X and Y denote the tarsus lengths of male and female grackles, respectively. Assume that X is and Y is . A sample of size n=25 yielded , , and a sample of size m=30 yielded , .
Test
(a) (10%) against a two-side alternative with .
(b) (10%) against with .
(Some critical values and , where and , are given as follows :
, , ,
, , ,
, , ,
, , )
登入後即可作答並保存紀錄。
本題主要考驗樣本數據進行變異數檢定 (F-test) 和平均數檢定 (t-test) 的能力。
首先,我們整理樣本數據:
男性樣本 (X): , ,
女性樣本 (Y): , ,
(a) 檢定變異數比例是否為 1: 對 ,顯著水準 。
此檢定使用 F 檢定。檢定統計量為:
自由度為 (分子), (分母)。
計算樣本變異數:
計算檢定統計量:
臨界值:
由於是雙邊檢定,我們需要尋找 的臨界值。
根據題目提供的臨界值,。
拒絕域為 或 。
由於 F 分佈不對稱,我們需要查找 和 。
但題目僅提供右尾臨界值。在實際應用中,若 ,則用 對 檢定;若 ,則用 對 檢定。
在此情況下,,我們應該計算 並與 比較。
臨界值 。
決策:
由於 ,統計量落在接受域。
因此,我們不拒絕虛無假說 。
【答案】不拒絕 。
第 3 題
Let X1, X2, ..., and Xn be a random sample from distributions with the following probability density functions. In each case find the maximum likelihood estimator .
(a) (5%)
(b) (5%)
登入後即可作答並保存紀錄。
本題考驗 Maximum Likelihood Estimator (MLE) 的求法。MLE 的基本步驟是寫出概似函數 (Likelihood Function),然後取對數得到對數概似函數 (Log-Likelihood Function),最後對參數求偏微分並令其為零,解出參數估計值。
(a) 給定機率密度函數 。
設 為來自此分佈的隨機樣本。
概似函數 為:
對數概似函數 為:
對 求偏微分並令其為零:
令 :
此時,我們需要注意定義域 。因此 ,且 。
我們知道樣本平均數 。
這個形式的 MLE 通常與期望值有關。
考慮 :
令 , 。當 ; 當 。
第 4 題
(10%) Assume that a stock is picked from a population of stocks at random. The average return of the population of stocks is 20%, and the standard deviation of the population of stocks is 2%. To calculate the maximum of the probability that a stock picked at random from this population, which has a return less than 16% or greater than 24%.
登入後即可作答並保存紀錄。
本題考驗標準常態分配的應用,特別是計算機率的區間。題目假設股票報酬率服從常態分配。
設股票的報酬率為 。
根據題目,報酬率的母體平均數 ,母體標準差 。
我們假設報酬率 服從常態分配 。
題目要求計算股票報酬率小於 16% 或大於 24% 的機率,即 。
由於事件 和 是互斥的,因此:
我們需要將這些值標準化,轉換為標準常態分配 。
標準化公式為 。
第 5 題
In a presidential election campaign, two potential candidates argue who has higher supporting ratio. They tend to incorporate into a candidate group, however, they have inconsistent ideas on who should be the vice-president candidate. Candidate A suggests if the poll demonstrates the difference of supporting rate between two candidate groups is not significant, he will support B to be the presidential candidate; otherwise, A should be the presidential candidate and B the vice.
(a) (7%) If the poll surveys at 95% confidence level and the sampling error is approximately ±3%, how large of the sample size should be interviewed at least? 【】
(b) (7%) The results of the poll:. Group (A,B) represents A the presidential candidate and B the vice; Group (B,A) vice versa.
| Group (A,B) | Support rate (p) | Sample size (N) |
|---|---|---|
| Group (B,A) | 48.3% | 2,046 |
| 46.1% | 2,046 | |
| How do they make the decision? (at 95% confidence level) |
登入後即可作答並保存紀錄。
本題考驗樣本數的決定以及兩個比例的假設檢定。
(a) 求樣本數的決定。
題目要求在 95% 信賴水準下,抽樣誤差約為 ±3%,求至少需要訪查的樣本數。
我們知道抽樣誤差 (Margin of Error, MOE) 的公式為:
其中 是信賴水準對應的 Z 值, 是樣本比例,n 是樣本數。
在題目中:
信賴水準 = 95%,所以 。
(題目已給定 ,這表示信賴區間的上界,對應的 是 0.025)。
抽樣誤差 (3%)。
為了估計樣本數,我們通常會使用最保守的 ,因為這會使得 最大,從而得到最大的樣本數。
由於樣本數必須是整數,且我們需要至少多少樣本,所以要向上取整。
。
如果題目提供的 是指兩個比例的差異的抽樣誤差,則情況會更複雜。但通常 MOE 指的是單一比例的抽樣誤差。
題目也給了實際的樣本數 2046,這比我們計算出的 1068 大很多。這可能是因為實際調查者預期比例離 0.5 較遠,或者有其他考量。但根據題意,我們直接使用公式求解。
【答案】至少需要訪查 1068 個樣本。
(b) 根據民意調查結果做出決策。
題目給出兩個候選人組合的民意調查結果:
組合 (A,B) (A 為總統候選人, B 為副手): 支持率 , 樣本數 。
組合 (B,A) (B 為總統候選人, A 為副手): 支持率 , 樣本數 。
第 6 題
A bank constructs a computer system for reviewing small-size loans. The following data discloses the cases reviewed by the system:
Total loan cases: 54,231
Passed cases by computer review: 49,082
Non-default cases after computer review: 46,880
Default cases after computer review: 2,202
Cases rejected by computer system: 5,149. Then the cases are sent to be reviewed by manually. Non-default cases after manual review: 4,585; default cases after manual review: 564.
(a) (8%) By the perspective of the computer system, fill up the following confusion matrix with number of cases.
Computer reviewing cases | Non-default | Default
Predicted | |
| Actual | Non-default | Default
(b) (4%) What are the ratios of type I error and type II error ?
(c) (14%) Calculate "Accuracy ratio", "Precision ratio", "Recall ratio", "False positive ratio", "False negative ratio", "F1-score".
登入後即可作答並保存紀錄。
核心觀念
本題屬於二元分類的 混淆矩陣 (confusion matrix) 應用。
- 實際 (Actual):案件真正的還款狀況。
- 預測 (Predicted):電腦系統的審核結論(通過=預測 非違約,拒絕=預測 違約)。
- TP、TN、FP、FN 的定義
| 預測 Non‑default (通過) | 預測 Default (拒絕) | |
|---|---|---|
| Actual Non‑default | TN | FP |
| Actual Default | FN | TP |
- Type I error = FP / (FP + TN)(把真實非違約誤判為違約)
- Type II error = FN / (FN + TP)(把真實違約誤判為非違約)
- 其他指標:Accuracy、Precision、Recall、FPR、FNR、F1‑score,均直接由四格數值衍生。
(a) 混淆矩陣填寫
根據題目敘述:
| 預測 Non‑default (通過) | 預測 Default (拒絕) | |
|---|---|---|
| Actual Non‑default (46,880 件) | TN = 46,880 | FP = 4,585 |
| Actual Default (2,202 + 564 = 2,766) | FN = 2,202 | TP = 564 |
- 電腦系統通過 49,082 件,其中 46,880 為真實非違約,2,202 為真實違約。
- 電腦系統拒絕 5,149 件,經人工審核後得:4,585 為真實非違約,564 為真實違約。
(b) Type I 與 Type II 錯誤率
第 7 題
(10%) Please derive when n→∞ and small p, binomial distribution will approach to Poisson distribution.
登入後即可作答並保存紀錄。
本題考驗二項分佈 (Binomial Distribution) 如何在特定條件下逼近蒲松分佈 (Poisson Distribution)。
二項分佈 的機率質量函數 (PMF) 為:
, 其中 。
蒲松分佈 的機率質量函數 (PMF) 為:
, 其中 。
我們需要證明當 且 時,二項分佈逼近蒲松分佈,且其參數 應為 。
也就是說,我們要證明:
我們逐一分析二項分佈 PMF 的各項在極限下的行為:
-
當 且 是固定的(通常是相對於 較小的值),則:
所以, -
由於 ,所以 。
則 -
當 且 ,我們有 。
所以 。
我們知道一個重要的極限:。
令 :。
因此,。
現在,將這三部分組合起來: