Error during average volume source

Hi,

When I try to average 33 volume source in the condition (one subject), I get error message.

** Error: [process_average] Average > Average files
** Line 544: /
** Matrix dimensions must agree.
**
** Call stack:
** >bst_avg_files.m at 544
** >process_average.m>AverageFiles at 348
** >process_average.m>Run at 190
** >process_average.m at 29
** >bst_process.m>Run at 229
** >bst_process.m at 36
** >panel_process1.m>RunProcess at 151
** >panel_process1.m at 26
** >gui_brainstorm.m>CreateWindow/ProcessRun_Callback at 760
** >bst_call.m at 28
** >gui_brainstorm.m>@(h,ev)bst_call(@ProcessRun_Callback) at 293

I calculated these volume source in template grid for group analysis. (https://neuroimage.usc.edu/brainstorm/Tutorials/CoregisterSubjects#Volume_source_models)

I checked the 33 file contents are the same without the "comment".

One for example:
image

Thank you very much !

The problem comes from the fact that both the nAvg and Leff fields are empty, which should not happen with files generated with Brainstorm.
I added a test in the loading functions to set both values to 1 by default, which will solve your averaging problem: https://github.com/brainstorm-tools/brainstorm3/commit/6463c542080f38cf0f51f638e4efec3a2baddd31

Please update Brainstorm and try again.

Dear Francois

After update Brainstorm, it run well.

Thank you very much !!!