'/home/vburns/Dropbox/ConchisData/2013-03-30/f00293/f00293_2013-03-30-19-44-01.json', '/home/vburns/Dropbox/ConchisData/2013-03-30/f00294/f00294_2013-03-30-19-44-14.json' ] c_novel = aba.loadMultipleDataFiles(c_novel) #velocity analysis endWinLen = 5 * 60; #seconds sm = 15; #smooth over 15 frames. eEndVel5 = aba.getMedianVelMulti(e_shock5, tRange=[-endWinLen,-0], smoothWinLen=sm) eEndVel25 = aba.getMedianVelMulti(e_shock25, tRange=[-endWinLen,-0], smoothWinLen=sm) cEndVel = aba.getMedianVelMulti(c_shock, tRange=[-endWinLen,-0], smoothWinLen = sm) baseWinLen = 15*60 eBaseVel25 = aba.getVelMulti(e_shock25, tRange=(0,baseWinLen), smoothWinLen=sm) eBaseVel5 = aba.getVelMulti(e_shock5, tRange=(0,baseWinLen), smoothWinLen=sm) cBaseVel = aba.getVelMulti(c_shock, tRange=(0,baseWinLen), smoothWinLen=sm) eNovel25 = aba.getVelMulti(e_novel25, smoothWinLen=sm) eNovel5 = aba.getVelMulti(e_novel5, smoothWinLen=sm) cNovel = aba.getVelMulti(c_novel, smoothWinLen=sm) #same context [tv, e_statBase25] = scipy.stats.ttest_ind(eBaseVel25, cBaseVel) [tv, e_statBase5] = scipy.stats.ttest_ind(eBaseVel5, cBaseVel) [tv, e_statEnd25] = scipy.stats.ttest_ind(eEndVel25, cEndVel) [tv, e_statEnd5] = scipy.stats.ttest_ind(eEndVel5, cEndVel) [tv, e_statNovel25] = scipy.stats.ttest_ind(eNovel25, cNovel)
velocity = aba.getVelRaw(e_shockR[n], (e_mintimes[n], e_maxtimes[n])) eBaseVelEnd.append(np.median(velocity)) c_maxtimes = [] for n in range(len(c_shockR)): mtime = getmintime(c_shockR[n]) c_maxtimes.append(mtime) c_mintimes = [x - minutes for x in c_maxtimes] cBaseVelEnd = [] for n in range(len(c_shockR)): cvelocity = aba.getVelRaw(c_shockR[n], (c_mintimes[n], c_maxtimes[n])) cBaseVelEnd.append(np.median(cvelocity)) #velocity locomation analysis eBaseVelStart1 = aba.getVelMulti(e_shockR, (0,450)) eBaseVelStart2 = aba.getVelMulti(e_shockR, (450,900)) eBaseVel = aba.getVelMulti(e_shockR, (900,1800)) eBaseVel2 = aba.getVelMulti(e_shockR, (1800,2700)) #for eBaseVelEnd, see function to take exactly last 5 min #eSameTank = aba.getVelMulti(e_shockS) eSameTank = aba.getVelMulti(e_shockS, (0,900)) eSameTank2 = aba.getVelMulti(e_shockS, (900,1800)) eSameTank3 = aba.getVelMulti(e_shockS, (1800,2700)) eSameTank4 = aba.getVelMulti(e_shockS, (2700,3600)) #eNovelTank = aba.getVelMulti(e_shockN) eNovelTank = aba.getVelMulti(e_shockN, (0,900)) eNovelTank2 = aba.getVelMulti(e_shockN, (900,1800)) eNovelTank3 = aba.getVelMulti(e_shockN, (1800,2700)) eNovelTank4 = aba.getVelMulti(e_shockN, (2700,3600)) #eSameTank2 = aba.getVelMulti(e_shockS2)