开发者:上海品职教育科技有限公司 隐私政策详情

应用版本:4.2.11(IOS)|3.2.5(安卓)APP下载

Ella · 2024年05月05日

为什么P(Type II error)=1 – P(being in the two tails)

NO.PZ2020010304000053

问题如下:

A data management group wants to test the null hypothesis that observed data is N(0,1) distributed by evaluating the mean of a set of random draws. However, the actual underlying data is distributed as N(1, 2.25).

a. If the sample size is 10, what is the probability of a Type II error and the power of the test? Assume a 90% confidence level on a two-sided test.

b. How many samples would need to be taken to reduce the probability of a Type II error to less than 1%?

选项:

解释:

a. When the null hypothesis is false, the probability of a Type II error is equal to the probability that the hypothesis fails to be rejected.

Now, if there are 10 samples taken from an N(0,1) then the standard deviation is reduced

σH0=1/10=0.316\sigma_{H_0}=1/ \sqrt{10}=0.316

Therefore, the cut-off points are ±1.650.316=±0.522\pm1.65 * 0.316 = \pm0.522

In actuality, the true distribution is N(1,2.25), so the σ=22.25=1.5\sigma = \sqrt{22.25} = 1.5. For a sample size of 10, the expected sample standard deviation is

σsample=1.5/10=0.474\sigma_{sample}=1.5/ \sqrt{10} = 0.474

Calculating the equivalent distance of ±1.65\pm1.65 in this distribution compared to a standard N(0,1) yields

left = (-0.522-1)/0.474=-3.21

and right =(+0.522 - 1)/ 0.474 = -1.00

The probability of being on the left-hand side is practically zero. For the right, Pr(> right) = 1 - Φ(-1.00) = 1 - 15.9% = 84.1%.

So total probability of a Type II error is 1 – the probability of being in the two tails is

Pr(Non - Rejection|Ho is false) = 1 - [Pr(< left) + Pr(> right)] ≈ 1 - 84.1% = 15.9%

Therefore, the power of the test is 84.1%.

b. The requirement is to have 1 - [Pr(< left) + Pr(> right)] = 1%

Clearly, as n increases from 10, the probability of being in the left-hand tail will only decrease from already being close to zero.

Therefore, the requirement becomes 1 - Pr(> right) = 0.01

This occurs at a Z-score of (using the Excel function NORMSINV) -2.32.

Accordingly, the following equations need to be solved

1.65σH0=1.65/n=K1.65 * \sigma_{H_0} =1.65/ \sqrt n=K and

+K11.5n=2.32\frac{+K-1}{\frac{1.5}{\sqrt n}}=-2.32

Plugging in K yields:

1.65n11.5n=1.65n1.5=2.32n=5.13\frac{\frac{1.65}{\sqrt n}-1}{\frac{1.5}{\sqrt n}}= \frac{1.65-\sqrt n}{1.5}=-2.32\geq \sqrt n=5.13 n=26.3\geq n=26.3

And because partial observations are not allowed, n = 27.

为什么total probability of a Type II error is 1 – the probability of being in the two tails


P(Type II error) = P(H0假&接受H0)/P(H0假)=1-P(H0假&拒绝H0)/P(H0假)


但我觉得the probability of being in the two tails = P(H0假&拒绝H0)啊

4 个答案

品职答疑小助手雍 · 2024年05月12日

我想不出来你这样的计算方法的计算过程,可以列一下计算过程么?要不看不出来问题在哪。

品职答疑小助手雍 · 2024年05月11日

A的解析算的不就是错误分布带到真实对应的分位点,然后求存伪的概率么?

Ella · 2024年05月12日

我觉得A问的解析做反了,应该先拿真实分布先算个置信区间,再代入错误分布算被接受的概率

品职答疑小助手雍 · 2024年05月10日

你这样算没办法求n的。

3等评价说明我的回答有问题,如果觉得之前回答的解法有什么问题请指出哪里有逻辑不通或者错误。

Ella · 2024年05月11日

我说的是A问

品职答疑小助手雍 · 2024年05月06日

同学你好,type II error即存伪,也就是在H0是假的时候(错误地)接受了它的概率

A问:它问的是犯第二类错误的概率,存伪,也就是没有拒绝错误的H0的概率。

首先根据中心极限定理,如果按0,1的正态分布有10个样本的话,标准误应该是1/根号10,等于0.316。

均值是0,90%置信度下的区间就是0加减1.65*0.316=正负0.522这个区间。

但是实际上分布却是(1,2.25),这个分布的标准差是根号下2.25(这里答案里多打了个2),也就是1.5。

十个样本的话标准误是1.5除以根号10,等于0.474。

然后要考虑的是之前假设算的正负0.522这个区间被接受的概率。

