Example #1
0
#Debugging
import ipdb

import matplotlib.pyplot as plt
plt.rcParams['image.cmap'] = 'tab10'
plt.close('all')

## MAJOR PARAMETERS for our partial biometric analysis
do_pts = ['901', '903', '905', '906', '907', '908'
          ]  # Which patients do we want to include in this entire analysis?
test_scale = 'pHDRS17'  # Which scale are we using as the measurement of the depression state? pHDRS17 = nHDRS (from paper) and is a patient-specific normalized HDRS

# Initial
# Now we set up our DBSpace environment
#ClinFrame = ClinVect.CFrame(norm_scales=True)
ClinFrame = ClinVect.CStruct()
#BRFrame = BRDF.BR_Data_Tree(preFrame='Chronic_Frame.pickle')

null_distribution = []
for ii in range(100):
    #%%
    BRFrame = pickle.load(
        open('/home/virati/Dropbox/Data/Chronic_FrameMay2020.pickle', "rb"))
    main_readout = decoder.weekly_decoderCV(
        BRFrame=BRFrame,
        ClinFrame=ClinFrame,
        pts=do_pts,
        clin_measure=test_scale,
        algo='ENR',
        alpha=-4,
        shuffle_null=True)  #main analysis is -3.4
Example #2
0
import pickle
# General python libraries
import scipy.signal as sig
import numpy as np

# Plotting Libraries
import matplotlib.pyplot as plt
import seaborn as sns
#Do some cleanup of the plotting space
plt.close('all')
sns.set_context('paper')
sns.set_style('white')
sns.set(font_scale=4)

# Misc libraries
import copy
import itertools
import scipy.stats as stats

import ipdb

#%% Initial
# Now we set up our DBSpace environment
ClinFrame = ClinVect.CFrame(norm_scales=True)
#BRFrame = BRDF.BR_Data_Tree(preFrame='Chronic_Frame_2019.pickle')
BRFrame = pickle.load(
    open('/home/virati/Dropbox/Data/Chronic_Frame_2019.pickle', "rb"))

readout = DSV.DMD_RO(BRFrame, ClinFrame)
readout.default_run()