Skip to content
Simulation and analysis code for making global and local laminar inferences with MEG data.
MATLAB M Objective-C
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.gitignore
LICENSE
README.md
compare_classifier_accuracy.m
compare_surface_statistic_free_energy.m
compute_roi_t_stat.m
create_subject_structure.m
fadedblue_map.mat
fadedred_map.mat
get_wmpial_t.m
lead_field_comparison.m
plot_abs_signal_perc_correct.m
plot_abs_signal_perc_pial.m
plot_fading_line.m
plot_free_energy_patch_size_results.m
plot_metric_correlations.m
plot_patch_size_luzia.m
plot_real_noise_perc_correct.m
plot_real_noise_perc_pial.m
plot_roi_patch_size_results.m
plot_snr_perc_correct.m
plot_snr_perc_correct_ve.m
plot_snr_perc_pial.m
plot_snr_perc_pial_ve.m
plot_surface_statistic.m
plot_surface_statistic_free_energy.m
plot_wholebrain_roi_sim_results.m
preprocess_resting_data.m
simlayer_cross_val.m
simlayer_free_energy.m
simlayer_free_energy_absolute.m
simlayer_free_energy_patch_size.m
simlayer_free_energy_real_noise.m
simlayer_roi.m
simlayer_roi_absolute.m
simlayer_roi_patch_size.m
simlayer_roi_real_noise.m
split_inversion_results.m
ttest_corrected.m

README.md

MEG laminar simulations

Simulation and analysis code for making global and local laminar inferences with MEG data.

JJ Bonaiuto, HE Rossiter, SS Meyer, N Adams, S Little, MF Callaghan, F Dick, S Bestmann, GR Barnes
Non-invasive laminar inference with MEG: Comparison of methods and source inversion algorithms
NeuroImage 2017, http://www.sciencedirect.com/science/article/pii/S1053811917310145
(bioRxiv link: https://www.biorxiv.org/content/early/2017/11/30/147215)

Requirements

Usage

Running simulations

% Create subject structure

subjects=create_subject_structure();

% Run cross validation whole brain simulations

simlayer_cross_val(subjects(1), 1, [10 30], -20);

% Run free energy whole brain simulations

simlayer_free_energy(subjects(1), 1, [10 30], -20);

% Run ROI simulations

simlayer_roi(subjects(1), 1, [10 30], -20);

% Run free energy - patch size simulations

simlayer_free_energy_patch_size(subjects(1), 1, [10 30], -20);

% Run ROI - patch size simulations

simlayer_roi_patch_size(subjects(1), 1, [10 30], -20);

Analyzing results

% Plot whole brain and ROI stats for each simulation

plot_wholebrain_roi_sim_results(subjects(1),1,[10 30], -20);

% Plot metric correlations - EBB

plot_metric_correlations(subjects(1), 1, [10 30], -20, 1);

% Plot metric correlations - MSP

plot_metric_correlations(subjects(1), 1, [10 30], -20, 4);

% Plot SNR - % pial for whole brain ad ROI, EBB and MSP algorithms

plot_snr_perc_pial(subjects(1), 1, [10 30], [-100 -50 -20 -5 0 5])

% Plot SNR - % correct for whole brain and ROI, EBB and MSP algorithms

plot_snr_perc_correct(subjects(1), 1, [10 30], [-100 -50 -20 -5 0 5]);

% Compare classification accuracy of whole brain/ROI and EBB/MSP algorithms

compare_classifier_accuracy(subjects(1), 1, [10 30], -100);
compare_classifier_accuracy(subjects(1), 1, [10 30], -50);
compare_classifier_accuracy(subjects(1), 1, [10 30], -20);
compare_classifier_accuracy(subjects(1), 1, [10 30], -5);
compare_classifier_accuracy(subjects(1), 1, [10 30], 0);
compare_classifier_accuracy(subjects(1), 1, [10 30], 5);

% Plot whole brain analysis - patch size results

plot_free_energy_patch_size_results(subjects(1), 1, [10 30], [-100 -50 -20 -5 0 5]);

% Plot patch size results as in Troebinger (2014)

plot_patch_size_luzia(subjects(1), 1, [10 30], -20)

% Plot ROI analysis - patch size results

plot_roi_patch_size_results(subjects(1), 1, [10 30], [-100 -50 -20 -5 0 5]);

% Plot surface statistics - free energy relationship

plot_surface_statistic_free_energy('depth', subjects(1), 1, [10 30])
plot_surface_statistic_free_energy('curvature', subjects(1), 1, [10 30])
plot_surface_statistic_free_energy('thickness', subjects(1), 1, [10 30])
plot_surface_statistic_free_energy('lead_field_norm', subjects(1), 1, [10 30])

% Compare surface statistic - free energy correlations

compare_surface_statistic_free_energy(subjects(1), 1, [10 30]);

Support

Email jbonaiuto@gmail.com with any questions.

You can’t perform that action at this time.