p-value of the following test
$begingroup$
I have the following problem:
I have $X_1 ... X_n$ ~ Bernoulli(p) independent.
I also have the following test hypothesis: $H_0: p = p_0$ and $H_1: p > p_0$. I define my test as follows:
$T:$ I refuse $H_0$ in favour of $P_1$ if the number of successes is very high.
Now suppose $p_0 = 0.6$ and $n = 20$, we find that we have 18 successes.
I want to find the p-value of the test.
Now this is what I have done:
$p-value = mathbb{P}(sum x_i geq 18)$ = 0.0005240494
However confronting it with the command:
binom.test(18,20,p=.6,alternative=greater)
It is not right (by a factor of 10). My problem is that I am not able to correctly asses what the "number of succession is very high". How do I work around this?
probability statistics hypothesis-testing p-value
$endgroup$
add a comment |
$begingroup$
I have the following problem:
I have $X_1 ... X_n$ ~ Bernoulli(p) independent.
I also have the following test hypothesis: $H_0: p = p_0$ and $H_1: p > p_0$. I define my test as follows:
$T:$ I refuse $H_0$ in favour of $P_1$ if the number of successes is very high.
Now suppose $p_0 = 0.6$ and $n = 20$, we find that we have 18 successes.
I want to find the p-value of the test.
Now this is what I have done:
$p-value = mathbb{P}(sum x_i geq 18)$ = 0.0005240494
However confronting it with the command:
binom.test(18,20,p=.6,alternative=greater)
It is not right (by a factor of 10). My problem is that I am not able to correctly asses what the "number of succession is very high". How do I work around this?
probability statistics hypothesis-testing p-value
$endgroup$
$begingroup$
What is the confidence level and significance level, respectively? Maybe 0.95 and 1-0.95=0.05?
$endgroup$
– callculus
Jan 17 at 21:19
1
$begingroup$
I don't have that information. I don't think is needed as the purpose of the p-value is to work without one, from my understanding.
$endgroup$
– qcc101
Jan 17 at 21:56
1
$begingroup$
$mathbb{P}(sum X_i geq 18)=0.0036$
$endgroup$
– d.k.o.
Jan 17 at 23:27
$begingroup$
@d.k.o. I see, maybe I messed up my calculation. Still, is this the right way to do it?
$endgroup$
– qcc101
Jan 18 at 9:35
$begingroup$
Yes this is the correct way to do it
$endgroup$
– Alex
Jan 22 at 7:12
add a comment |
$begingroup$
I have the following problem:
I have $X_1 ... X_n$ ~ Bernoulli(p) independent.
I also have the following test hypothesis: $H_0: p = p_0$ and $H_1: p > p_0$. I define my test as follows:
$T:$ I refuse $H_0$ in favour of $P_1$ if the number of successes is very high.
Now suppose $p_0 = 0.6$ and $n = 20$, we find that we have 18 successes.
I want to find the p-value of the test.
Now this is what I have done:
$p-value = mathbb{P}(sum x_i geq 18)$ = 0.0005240494
However confronting it with the command:
binom.test(18,20,p=.6,alternative=greater)
It is not right (by a factor of 10). My problem is that I am not able to correctly asses what the "number of succession is very high". How do I work around this?
probability statistics hypothesis-testing p-value
$endgroup$
I have the following problem:
I have $X_1 ... X_n$ ~ Bernoulli(p) independent.
I also have the following test hypothesis: $H_0: p = p_0$ and $H_1: p > p_0$. I define my test as follows:
$T:$ I refuse $H_0$ in favour of $P_1$ if the number of successes is very high.
Now suppose $p_0 = 0.6$ and $n = 20$, we find that we have 18 successes.
I want to find the p-value of the test.
Now this is what I have done:
$p-value = mathbb{P}(sum x_i geq 18)$ = 0.0005240494
However confronting it with the command:
binom.test(18,20,p=.6,alternative=greater)
It is not right (by a factor of 10). My problem is that I am not able to correctly asses what the "number of succession is very high". How do I work around this?
probability statistics hypothesis-testing p-value
probability statistics hypothesis-testing p-value
asked Jan 17 at 20:31
qcc101qcc101
629213
629213
$begingroup$
What is the confidence level and significance level, respectively? Maybe 0.95 and 1-0.95=0.05?
$endgroup$
– callculus
Jan 17 at 21:19
1
$begingroup$
I don't have that information. I don't think is needed as the purpose of the p-value is to work without one, from my understanding.
$endgroup$
– qcc101
Jan 17 at 21:56
1
$begingroup$
$mathbb{P}(sum X_i geq 18)=0.0036$
$endgroup$
– d.k.o.
Jan 17 at 23:27
$begingroup$
@d.k.o. I see, maybe I messed up my calculation. Still, is this the right way to do it?
$endgroup$
– qcc101
Jan 18 at 9:35
$begingroup$
Yes this is the correct way to do it
$endgroup$
– Alex
Jan 22 at 7:12
add a comment |
$begingroup$
What is the confidence level and significance level, respectively? Maybe 0.95 and 1-0.95=0.05?
$endgroup$
– callculus
Jan 17 at 21:19
1
$begingroup$
I don't have that information. I don't think is needed as the purpose of the p-value is to work without one, from my understanding.
$endgroup$
– qcc101
Jan 17 at 21:56
1
$begingroup$
$mathbb{P}(sum X_i geq 18)=0.0036$
$endgroup$
– d.k.o.
Jan 17 at 23:27
$begingroup$
@d.k.o. I see, maybe I messed up my calculation. Still, is this the right way to do it?
$endgroup$
– qcc101
Jan 18 at 9:35
$begingroup$
Yes this is the correct way to do it
$endgroup$
– Alex
Jan 22 at 7:12
$begingroup$
What is the confidence level and significance level, respectively? Maybe 0.95 and 1-0.95=0.05?
$endgroup$
– callculus
Jan 17 at 21:19
$begingroup$
What is the confidence level and significance level, respectively? Maybe 0.95 and 1-0.95=0.05?
$endgroup$
– callculus
Jan 17 at 21:19
1
1
$begingroup$
I don't have that information. I don't think is needed as the purpose of the p-value is to work without one, from my understanding.
$endgroup$
– qcc101
Jan 17 at 21:56
$begingroup$
I don't have that information. I don't think is needed as the purpose of the p-value is to work without one, from my understanding.
$endgroup$
– qcc101
Jan 17 at 21:56
1
1
$begingroup$
$mathbb{P}(sum X_i geq 18)=0.0036$
$endgroup$
– d.k.o.
Jan 17 at 23:27
$begingroup$
$mathbb{P}(sum X_i geq 18)=0.0036$
$endgroup$
– d.k.o.
Jan 17 at 23:27
$begingroup$
@d.k.o. I see, maybe I messed up my calculation. Still, is this the right way to do it?
$endgroup$
– qcc101
Jan 18 at 9:35
$begingroup$
@d.k.o. I see, maybe I messed up my calculation. Still, is this the right way to do it?
$endgroup$
– qcc101
Jan 18 at 9:35
$begingroup$
Yes this is the correct way to do it
$endgroup$
– Alex
Jan 22 at 7:12
$begingroup$
Yes this is the correct way to do it
$endgroup$
– Alex
Jan 22 at 7:12
add a comment |
1 Answer
1
active
oldest
votes
$begingroup$
Letting $K=sum_i mathbb{I}(X_i = 1)$ be the number of successes, you have $K sim text{Bin}(n,p)$. Thus, your p-value is:
$$begin{equation} begin{aligned}
p equiv p(k)
&equiv mathbb{P}( K geqslant k | H_0) \[6pt]
&= mathbb{P}( K geqslant k | K sim text{Bin}(n,p_0)) \[6pt]
&= sum_{r=k}^n text{Bin}(r|n,p_0). \[6pt]
end{aligned} end{equation}$$
With $p_0=0.6$, $n=20$ and $k=18$ you get the p-value:
$$p = sum_{r=18}^{20} text{Bin}(r|20, 0.6)
= 0.003611472.$$
$endgroup$
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "69"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
noCode: true, onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3077478%2fp-value-of-the-following-test%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
$begingroup$
Letting $K=sum_i mathbb{I}(X_i = 1)$ be the number of successes, you have $K sim text{Bin}(n,p)$. Thus, your p-value is:
$$begin{equation} begin{aligned}
p equiv p(k)
&equiv mathbb{P}( K geqslant k | H_0) \[6pt]
&= mathbb{P}( K geqslant k | K sim text{Bin}(n,p_0)) \[6pt]
&= sum_{r=k}^n text{Bin}(r|n,p_0). \[6pt]
end{aligned} end{equation}$$
With $p_0=0.6$, $n=20$ and $k=18$ you get the p-value:
$$p = sum_{r=18}^{20} text{Bin}(r|20, 0.6)
= 0.003611472.$$
$endgroup$
add a comment |
$begingroup$
Letting $K=sum_i mathbb{I}(X_i = 1)$ be the number of successes, you have $K sim text{Bin}(n,p)$. Thus, your p-value is:
$$begin{equation} begin{aligned}
p equiv p(k)
&equiv mathbb{P}( K geqslant k | H_0) \[6pt]
&= mathbb{P}( K geqslant k | K sim text{Bin}(n,p_0)) \[6pt]
&= sum_{r=k}^n text{Bin}(r|n,p_0). \[6pt]
end{aligned} end{equation}$$
With $p_0=0.6$, $n=20$ and $k=18$ you get the p-value:
$$p = sum_{r=18}^{20} text{Bin}(r|20, 0.6)
= 0.003611472.$$
$endgroup$
add a comment |
$begingroup$
Letting $K=sum_i mathbb{I}(X_i = 1)$ be the number of successes, you have $K sim text{Bin}(n,p)$. Thus, your p-value is:
$$begin{equation} begin{aligned}
p equiv p(k)
&equiv mathbb{P}( K geqslant k | H_0) \[6pt]
&= mathbb{P}( K geqslant k | K sim text{Bin}(n,p_0)) \[6pt]
&= sum_{r=k}^n text{Bin}(r|n,p_0). \[6pt]
end{aligned} end{equation}$$
With $p_0=0.6$, $n=20$ and $k=18$ you get the p-value:
$$p = sum_{r=18}^{20} text{Bin}(r|20, 0.6)
= 0.003611472.$$
$endgroup$
Letting $K=sum_i mathbb{I}(X_i = 1)$ be the number of successes, you have $K sim text{Bin}(n,p)$. Thus, your p-value is:
$$begin{equation} begin{aligned}
p equiv p(k)
&equiv mathbb{P}( K geqslant k | H_0) \[6pt]
&= mathbb{P}( K geqslant k | K sim text{Bin}(n,p_0)) \[6pt]
&= sum_{r=k}^n text{Bin}(r|n,p_0). \[6pt]
end{aligned} end{equation}$$
With $p_0=0.6$, $n=20$ and $k=18$ you get the p-value:
$$p = sum_{r=18}^{20} text{Bin}(r|20, 0.6)
= 0.003611472.$$
answered Feb 13 at 23:29
BenBen
1,900215
1,900215
add a comment |
add a comment |
Thanks for contributing an answer to Mathematics Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
Use MathJax to format equations. MathJax reference.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3077478%2fp-value-of-the-following-test%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
$begingroup$
What is the confidence level and significance level, respectively? Maybe 0.95 and 1-0.95=0.05?
$endgroup$
– callculus
Jan 17 at 21:19
1
$begingroup$
I don't have that information. I don't think is needed as the purpose of the p-value is to work without one, from my understanding.
$endgroup$
– qcc101
Jan 17 at 21:56
1
$begingroup$
$mathbb{P}(sum X_i geq 18)=0.0036$
$endgroup$
– d.k.o.
Jan 17 at 23:27
$begingroup$
@d.k.o. I see, maybe I messed up my calculation. Still, is this the right way to do it?
$endgroup$
– qcc101
Jan 18 at 9:35
$begingroup$
Yes this is the correct way to do it
$endgroup$
– Alex
Jan 22 at 7:12