-0.522和0.522在真实的分布里对应的分位点分别是-3.21和-1。

-3.21离均值太远了肯定会被拒绝的,主要就看-1对应的被拒绝的概率,查表可得分位点1对应的是0.8413。

那么-1左边就有15.9%的累计概率,也就是被接受的概率。被接受就相当于存伪了(没有拒绝这个错误的假设) 所以第二类错误的概率就是15.9%,而test power用1减15.9%就可以了。


B问的考点:n的多少,会决定H0中的样本标准差:样本标准差 = 1/根号下n

犯第二类错误的概率小于等于1,也就是使得 落入中间接受域的概率小于等于,也就是使得 落入两个尾巴的概率大于等于99%。而由第一问,当n增大时,它落入左边尾巴的概率会越来越小、接近于0,因此处于简化不用看左边尾巴的情况。所以,就变成了 1 - Pr(> right) = 0.01(为了计算方便,这边由大于等于号变成了等于号)。

所以,Pr(> right) = 0.99,所以这个right对应的应该是-2.33(根据特殊的分位数,这个数应该要记得)。而这个right=-2.33是经过标准化的,它应该等于 (1.65*1/根号下n - 1 ) / (1.5/根号n) ,最后求出n。

Ella · 2024年05月09日

我觉得做反了,应该拿真实分布先算个置信区间,再代入错误分布算被接受的概率

  • 4

    回答
  • 0

    关注
  • 169

    浏览
相关问题

NO.PZ2020010304000053 问题如下 A ta management group wants to test the null hypothesis thobserveta is N(0,1) stributeevaluating the meof a set of ranm aws. However, the actuunrlying ta is stributeN(1, 2.25). If the sample size is 10, whis the probability of a Type II error anthe power of the test? Assume a 90% confinlevel on a two-sitest.How many samples woulneeto taken to rethe probability of a Type II error to less th1%? When the null hypothesis is false, the probability of a Type II error is equto the probability ththe hypothesis fails to rejecteNow, if there are 10 samples taken from N(0,1) then the stanrviation is receH0=1/10=0.316\sigma_{H_0}=1/ \sqrt{10}=0.316σH0​​=1/10​=0.316Therefore, the cut-off points are ±1.65∗0.316=±0.522\pm1.65 * 0.316 = \pm0.522±1.65∗0.316=±0.522In actuality, the true stribution is N(1,2.25), so the σ=22.25=1.5\sigma = \sqrt{22.25} = 1.5σ=22.25​=1.5. For a sample size of 10, the expectesample stanrviation isσsample=1.5/10=0.474\sigma_{sample}=1.5/ \sqrt{10} = 0.474σsample​=1.5/10​=0.474Calculating the equivalent stanof ±1.65\pm1.65±1.65 in this stribution compareto a stanrN(0,1) yielleft = (-0.522-1)/0.474=-3.21anright =(+0.522 - 1)/ 0.474 = -1.00The probability of being on the left-hansi is practically zero. For the right, Pr( right) = 1 - Φ(-1.00) = 1 - 15.9% = 84.1%.So totprobability of a Type II error is 1 – the probability of being in the two tails isPr(Non - Rejection|Ho is false) = 1 - [Pr( left) + Pr( right)] ≈ 1 - 84.1% = 15.9%Therefore, the power of the test is 84.1%.The requirement is to have 1 - [Pr( left) + Pr( right)] = 1%Clearly, n increases from 10, the probability of being in the left-hantail will only crease from alrea being close to zero.Therefore, the requirement becomes 1 - Pr( right) = 0.01This occurs a Z-score of (using the Excel function NORMSINV) -2.32.Accorngly, the following equations neeto solve.65∗σH0=1.65/n=K1.65 * \sigma_{H_0} =1.65/ \sqrt n=K1.65∗σH0​​=1.65/n​=K an+K−11.5n=−2.32\frac{+K-1}{\frac{1.5}{\sqrt n}}=-2.32n​1.5​+K−1​=−2.32Plugging in K yiel: 1.65n−11.5n=1.65−n1.5=−2.32≥n=5.13\frac{\frac{1.65}{\sqrt n}-1}{\frac{1.5}{\sqrt n}}= \frac{1.65-\sqrt n}{1.5}=-2.32\geq \sqrt n=5.13n​1.5​n​1.65​−1​=1.51.65−n​​=−2.32≥n​=5.13 ≥n=26.3\geq n=26.3≥n=26.3Anbecause partiobservations are not allowe n = 27. 请问这个observeta是指什么?是抽样一次得到的数据么?

2024-04-28 13:41 1 · 回答

