ihgumilar / Hyperscanning2-redesign

Experiment of hyperscanning2-redesign is adding questionnaire inside VR and also improved the UNITY that is used for the experiment.
1 stars 1 forks source link

Combine pre-training files as well as post-training files of EEG data #21

Closed ihgumilar closed 2 years ago

ihgumilar commented 2 years ago

Right now it is in separate files

ihgumilar commented 2 years ago

use combine_fif_files.py Please refer to this

ihgumilar commented 2 years ago

c7f409b combine pre-averted data. There is something wrong in combining data for odd and even subject.

ihgumilar commented 2 years ago

eefc499 Fixed combining pre-averted files (fixing the above comment) and Add script to combine post averted files

ihgumilar commented 2 years ago

ccbdfde86736a869b205665900115152dd23e514 Combine all raw data (jupyter notebook)

 * Combine all baseline data : It has only pre & post averted.
 * Combine all experimental data : pre & post for all eye conditions (averted, direct, & natural).
 * Fix S0 to S for subject number which is bigger than 9, eg. S10 instead of S010.
 * ToDo :      
       - [ ]  Change the number of looping to the total number of files, currently is 16.     
       - [ ]  Change to 30 later on (if there are 15 pairs)
ihgumilar commented 2 years ago

d97426c1e4378fd943dbf7a17b23f375155997b2 needs to be fixed :

ihgumilar commented 2 years ago

a021d21 Change from hard coded to soft coded

ihgumilar commented 2 years ago

It seems there is something wrong in combining averted_pre (no.11) and averted_post (no.12)

Do this. Check other conditions

# Equalise epoch
mne.epochs.equalize_epoch_counts([epo1_averted, epo2_averted])

# Combined epoch
combined_epoch = mne.concatenate_epochs([epo1_averted, epo2_averted])

The issue seems with the way we save..after concatenating epoched data, it should be saved this way -epo.fifor -epo.fif.gz

ihgumilar commented 2 years ago

There is something wrong with the looping. Just use the old script from hyperscanning2 under EEG-pre-processing branch there is **combine_files_fif.py** Just use that file and use the looping in it. Looping with step 2

Forget about **combine_files_fif.ipynb** and delete later

ihgumilar commented 2 years ago

b8f675e Fixed combine each pre & post data

ihgumilar commented 2 years ago

a923304 Added coded to combine baseline data

18136a51a8845a076b3bc573f7f28063183bdf49 in main branch

(NOTE) For processing all data, please change the end variable. So far, it is only dedicated for processing 16 files

ihgumilar commented 2 years ago

497cdf763835c09c2ca9b805e88343ab488e0e52 Fixed file order and naming even subjects in (EEG-pre-processing branch)

9aa1e7a the same file but in main branch

ihgumilar commented 2 years ago

6848b536e7d79ddc2a99b0eff795e20f86fd1790 use this that counts 26 files of csv

ihgumilar commented 2 years ago

432da5e use this, it will automatically read the number of raw csv files. It is soft coded instead of hard coded as you can see the above code