^ Where are the alleged pvalue comparisons? You just posted the original code, changing only sample size.
CG doesn't understand basic statistics

^
Here's a question for you: If one sample mean is normally distributed and a second sample mean is normally distributed, and we know that the sum or difference of two normals is also normal, does that mean the hypothesis test for their difference will follow a normal under the null? The answer is no. If you can figure out why, you can also figure out how your whole logic is nonsensical, on top of the excruciating mistakes with sample size, dof, beta's distribution, etc., etc.The difference in means from two normals is normal, but that's not your test statistic. You use the twosample tstatistic. Which is the twosample analog of the tstatistic for one sample. The approach is similar: you divide the difference in centered means by the square root of the sum of sample variances to obtain an approximately t distributed test statistic. Just as you divide the sample mean by the square root of the sample variance to get your tstatistic in the one sample case. That T variable that Casella and Berger want you to construct in that exercise. Is that clear now?
Yes, very good. You've proven my point. The two quantities are normal, their theoretical distribution is normal, but you use a t statistic to tell their difference. Get the point now? Can you see how what Collin was doing was missing the point entirely?
And for the millionth time, Casella & Berger don't ask you to construct anything. They rather ask you to show that you can use the sample mean as a test statistic. They literally give you an equation showing you that this works. The way you prove something does not invalidate it being true. Say it with me now: The way you prove something does not invalidate it being true. Even you are smart enough to eventually understand this. I think.

^ Where are the alleged pvalue comparisons? You just posted the original code, changing only sample size.
I don't follow. I showed you the output from using three different seeds. Are you asking how you run something in R?
Or is the problem that you're too lazy to notice that one uses a t and the other a normal for the critical values?

^
Here's a question for you: If one sample mean is normally distributed and a second sample mean is normally distributed, and we know that the sum or difference of two normals is also normal, does that mean the hypothesis test for their difference will follow a normal under the null? The answer is no. If you can figure out why, you can also figure out how your whole logic is nonsensical, on top of the excruciating mistakes with sample size, dof, beta's distribution, etc., etc.
The difference in means from two normals is normal, but that's not your test statistic. You use the twosample tstatistic. Which is the twosample analog of the tstatistic for one sample. The approach is similar: you divide the difference in centered means by the square root of the sum of sample variances to obtain an approximately t distributed test statistic. Just as you divide the sample mean by the square root of the sample variance to get your tstatistic in the one sample case. That T variable that Casella and Berger want you to construct in that exercise. Is that clear now?Yes, very good. You've proven my point. The two quantities are normal, their theoretical distribution is normal, but you use a t statistic to tell their difference. Get the point now? Can you see how what Collin was doing was missing the point entirely?
And for the millionth time, Casella & Berger don't ask you to construct anything. They rather ask you to show that you can use the sample mean as a test statistic. They literally give you an equation showing you that this works. The way you prove something does not invalidate it being true. Say it with me now: The way you prove something does not invalidate it being true. Even you are smart enough to eventually understand this. I think.You get that tstatistic by diving the mean or difference in means by the square root of the variance. That means you're NOT using the sample mean, or difference in means, as your test statistic. And you are using the fact that the mean is normal, and the variance is a Chisquared, to derive that tdistributed t statistic. Simple transformations to get that new r.v. that acts as your test statistic. I'm probably the 100th poster who explains this to you.
C&B effectively construct a new test statistic according to the procedure above. See their solutions.
Feel free to disagree, but don't be dishonest.

You get that tstatistic by diving the mean or difference in means by the square root of the variance. That means you're NOT using the sample mean, or difference in means, as your test statistic. And you are using the fact that the mean is normal, and the variance is a Chisquared, to derive that tdistributed t statistic. Simple transformations to get that new r.v. that acts as your test statistic. I'm probably the 100th poster who explains this to you.
C&B effectively construct a new test statistic according to the procedure above. See their solutions.
Feel free to disagree, but don't be dishonest.False. The problem is you just don't understand what the definition of a test statistic is. If you set up a statistic and then test a hypothesis by comparing that statistic to critical values under a null, then it's a test statistic by any possible definition. This is exactly what C&B do with the sample mean. You're numbskull response is that they show why this works by doing transformations in the solutions, which has *nothing* to do with the question of whether the sample mean is working there as a test stat. It is. It works. It's obvious. You lose.