NO.PZ2020010304000053 问题如下 A ta management group wants to test the null hypothesis thobserveta is N(0,1) stributeevaluating the meof a set of ranm aws. However, the actuunrlying ta is stributeN(1, 2.25). If the sample size is 10, whis the probability of a Type II error anthe power of the test? Assume a 90% confinlevel on a two-sitest.How many samples woulneeto taken to rethe probability of a Type II error to less th1%? When the null hypothesis is false, the probability of a Type II error is equto the probability ththe hypothesis fails to rejecteNow, if there are 10 samples taken from N(0,1) then the stanrviation is receH0=1/10=0.316\sigma_{H_0}=1/ \sqrt{10}=0.316σH0​​=1/10​=0.316Therefore, the cut-off points are ±1.65∗0.316=±0.522\pm1.65 * 0.316 = \pm0.522±1.65∗0.316=±0.522In actuality, the true stribution is N(1,2.25), so the σ=22.25=1.5\sigma = \sqrt{22.25} = 1.5σ=22.25​=1.5. For a sample size of 10, the expectesample stanrviation isσsample=1.5/10=0.474\sigma_{sample}=1.5/ \sqrt{10} = 0.474σsample​=1.5/10​=0.474Calculating the equivalent stanof ±1.65\pm1.65±1.65 in this stribution compareto a stanrN(0,1) yielleft = (-0.522-1)/0.474=-3.21anright =(+0.522 - 1)/ 0.474 = -1.00The probability of being on the left-hansi is practically zero. For the right, Pr( right) = 1 - Φ(-1.00) = 1 - 15.9% = 84.1%.So totprobability of a Type II error is 1 – the probability of being in the two tails isPr(Non - Rejection|Ho is false) = 1 - [Pr( left) + Pr( right)] ≈ 1 - 84.1% = 15.9%Therefore, the power of the test is 84.1%.The requirement is to have 1 - [Pr( left) + Pr( right)] = 1%Clearly, n increases from 10, the probability of being in the left-hantail will only crease from alrea being close to zero.Therefore, the requirement becomes 1 - Pr( right) = 0.01This occurs a Z-score of (using the Excel function NORMSINV) -2.32.Accorngly, the following equations neeto solve.65∗σH0=1.65/n=K1.65 * \sigma_{H_0} =1.65/ \sqrt n=K1.65∗σH0​​=1.65/n​=K an+K−11.5n=−2.32\frac{+K-1}{\frac{1.5}{\sqrt n}}=-2.32n​1.5​+K−1​=−2.32Plugging in K yiel: 1.65n−11.5n=1.65−n1.5=−2.32≥n=5.13\frac{\frac{1.65}{\sqrt n}-1}{\frac{1.5}{\sqrt n}}= \frac{1.65-\sqrt n}{1.5}=-2.32\geq \sqrt n=5.13n​1.5​n​1.65​−1​=1.51.65−n​​=−2.32≥n​=5.13 ≥n=26.3\geq n=26.3≥n=26.3Anbecause partiobservations are not allowe n = 27. 这道题题干能不能翻译一下

2024-04-26 15:42 1 · 回答

NO.PZ2020010304000053 问题如下 A ta management group wants to test the null hypothesis thobserveta is N(0,1) stributeevaluating the meof a set of ranm aws. However, the actuunrlying ta is stributeN(1, 2.25). If the sample size is 10, whis the probability of a Type II error anthe power of the test? Assume a 90% confinlevel on a two-sitest.How many samples woulneeto taken to rethe probability of a Type II error to less th1%? When the null hypothesis is false, the probability of a Type II error is equto the probability ththe hypothesis fails to rejecteNow, if there are 10 samples taken from N(0,1) then the stanrviation is receH0=1/10=0.316\sigma_{H_0}=1/ \sqrt{10}=0.316σH0​​=1/10​=0.316Therefore, the cut-off points are ±1.65∗0.316=±0.522\pm1.65 * 0.316 = \pm0.522±1.65∗0.316=±0.522In actuality, the true stribution is N(1,2.25), so the σ=22.25=1.5\sigma = \sqrt{22.25} = 1.5σ=22.25​=1.5. For a sample size of 10, the expectesample stanrviation isσsample=1.5/10=0.474\sigma_{sample}=1.5/ \sqrt{10} = 0.474σsample​=1.5/10​=0.474Calculating the equivalent stanof ±1.65\pm1.65±1.65 in this stribution compareto a stanrN(0,1) yielleft = (-0.522-1)/0.474=-3.21anright =(+0.522 - 1)/ 0.474 = -1.00The probability of being on the left-hansi is practically zero. For the right, Pr( right) = 1 - Φ(-1.00) = 1 - 15.9% = 84.1%.So totprobability of a Type II error is 1 – the probability of being in the two tails isPr(Non - Rejection|Ho is false) = 1 - [Pr( left) + Pr( right)] ≈ 1 - 84.1% = 15.9%Therefore, the power of the test is 84.1%.The requirement is to have 1 - [Pr( left) + Pr( right)] = 1%Clearly, n increases from 10, the probability of being in the left-hantail will only crease from alrea being close to zero.Therefore, the requirement becomes 1 - Pr( right) = 0.01This occurs a Z-score of (using the Excel function NORMSINV) -2.32.Accorngly, the following equations neeto solve.65∗σH0=1.65/n=K1.65 * \sigma_{H_0} =1.65/ \sqrt n=K1.65∗σH0​​=1.65/n​=K an+K−11.5n=−2.32\frac{+K-1}{\frac{1.5}{\sqrt n}}=-2.32n​1.5​+K−1​=−2.32Plugging in K yiel: 1.65n−11.5n=1.65−n1.5=−2.32≥n=5.13\frac{\frac{1.65}{\sqrt n}-1}{\frac{1.5}{\sqrt n}}= \frac{1.65-\sqrt n}{1.5}=-2.32\geq \sqrt n=5.13n​1.5​n​1.65​−1​=1.51.65−n​​=−2.32≥n​=5.13 ≥n=26.3\geq n=26.3≥n=26.3Anbecause partiobservations are not allowe n = 27. 这道题如果没有给真实分布的话,那么可以认为type II 的概率是90%么?还是说没给真实分布的话,这道题解不出来?

