Sample means in the Planet X

Discussion in 'Scientific Statistics Math' started by Luis A. Afonso, Dec 3, 2010.

  1. Sample means in the Planet X

    Since one is able to simulate the Universe it’s a straightforward duty to obtain a Critical Values of a Test Statistics of samples draw from it. This fact, at least 50 years old (see Lilliefors Test, 1968) is not known by Jack Tomsky yet. I several times, since 2007, ask him to reformulate his ideas about the Monte Carlo Method but had not got any feedback.
    A simple exercise concerning X~N(0,1): 10 samples and the statistics t = sqrt(n) * (xhat - 0)/ s involving the sample mean and its standard deviation is quite explicit.

    The quantiles of t were (1 million samples):
    _____0.60___0.260____Tables____0.261
    _____0.75___0.703_____________ 0.703
    _____0.90___1.383_____________ 1.383
    _____0.95___1.832_____________ 1.833
    _____0.975__2.258_____________ 2.262
    _____0.99___2.827_____________ 2.821

    It’s conceivable that in a planet where Gasset/Student had never landed, their inhabitants, though sufficiently experts in Microelectronics, could fully be able to find out confident intervals for normal sample means.

    Luis



    REM "MATE"
    CLS
    PRINT
    PRINT " T=sqr(n)*(Xhat-0)/s fractiles samples N(0,1) "
    pi = 4 * ATN(1)
    INPUT " all = "; all
    DIM w(8001)
    LOCATE 8, 1
    PRINT " 0.600 0.750 0.900 0.950 ";
    PRINT " 0.975 0.990 "
    FOR n = 5 TO 20
    PRINT : COLOR 14
    FOR j = 0 TO 8001: w(j) = 0: NEXT j
    FOR j = 1 TO all
    LOCATE 5, 50
    PRINT USING "##########"; all - j
    RANDOMIZE TIMER
    m = 0: xx = 0
    FOR i = 1 TO n
    aa = SQR(-2 * LOG(RND))
    x = 1 * aa * COS(2 * pi * RND)
    m = m + x / n: xx = xx + x * x
    NEXT i
    v = xx - n * m * m: v = v / (n - 1)
    t = m / (SQR(v) / SQR(n))
    IF t < -4 THEN t = -4
    IF t > 4 THEN t = 4
    t = t + 4
    t = INT(1000 * t + .5)
    w(t) = w(t) + 1 / all
    NEXT j: PRINT : PRINT : PRINT
    LOCATE 5 + n, 1
    PRINT USING "###"; n;
    v(1) = .6: v(2) = .75: v(3) = .9: v(4) = .95
    v(5) = .975: v(6) = .99
    FOR vv = 1 TO 6: s = 0
    FOR tt = 0 TO 8000
    s = s + w(tt)
    IF s > v(vv) THEN GOTO 10
    NEXT tt
    10 PRINT USING " ##.### "; tt / 1000 - 4;
    NEXT vv
    NEXT n
    END
     
    Luis A. Afonso, Dec 3, 2010
    #1
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.