Example #1
0
def bigFig(m1, m2, compress='istac', clevel=.85):
    stim = gwn.getstim('bl')
    uc = ucse(stim)
    rcse = evalSystem(m1, True, cid=0)
    rcse2 = evalSystem(m2, True, cid=1)
    rc = eqrc((rcse, rcse2))
    iss = DRMODES[compress](rc, uc, clevel)
    report('Using %i components' % iss.shape[0])
    plt.figure(3)
    plt.clf()
    ll = lltest(rcse, rcse2)
    _prow(rcse, rcse2, 0, 3, True, ll)
    rc1 = np.dot(iss, rcse)
    rc2 = np.dot(iss, rcse2)
    ll = lltest(rc1, rc2)
    _prow(rc1, rc2, 1, 3, True, ll)
    rcb1 = np.dot(iss.transpose(), rc1)
    rcb2 = np.dot(iss.transpose(), rc2)
    #ll = lltest(rcb1, rcb2)
    _prow(rcb1, rcb2, 2, 3, True, ll)
    f = plt.figure(3)
    f.subplots_adjust(left=.04, right=.99, bottom=.05, top=.99, wspace=.05, hspace=.05)
    f.canvas.draw()
Example #2
0
def comp2s(stim1, evts1, stim2, evts2, length=LENGTH, lead=LEAD, compress='no', clevel=0, testprop=TESTPROP,
           bootstrap=BOOTSTRAP, report=None):
    '''
    Like compare, but considers the case where there are two stimuli in
    addition to two response sets
    '''
    rc1 = ece(stim1, evts1, length, lead)
    rc2 = ece(stim2, evts2, length, lead)
    if compress in DRMODES:
        uc = np.column_stack([ucse(stim1, 10000, length),
                              ucse(stim2, 10000, length)])
        ce = eqrc((rc1, rc2))
        cspace = DRMODES[compress](ce, uc, clevel)
        if report:
            report('Using %i components' % cspace.shape[0])
        rc1 = np.dot(cspace, rc1)
        rc2 = np.dot(cspace, rc2)
    return lltest(rc1, rc2, testprop, bootstrap)