Welcome to our community

Be a part of something great, join today!

[SOLVED] Which is the mean value of the sample?

mathmari

Well-known member
MHB Site Helper
Apr 14, 2013
4,004
Hey!! :eek:

We have the following hypotheses: $$H_0: \mu\geq 60 \ \ \ , \ \ \ H_1:\mu<60$$

A test is executed with a sample of size $25$ and an estimated standard deviation $S'=8$.

From the test we get a p-value of 5%. I want to determine the value of the mean of the sample $\overline{X}$.



The p-value is equal to $P(T\leq t\mid H_0)$. So is this in this case equal to
$P(\mu\leq 60\mid H_0)$ ?

If yes, then we have the following: $$p=0.05\Rightarrow \Phi \left (\frac{\overline{X}-60}{\frac{S'}{\sqrt{n}}}\right )=0.05 \Rightarrow \Phi \left (\frac{\overline{X}-60}{\frac{8}{\sqrt{25}}}\right )=0.05\Rightarrow \frac{\overline{X}-60}{\frac{8}{\sqrt{25}}}=\Phi^{-1}(0.05)$$ Or am I thinking wrong?

Do we use here the table of t-distribution?
 

Jameson

Administrator
Staff member
Jan 26, 2012
4,029
Hey mathmari,

I agree with your problem set up. Most people really fail to understand the concept of a p-value as a conditional probability and you very nicely stated how it is one.

There are different rules of thumb for when you can use a normal distribution to approximate a t-distribution, but the sample size seems to be $n > 30$ from what I read right now. Given that our sample is smaller than that, you might be better off using the inverse t function instead.

Overall though your understanding of the solution looks good to me. :)
 

mathmari

Well-known member
MHB Site Helper
Apr 14, 2013
4,004
I thought about that again and now I got stuck.

We have the null hypothesis $H_0: \mu\geq 60$ and the alternative hypothesis $H_1:\mu<60$.

The p-value is defined as the probability, under the null hypothesis, of obtaining a result equal to or more extreme than what was actually observed.

At the alternative hypothesis we have that what we've observed, so we have observes that $\mu<60$, or not?

So, is the p-value defined as $$P(\mu< 60\mid H_0)=P(\mu< 60\mid \mu\geq 60)$$ ? Or am I thinking wrong? (Wondering)
 

Klaas van Aarsen

MHB Seeker
Staff member
Mar 5, 2012
8,684
I thought about that again and now I got stuck.

We have the null hypothesis $H_0: \mu\geq 60$ and the alternative hypothesis $H_1:\mu<60$.

The p-value is defined as the probability, under the null hypothesis, of obtaining a result equal to or more extreme than what was actually observed.

At the alternative hypothesis we have that what we've observed, so we have observes that $\mu<60$, or not?

So, is the p-value defined as $$P(\mu< 60\mid H_0)=P(\mu< 60\mid \mu\geq 60)$$ ? Or am I thinking wrong? (Wondering)
To reject $H_0$, we want to be really sure that the probability that we are wrong is less than $\alpha$.
The expected value $\mu$ could be greater than $60$, but we pick $\mu=60$ so that if we err, it will be on the safe side.


Additionally we cannot observe $\mu$ directly. That is, not unless we measure the entire population.
After all, isn't $P(\mu< 60\mid \mu\geq 60)=0$? $\mu$ cannot both be greater and less than $60$ can it? (Wondering)

Instead we observe the mean $\overline x$ of a sample, which is an instance of the random variable $\overline X$ of sample means.
So we have:
$$p\text{-value} = P(\overline X < \overline x\mid \mu=60)$$
(Thinking)
 

mathmari

Well-known member
MHB Site Helper
Apr 14, 2013
4,004
To reject $H_0$, we want to be really sure that the probability that we are wrong is less than $\alpha$.
The expected value $\mu$ could be greater than $60$, but we pick $\mu=60$ so that if we err, it will be on the safe side.


Additionally we cannot observe $\mu$ directly. That is, not unless we measure the entire population.
After all, isn't $P(\mu< 60\mid \mu\geq 60)=0$? $\mu$ cannot both be greater and less than $60$ can it? (Wondering)

Instead we observe the mean $\overline x$ of a sample, which is an instance of the random variable $\overline X$ of sample means.
So we have:
$$p\text{-value} = P(\overline X < \overline x\mid \mu=60)$$
(Thinking)
Ah ok!! So we have the following: $$p\text{-value} = P(\overline X < \overline x\mid \mu=60)=t_{25}\left (\frac{\overline{x}-\mu}{\frac{S'}{\sqrt{n}}}\right )=t_{25}\left (\frac{\overline{x}-60}{\frac{8}{\sqrt{25}}}\right )=t_{25}\left (\frac{\overline{x}-60}{\frac{8}{5}}\right )=t_{25}\left (\frac{5}{8}\left[\overline{x}-60\right ]\right )$$ or not? (Wondering)

So it must be $$t_{25}\left (\frac{5}{8}\left[\overline{x}-60\right ]\right )=0.05$$


I used the online R compiler and got this result. Is this correct, or do I have to write something else there? (Wondering)
 
Last edited:

Klaas van Aarsen

MHB Seeker
Staff member
Mar 5, 2012
8,684
Ah ok!! So we have the following: $$p\text{-value} = P(\overline X < \overline x\mid \mu=60)=t_{25}\left (\frac{\overline{x}-\mu}{\frac{S'}{\sqrt{n}}}\right )=t_{25}\left (\frac{\overline{x}-60}{\frac{8}{\sqrt{25}}}\right )=t_{25}\left (\frac{\overline{x}-60}{\frac{8}{5}}\right )=t_{25}\left (\frac{5}{8}\left[\overline{x}-60\right ]\right )$$ or not?

So it must be $$t_{25}\left (\frac{5}{8}\left[\overline{x}-60\right ]\right )=0.05$$
Since we have $n=25$ we have $df=n-1=25-1$ don't we? (Wondering)
I think we need:
$$t_{25-1}\left (\frac{5}{8}\left[\overline{x}-60\right ]\right )=0.05$$

I used the online R compiler and got this result. Is this correct, or do I have to write something else there?
If I follow that link, I only see some default commands. (Worried)
What did you execute, and what was its result?
 

mathmari

Well-known member
MHB Site Helper
Apr 14, 2013
4,004
Since we have $n=25$ we have $df=n-1=25-1$ don't we? (Wondering)
I think we need:
$$t_{25-1}\left (\frac{5}{8}\left[\overline{x}-60\right ]\right )=0.05$$
Ah ok!!

If I follow that link, I only see some default commands. (Worried)
What did you execute, and what was its result?
Now I wrote [m]qt(0.05, 24)[/m]
Is this wrong? (Wondering)
 

Klaas van Aarsen

MHB Seeker
Staff member
Mar 5, 2012
8,684

mathmari

Well-known member
MHB Site Helper
Apr 14, 2013
4,004
That seems fine to me.
So now we can solve for $\overline x$. (Happy)
We have that \begin{align*}&t_{24}\left (\frac{5}{8}\left[\overline{x}-60\right ]\right )=0.05\Rightarrow \frac{5}{8}\left[\overline{x}-60\right ]=-1.710882 \Rightarrow \frac{5}{8}\overline{x}-37.5=-1.710882 \Rightarrow \frac{5}{8}\overline{x}=35.789118 \\ & \Rightarrow \overline{x}=57.2625888\end{align*}


I want to determine the value of the mean of the sample $\overline{X}$.
Is $\overline{x}$ what we want to calculate or $\overline{X}$ ? (Wondering)
 

Klaas van Aarsen

MHB Seeker
Staff member
Mar 5, 2012
8,684
It's the same thing.
The question asks for the mean of the observed sample. And that is what you found.
Usually we use lower case for observed measurements, and upper case for random variables. But it's not unusual either that this convention is ignored, or applied sloppily. (Nerd)
 

mathmari

Well-known member
MHB Site Helper
Apr 14, 2013
4,004
It's the same thing.
The question asks for the mean of the observed sample. And that is what you found.
Usually we use lower case for observed measurements, and upper case for random variables. But it's not unusual either that this convention is ignored, or applied sloppily. (Nerd)
Ah ok!! Thank you very much!! (Sun)