2024-04-24 16:12 1 · 回答

NO.PZ2020010304000053问题如下A ta management group wants to test the null hypothesis thobserveta is N(0,1) stributeevaluating the meof a set of ranm aws. However, the actuunrlying ta is stributeN(1, 2.25). If the sample size is 10, whis the probability of a Type II error anthe power of the test? Assume a 90% confinlevel on a two-sitest.How many samples woulneeto taken to rethe probability of a Type II error to less th1%?When the null hypothesis is false, the probability of a Type II error is equto the probability ththe hypothesis fails to rejecteNow, if there are 10 samples taken from N(0,1) then the stanrviation is receH0=1/10=0.316\sigma_{H_0}=1/ \sqrt{10}=0.316σH0​​=1/10​=0.316Therefore, the cut-off points are ±1.65∗0.316=±0.522\pm1.65 * 0.316 = \pm0.522±1.65∗0.316=±0.522In actuality, the true stribution is N(1,2.25), so the σ=22.25=1.5\sigma = \sqrt{22.25} = 1.5σ=22.25​=1.5. For a sample size of 10, the expectesample stanrviation isσsample=1.5/10=0.474\sigma_{sample}=1.5/ \sqrt{10} = 0.474σsample​=1.5/10​=0.474Calculating the equivalent stanof ±1.65\pm1.65±1.65 in this stribution compareto a stanrN(0,1) yielleft = (-0.522-1)/0.474=-3.21anright =(+0.522 - 1)/ 0.474 = -1.00The probability of being on the left-hansi is practically zero. For the right, Pr( right) = 1 - Φ(-1.00) = 1 - 15.9% = 84.1%.So totprobability of a Type II error is 1 – the probability of being in the two tails isPr(Non - Rejection|Ho is false) = 1 - [Pr( left) + Pr( right)] ≈ 1 - 84.1% = 15.9%Therefore, the power of the test is 84.1%.The requirement is to have 1 - [Pr( left) + Pr( right)] = 1%Clearly, n increases from 10, the probability of being in the left-hantail will only crease from alrea being close to zero.Therefore, the requirement becomes 1 - Pr( right) = 0.01This occurs a Z-score of (using the Excel function NORMSINV) -2.32.Accorngly, the following equations neeto solve.65∗σH0=1.65/n=K1.65 * \sigma_{H_0} =1.65/ \sqrt n=K1.65∗σH0​​=1.65/n​=K an+K−11.5n=−2.32\frac{+K-1}{\frac{1.5}{\sqrt n}}=-2.32n​1.5​+K−1​=−2.32Plugging in K yiel: 1.65n−11.5n=1.65−n1.5=−2.32≥n=5.13\frac{\frac{1.65}{\sqrt n}-1}{\frac{1.5}{\sqrt n}}= \frac{1.65-\sqrt n}{1.5}=-2.32\geq \sqrt n=5.13n​1.5​n​1.65​−1​=1.51.65−n​​=−2.32≥n​=5.13 ≥n=26.3\geq n=26.3≥n=26.3Anbecause partiobservations are not allowe n = 27.老师好,这个部分使用的公式里面减去均值再除以标准差的那个X不是实际分布里面的X吗?也就是说公式是把不标准的正态分布标准化。可是这道题里面的正负0.522已经是标准正态分布里的分位点了,还可以用这个分位点的数值再标准化吗?

2024-03-06 15:19 1 · 回答