Skip to content

Commit 2915825

Browse files
authored
Merge branch 'main' into slice
2 parents b878771 + 1ff190f commit 2915825

File tree

2 files changed

+60
-0
lines changed

2 files changed

+60
-0
lines changed

src/defaults/defaultResultsStructure.m

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,4 +23,35 @@
2323

2424
result.nidm = true();
2525

26+
% transparent plot
27+
layers{1} = struct('color', struct('file', result.montage.background, ...
28+
'range', [0 1], ...
29+
'map', gray(256)));
30+
31+
% color_map_folder = fullfile(fileparts(which('map_luminance')), '..', 'mat_maps');
32+
% load(fullfile(color_map_folder, 'diverging_bwr_iso.mat'));
33+
34+
layers{2} = struct('color', struct('file', [], ... % con image
35+
'map', 'diverging_bwr_iso', ...
36+
'range', [-4 4]), ...
37+
'label', '\beta_{listening} - \beta_{baseline} (a.u.)', ...
38+
'opacity', struct('file', [], ... % spmT image
39+
'range', [2 3], ...
40+
'label', '| t |'));
41+
42+
layers{3} = struct('color', struct('file', [], ... % spmT mask thresholded at 0.05 FWD
43+
'map', [0 0 0], ...
44+
'line_width', 2));
45+
46+
result.sdConfig.layers = layers;
47+
48+
settings = sd_config_settings('init');
49+
50+
settings.slice.orientation = result.montage.orientation;
51+
settings.slice.disp_slices = -50:10:50;
52+
settings.fig_specs.n.slice_column = 4;
53+
settings.fig_specs.title = [];
54+
55+
result.sdConfig.settings = settings;
56+
2657
end

tests/tests_defaults/test_defaultResultsStructure.m

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,35 @@ function test_defaultResultsStructure_basic()
3737

3838
expected.nidm = true();
3939

40+
layers{1} = struct('color', struct('file', expected.montage.background, ...
41+
'range', [0 1], ...
42+
'map', gray(256)));
43+
44+
layers{2} = struct('color', struct('file', [], ... % con image
45+
'map', 'diverging_bwr_iso', ...
46+
'range', [-4 4]), ...
47+
'label', '\beta_{listening} - \beta_{baseline} (a.u.)', ...
48+
'opacity', struct('file', [], ... % spmT image
49+
'range', [2 3], ...
50+
'label', '| t |'));
51+
52+
layers{3} = struct('color', struct('file', [], ... % spmT mask thresholded at 0.05 FWD
53+
'map', [0 0 0], ...
54+
'line_width', 2));
55+
56+
expected.sdConfig.layers = layers;
57+
58+
settings = sd_config_settings('init');
59+
60+
settings = sd_config_settings('init');
61+
62+
settings.slice.orientation = expected.montage.orientation;
63+
settings.slice.disp_slices = -50:10:50;
64+
settings.fig_specs.n.slice_column = 4;
65+
settings.fig_specs.title = [];
66+
67+
expected.sdConfig.settings = settings;
68+
4069
assertEqual(results, expected);
4170

4271
end

0 commit comments

Comments
 (0)