Bug: problem averaging cortical maps

Hi Francois,

I just found out a weird Brainstorm behavior. Assume I have 10 conditions with 40 trials each. I can

  1. Average all 400 trials to produce a grand total trial
  2. Create 10 condition-specific averages, and then average them to create a grand total trial.

Both 1 and 2 should give the same result. However, when I plot the dspm maps, I get scaling inconsistencies and the results are different.

BST> Loading dspm maps: scaling the values by 3.16 to match the number of trials averaged (1 => 10)
BST> Loading dspm maps: scaling the values by 20 to match the number of trials averaged (1 => 400)

Best,
Dimitrios

Hi Dimitrios,

Use the “Weighted average” option and it should scale them correctly (the field nAvg is replaced by the sum of the nAvg of the input files, instead of the number of files).
Otherwise, average the dSPM maps instead of the recordings.

If you want to change this behavior, please discuss with Sylvain, John and Richard, and let me know what I should do.

Cheers,
Francois