You get that tstatistic by diving the mean or difference in means by the square root of the variance. That means you're NOT using the sample mean, or difference in means, as your test statistic. And you are using the fact that the mean is normal, and the variance is a Chisquared, to derive that tdistributed t statistic. Simple transformations to get that new r.v. that acts as your test statistic. I'm probably the 100th poster who explains this to you.
C&B effectively construct a new test statistic according to the procedure above. See their solutions.
Feel free to disagree, but don't be dishonest.False. The problem is you just don't understand what the definition of a test statistic is. If you set up a statistic and then test a hypothesis by comparing that statistic to critical values under a null, then it's a test statistic by any possible definition. This is exactly what C&B do with the sample mean. You're numbskull response is that they show why this works by doing transformations in the solutions, which has *nothing* to do with the question of whether the sample mean is working there as a test stat. It is. It works. It's obvious. You lose.
What is T_{n1} in their official solutions? How is that random variable constructed, what kind of distribution does it follow, and what purpose does it serve in hypothesis testing?

What is T_{n1} in their official solutions? How is that random variable constructed, what kind of distribution does it follow, and what purpose does it serve in hypothesis testing?
Derp derp derp. Are you even serious or just trolling? How you prove something is not relevant to whether the thing being proved is true. They set up a sample mean as a test stat. Period. It's the whole point of the exercise.
To see how unbelievably stupid your response is, it's literally like if I proved that 2+2=4 by mentioning the number 3, and then you responded, "Ah, see, 2+2 doesn't equal 4 because 3 is involved, so only 3+1 can equal 4." That's your actual argument.

I hope it's the last time you lied about that Casella and Berger exercise.
You seem real butthurt that Casella & Berger embarrassingly proved you wrong. Because it does. As anyone with basic stats knowledge can understand. The fact that you're too dense to get it is noone's problem but yours.

Decided to post some fun little code. This shows a couple things: It shows the coefficient working perfectly as a test stat, exactly in the way I always claimed. Also shows the correct critical values are from the t and not the normal. (Again, this is true because you don't know the standard error, so what would be distributed normally if you knew the se requires a t. This was Collin et al.'s fundamental mistake.)
The code cycles over different desired p values. Here, it's from .01 to .1, but you can fiddle with it. Then it calculates how often a sample with true beta = 0 gives you false positives. If you understand literally anything about testing, this is what defines the correct critical values under the null. One set of sims uses a t to define the critical values, the other a normal.
The final plots show how the two different sims perform. The t performs beautifully, while the normal consistently overshoots the implied p value! On average, the t version differs from the "correct" p by .0053, the normal by 2.2 times that. Ok? The end? Time for everyone to admit they were wrong?
set.seed(14627)
pop_n = 1000000
samp_n = 25
y_pop = rnorm(pop_n)
x_pop = rnorm(pop_n)
draws = 1000sig_list = seq(0.01,.1,.01)
norm_crit = rep(NA,length(sig_list))
t_crit = rep(NA,length(sig_list))for (j in 1:length(sig_list)){
sig_result = rep(NA, draws)
for(i in 1:draws){
s = sample(1:pop_n, samp_n)
mod = lm(y_pop[s] ~ x_pop[s])
beta = coef(summary(mod))[2,1]
se = coef(summary(mod))[2,2]
rescaled_t = abs(qt(sig_list[j]/2, samp_n  2) * se)sig_result[i] = abs(beta) > rescaled_t
}
t_crit[j] = mean(sig_result)sig_result = rep(NA, draws)
for(i in 1:draws){
s = sample(1:pop_n, samp_n)
mod = lm(y_pop[s] ~ x_pop[s])
beta = coef(summary(mod))[2,1]
se = coef(summary(mod))[2,2]
rescaled_norm = abs(qnorm(sig_list[j]/2) * se)sig_result[i] = abs(beta) > rescaled_norm
}
norm_crit[j] = mean(sig_result)
}plot(sig_list,t_crit)
lines(sig_list,sig_list)
mean(abs(sig_listt_crit))plot(sig_list,norm_crit)
lines(sig_list,sig_list)
mean(abs(sig_listnorm_crit)) 
See p. 9 for theoretical proof (adapted from stats textbook) that the sampling distribution of beta is normal.
https://www.uvm.edu/~dhowell/fundamentals9/Supplements/SampDistRegCoeff.pdfIdiot *still* doesn't understand that this doesn't imply this is how you *test* the coefficient. And I already gave a clear example of where Eileen's logic fails: If you're testing a difference of two sample means, both should be normally distributed, therefore their difference is normally distributed, and yet you test it with a t. No response.
The only question under debate here (since everyone has now conceded the coefficient can work as a test statistic) is what you use to test the coefficient. What I've shown through both stats analysis and simulation evidence is that you test it with t critical values. The end.