Hypothesis test: decide the test variable ic in normal distribution.

137 Views Asked by At

I know that the test variable is based on the estimation of the parameter. So, if we have an sample of size $n$ from $N(\mu,\sigma^2)$, $\sigma^2$ known, and want to test $H_0: \mu=\mu_0$, then the test variable can be $$T=\mu^*$$ which is same as$$T=\frac{1}{n}\sum_{i=1}^{n}x_i$$ But since T is an observation of $T(X)$~$N(\mu,\sigma^2/\sqrt{n})$, we can use standardized normal distribution and use the test variable $$Z=\frac{\frac{1}{n}\sum_{i=1}^{n}x_i-\mu}{\sigma/\sqrt{n}}$$ instead. This test variable is an observation of $$Z(X)=\frac{\frac{1}{n}\sum_{i=1}^{n}X_i-\mu}{\sigma/\sqrt{n}}$$ which is ~$N(0,1)$ if $H_0$ is true. Are my reasonings right?

1

There are 1 best solutions below

7
On BEST ANSWER

Your algebra is OK, but since you're in some doubt (and you need some practice with notation), lets use an example as a reality check.

Suppose $H_0:~\mu = 0,$ $H_A:~\mu = 10,$ and $\sigma = 5$. Then the test statistic can be either $T = \bar X \sim N(0, 25)$ or $Z = \sqrt{n}(\bar X - 0)/\sigma$ (using the usual letter Z for a standard normal random variable). We illustrate both methods below.

In particular, suppose $n = 16$ and we have the random sample generated below from the distribution $N(0, 25)$, using R software:

n = 16; x = round(rnorm(16, 0, 5), 3); x}

[1] 1.075 -0.911 -2.727 2.503 -1.184 5.492 -10.033 8.497 1.233

[10] -4.827 -6.928 8.076 4.591 1.499 1.673 5.942

mean(x)

[1] 0.8731875

Thus, rounded to three places, $T = \bar X = 0.873$. (BTW, notice that this software uses the standard deviation instead of the variance in its notation for the normal distribution.)

Test using the sample mean. For a test at the 5% level, the critical value separating the Acceptance region at left from the Rejection region at right, would be found by cutting off 5% from the upper tail of the distribution $N(0, 25/16)$. You could use software to find the critical value or standardize and use printed normal tables. The critical value is $T_c = 2.056$. (In R, the code 'qnorm(.95, 0, 5/4)' returns 2.056067. Check with your favorite software or use normal tables.) In our case, $T = 0.873 < T_c = 2.056,$ so we do not reject the null hypothesis $H_0$.

Using the standard normal distribution. Now, using the standardized version of the test statistic, we have $Z = (0.873 - 0)/(5/4) = 0.6984$ and in terms of the standard normal distribution the critical value is $Z_c = 1.645$. Again, we do not reject the null hypothesis because $Z = 0.6984 < Z_c = 1.645$.

Generally, statisticians prefer the latter method. After some experience, this exact testing situation will have arisen enough times that a statistician remembers "the critical value for a z-test of a null hypothesis against a right-sided alternative at the 5% level is 1.645." So as soon as he/she sees the test statistic Z, the conclusion (whether or not to reject) is obvious.

P-value. While we're at it, I'll mention that the P-value for this particular test and data is the area under the standard normal curve to the right of 0.6984. The answer is 0.2425 or about 25%. For a test at the 5% level of significance, any P-value LESS than 5% leads to rejection of the null hypothesis. (Can you figure out how to find this P-value?)

Why this test is "right-sided. Notice that we never used the exact value of $\mu_A$ in any of the computations above. We did, however, use the fact that $\mu_A > \mu_0$ to know that this is a RIGHT-tailed test and that we need to to look in the RIGHT tail of the normal distribution to find the critical value. (Can you figure out how the tests change if $\mu_0 = 10$ and $\mu_A = 0$? And whether you'd reject, using exactly the same data as above?)