Re: ONLY STUPID PEOPLE DOESN´T CHEK ITS BELIEFS.
- From: Jack Tomsky <jtomsky@xxxxxxxxxxxxx>
- Date: Tue, 25 Dec 2007 21:45:55 EST
The believers ... and the others
Ordinary it’s believed that the difference between to
Population means, drawn from Normal Populations
having the same variance follows the Student t
distribution. I’ll show that it is not SO: the
critical values depend on the sample sizes.
The absolute weapon shall be used to do it: Monte
Carlo simulations.
The simulated data is
_________ X~N(0, 1) : nX , Y~N(0, 1): nY
The means are both ZERO because H0 demand, and the
variances are both 1 because they are supposed equal
(with no loss of generality).
__nX_nY___95%Cumulative_____99%_____
__15_15__2.050 (2.048)____ 2.768 (2.763)___
__10_20__2.097__________ 2.859_________
___5_25__2.390__________ 3.473_________
Only with nX= nY the cv are those of the Student t
distribution with nX + nY - 2 degrees of freedom,
2.048 , 2.763 respectively for 5% and 1% significance
levels.
ONLY STUPID PEOPLE DOESN´T CHEK ITS BELIEFS.
__________
Luis Amaral Afonso
REM "EQsigm"
CLS : LOCATE 1, 60: PRINT " EQSIGM "
PRINT " H0 : m1=m2 **** X=N(0,1):nX ...
):nX ... Y=N(0,1):nY "
INPUT " nX= "; nX: DIM x(nX)
INPUT " nY= ", ny: DIM y(ny), w(8001)
INPUT " how many sample pairs "; vv
vc(1) = .95 * vv: vc(2) = .99 * vv
pi = 4 * ATN(1)
FOR v = 1 TO vv
LOCATE 5, 50
PRINT USING "###############"; vv - v
RANDOMIZE TIMER
sx = 0: ssx = 0: sy = 0: ssy = 0
FOR i = 1 TO nX: aa = SQR(-2 * LOG(RND))
x = aa * COS(2 * pi * RND)
sx = sx + x / nX: ssx = ssx + x * x
NEXT i
FOR i = 1 TO ny: aa = SQR(-2 * LOG(RND))
y = aa * COS(2 * pi * RND)
sy = sy + y / ny: ssy = ssy + y * y
NEXT i
vvx = (ssx - nX * sx * sx) / ((nX - 1) * nX)
vvy = (ssy - ny * sy * sy) / ((ny - 1) * ny)
su = SQR(vvx + vvy)
w = (sx - sy) / su
w = ABS(w): w = INT(1000 * w + .5)
IF w > 8000 THEN w = 8000
w(w) = w(w) + 1
NEXT v
FOR u = 1 TO 2
s = 0: g = vc(u)
FOR ii = 0 TO 8000
s = s + w(ii)
IF s > g THEN GOTO 10
NEXT ii
10 LOCATE 10 + u, 50
PRINT USING " ##.### #.##### "; ii / 1000;
/ 1000; s / v
NEXT u
END
The reason your MC answers come out wrong is that you used the wrong statistic. The correct statistic is
t = (Xbar-Ybar)/[s*((1/Nx)+(1/Ny))],
where
s = [Sum(Xi-Xbar)^2 + Sum(Yi-Ybar)^2]/(Nx+Ny-2).
Then under H, s^2 is proportional to a chi-square and t has Student's t distribution with Nx+Ny-2 degrees of freedom.
The square of your denominator is a linear combination of chi-squares, which is not a chi-square unless Nx=Ny. That's why your statistic does not have Student's t distribution.
Only those uneducated in statistics can make such an error.
Jack (moderator of the Math Forum)
.
- Follow-Ups:
- Re: ONLY STUPID PEOPLE DOESN´T CHEK ITS BELIEFS.
- From: Ken Butler
- Re: ONLY STUPID PEOPLE DOESN´T CHEK ITS BELIEFS.
- References:
- ONLY STUPID PEOPLE DOESN´T CHEK ITS BELIEFS.
- From: Luis A. Afonso
- ONLY STUPID PEOPLE DOESN´T CHEK ITS BELIEFS.
- Prev by Date: Re: How sweet is to remember1
- Next by Date: (WWW.CNCIRCLE.COM) cheap wholesale nike jordan, adidas,puma,lacoste ,gucci,parada,lv,bape,tupac.outlet shoe, and hoodies,jean, jacket, sunglass,handbags, watch, mp4.iphone
- Previous by thread: Re: ONLY STUPID PEOPLE DOESN´T CHEK ITS BELIEFS.
- Next by thread: Re: ONLY STUPID PEOPLE DOESN´T CHEK ITS BELIEFS.
- Index(es):
Relevant Pages
|
|