Changeset 3033


Ignore:
Timestamp:
Sep 20, 2010 6:50:14 PM (11 years ago)
Author:
jwatson
Message:

Fixed an off-by-one error in the computation of the gap variance estimator.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • coopr.pysp/trunk/scripts/computeconf

    r3032 r3033  
    2121
    2222# to avoid the pain of user lookup of parameter in t-tables, we provide decent coverage automatically.
    23 # feel free to add more values!!!!
     23# feel free to add more values!!!! maps degrees-of-freedom to (alpha,t-statistic) pairs.
    2424
    2525t_table_values = {
     
    294294   # second pass for variance calculation (because we like storing the g_supk)
    295295   g_var = 0
    296    for k in range(0, n_g-1):
     296   for k in range(0, n_g):
    297297      g_var = g_var + (g_supk_of_xhat[k] - g_bar) * (g_supk_of_xhat[k] - g_bar)
    298298   g_var = g_var / (n_g - 1)    # sample var
Note: See TracChangeset for help on using the changeset viewer.