Export Data to Brainstorm
From BESA® Wiki
Module information | |
Modules | BESA Research Standard or higher |
Version | BESA Research 6.1 or higher |
BESA Research can export EEG or MEG data to MATLAB in a structure data type named besa_channels
. The exported data structure can be also imported to Brainstorm for further analysis using the besa2brainstorm
MATLAB function included in the BESA MATLAB Readers.
Procedure
- Export EEG or MEG data to MATLAB in BESA Research using the Export data dialog (File → Send to MATLAB...).
- After finishing the data exporting process, type
desktop
in the MATLAB window to open the MATLAB desktop window. - Add the BESA MATLAB Readers and Brainstorm folders to the search path for MATLAB.
- Run Brainstorm and then create a Protocol and Subject. Protocols and subjects already created in Brainstorm can be also used instead of creating new ones.
- Import the
besa_channels
structure to Brainstorm using thebesa2brainstorm
function. For an example, refer to the MATLAB script below.
An example MATLAB script for importing the besa_channels
structure to Brainstorm:
% Add paths: BESA2MATLAB (BESA MATLAB Readers) and Brainstorm %addpath('xxx'); %addpath('xxx'); % Create a protocol and a subject in Brainstorm % ex) Protocol name: Protocol01; Subject name: Subject01 % Import the besa_channels structure to Brainstorm bstVar = []; bstVar.ProtocolName = 'Protocol01'; bstVar.SubjectName = 'Subject01'; bstVar.StudyName = 'test_S1_EpochedData'; besa2brainstorm(besa_channels, bstVar, true);