Difference between revisions of "User Tutorial:Obtaining Mu Rhythm Parameters in an Initial Session"

From BCI2000 Wiki
Jump to: navigation, search
(Typo)
 
(42 intermediate revisions by 4 users not shown)
Line 2: Line 2:
  
 
==Experimental Design==
 
==Experimental Design==
In this initial session, the subject is instructed to imagine hand and/or foot movements in response to visual cues.
+
In this initial session, the subject is instructed to incorporate hand and/or foot movements in response to visual cues.
To identify a subject's Mu Rhythm, offline analyses then determine the frequency and location whose activity changes the most across conditions (e.g., hand imagery and rest). These analyses result in spectra calculated at different locations or in topographical plots at particular frequencies.  
+
To identify a subject's Mu Rhythm, offline analyses then determine the frequency and location whose activity changes the most across conditions (e.g., hand movement and rest). These analyses result in spectra calculated at different locations or in topographical plots at particular frequencies. For the purpose of conceptual demonstration, the tutorial will mainly focus on one dimension control (up and down of a cursor) using hand movements. Once familiarized, one can then engage foot movements for more tasks.
  
 
==Preparing for the Initial (Screening) Session==
 
==Preparing for the Initial (Screening) Session==
To begin, you first need to gather some system data. For setup, this tutorial will assume that you will be using a dual-monitor setup as shown below, with the administrator of the sessions operating on monitor 1, and the volunteer will be watching monitor 2.  
+
To begin, you first need to gather some system data. This tutorial will assume that you will be using a dual-monitor setup as shown below, with the experimenter of the sessions operating on monitor 1, and the subject will be watching monitor 2.  
  
 
Open Display Properties by right-clicking on an empty portion of the desktop and clicking '''Properties''', and navigating to the '''Settings''' tab.
 
Open Display Properties by right-clicking on an empty portion of the desktop and clicking '''Properties''', and navigating to the '''Settings''' tab.
  
 
{|
 
{|
|colspan="2" align="center"|[[Image:MonitorSetupOrientation.PNG|center]]
+
|colspan="2" align="center"|[[Image:MonitorSetupOrientation.PNG|center|400px]]
 
|-
 
|-
 
|colspan="2" align="center"|Make sure that Monitor 2, (which displays the instructions to the subject), is on the right of Monitor 1, (the experimenter's screen), and is aligned along the top.
 
|colspan="2" align="center"|Make sure that Monitor 2, (which displays the instructions to the subject), is on the right of Monitor 1, (the experimenter's screen), and is aligned along the top.
Line 17: Line 17:
 
|colspan="2" align="center" height=50px|
 
|colspan="2" align="center" height=50px|
 
|-
 
|-
|align="center"|[[Image:MonitorSetupPrimaryRes.PNG|center]]
+
|align="center"|[[Image:MonitorSetupPrimaryRes.PNG|center|400px]]
|[[Image:MonitorSetupSecondaryRes.PNG|center]]
+
|[[Image:MonitorSetupSecondaryRes.PNG|center|400px]]
 
|-
 
|-
 
|colspan="2" align="center"|What we need to make a note of is the '''width''' of monitor 1, and the '''width and height''' of monitor 2.
 
|colspan="2" align="center"|What we need to make a note of is the '''width''' of monitor 1, and the '''width and height''' of monitor 2.
 
|-
 
|-
|colspan="2" align="center"|In this example we see that Monitor 1 is 2048 pixels wide, and monitor 2 is 1024 pixels wide by 768 pixels tall.
+
|colspan="2" align="center"|In this example we see that Monitor 1 is 1920 pixels wide, and monitor 2 is 1600 pixels wide by 900 pixels tall.
 
|-
 
|-
 
|colspan="2" align="center" height=50px|
 
|colspan="2" align="center" height=50px|
 
|}
 
|}
  
Plug your adapter into the computer and turn it on.
+
Connect your amplifier to the computer, and turn it on.
  
Now we will determine what port your amplifier is connected to by going through '''Start → Settings → Control Panel → System → Hardware → Device Manager → Ports (COM & LPT)'''. In this example, we see that the amplifier is connected to ''COM8''.
+
If your amplifier is from the gUSBamp family, drivers can be downloaded from official website of gtec. In this example we are using a gUSBamp-8 amplifier.
 +
 
 +
If your amplifier is from the gMOBIlab family, you will need to make a note of the port it is connected to. In order to determine that port, in Windows XP, go to the Windows Start Menu, and choose '''Start → Control Panel → System → Hardware → Device Manager → Ports (COM & LPT)'''. Different versions of Windows may have the Device Manager in a different location.  
  
 
<gallery caption="Finding the COM port" widths="300px" heights="300px" perrow="4">
 
<gallery caption="Finding the COM port" widths="300px" heights="300px" perrow="4">
Line 37: Line 39:
 
Image:COMCircled.PNG|Identifying the COM Port
 
Image:COMCircled.PNG|Identifying the COM Port
 
</gallery>
 
</gallery>
 +
You can now close all open windows.
  
 +
==Configuring BCI2000==
  
*Start BCI2000 by double-clicking <tt>batch/StimulusPresentation_screening_<YourAmplifier>.bat</tt>.
+
*When you are using a source module that is not part of the BCI2000 core distribution, you will need to create a batch file and parameter file for your amplifier first. Please follow the steps described [[Contributions:How_to_use_a_Contributed_Source_Module#Creating_batch_files|on this page]].
 +
*Start BCI2000 by double-clicking <tt>batch/StimulusPresentation_<YourAmplifier>.bat</tt>.
 
**For repeated use, placing a link to this file on the desktop might be a good idea.
 
**For repeated use, placing a link to this file on the desktop might be a good idea.
 
*In the operator module, click '''Config'''.
 
*In the operator module, click '''Config'''.
*Click '''Load Parameters''', and load <tt>parameters/fragments/parms/fragment_<YourAmplifier>.prm</tt> and <tt>parameters/fragments/parms/Mu_screening.prm</tt>
+
*Click '''Load Parameters''', and load <tt>parms/examples/SMR_screening_left_vs_right.prm</tt>. Then, load <tt>parms/fragments/amplifiers/<YourAmplifier>.prm</tt>.
 
*In the '''Storage''' tab:
 
*In the '''Storage''' tab:
**Set ''SubjectName'' to the volunteer’s initials.
+
**Set ''SubjectName'' to the subject’s initials.
 
**Set ''SubjectSession'' to <tt>001</tt>
 
**Set ''SubjectSession'' to <tt>001</tt>
 
**Set ''SubjectRun'' to <tt>01</tt>
 
**Set ''SubjectRun'' to <tt>01</tt>
**Please note that the data will be stored into a directory dedicated to the screening data.
 
  
[[Image:SourceTabCircledMu.PNG|right|500px]]
+
[[Image:WindowSize.PNG|right|500px]]
  
 
In the '''Source''' tab, set:
 
In the '''Source''' tab, set:
*''SourceCh'' to <tt>8</tt>
+
*''ChannelNames'' to the electrode positions according to the 10-20 convention.
**This tells the program that only 8 channels will be sending data
+
**This names the channels according to their respective electrode positions.
*''ChannelNames'' to <tt>F3 F4 T7 C3 Cz C4 T8 Pz</tt>
+
**In our example, <tt>F3 F4 T7 C3 Cz C4 T8 Pz</tt> has been entered.
**This names the channels to the electrode positions they report
+
*''TransmitChList'' to the channel names entered into the ''ChannelNames'' parameter
*''SourceChOffset'' to <tt>0 0 0 0 0 0 0 0</tt>
+
*If using a gMOBIlab amplifier, set ''COM port'' to the port name that you found earlier.
**This tells the program that none of the channels have an offset
+
 
*''SourceChGain'' to <tt>0.019 0.019 0.019 0.019 0.019 0.019 0.019 0.019</tt>
 
**This is the conversion for each channel for A/D information into microvolts
 
*''COM port'' to the port name that you found earlier
 
**In this example we would put in <tt>COM8:</tt>
 
*''NotchFilter'' to <tt>disable</tt>
 
**We will use this to identify any poorly-gelled electrodes
 
*''AlignChannels'' to <tt>0</tt>
 
**This makes sure that the electrodes, which gather data simultaneously, will be treated as such.
 
*''TransmitChList'' to <tt>F3 F4 T7 C3 Cz C4 T8 Pz</tt>
 
  
 
{|
 
{|
Line 73: Line 68:
  
 
In the '''Application''' tab, set:
 
In the '''Application''' tab, set:
*''WindowWidth'' to the width of the display monitor, found earlier
+
*''WindowWidth'' to the width of the display monitor, found earlier.
*''WindowHeight'' to the height of the display monitor, found earlier
+
*''WindowHeight'' to the height of the display monitor, found earlier.
**In our example, ''WindowWidth'' would be set to <tt>1024</tt> and ''WindowHeight'' would be set to <tt>768</tt>
+
**In our example, ''WindowWidth'' would be set to <tt>1600</tt> and ''WindowHeight'' would be set to <tt>900</tt>.
*''WindowLeft'' to the width of the experimenter’s monitor plus one
+
*''WindowLeft'' to the width of the experimenter’s monitor.
**In our example, this would be <tt>2049</tt>
+
**In our example, this would be <tt>1920</tt>.
**This shifts the character display to the right 2049 pixels, making it display on the secondary monitor
+
**This shifts the character display to the right 1920 pixels, making it display on the secondary monitor.
 
*Take note of the ''Sequence'' field:
 
*Take note of the ''Sequence'' field:
**This field calls for four single-digit numbers separated by one space. Initially it will be <tt>1 1 1 1</tt>.
+
**This field contains four single-digit numbers separated by one space. Initially it will be <tt>1 1 0 0</tt>.
**These numbers are the relative frequency of calling for the different subject activity. The first number corresponds to the left hand, the second is the right hand, the third for both hands, the fourth for both feet.
+
**These numbers are frequencies of calling for the different subject activity. The first number corresponds to the left hand, the second is the right hand, the third for both hands, the fourth for both feet (details can be inspected under ''Stimuli'' &rarr; '''Edit''').  
**Therefore, setting this field to <tt>2 1 0 1</tt> will call for the subject to move the left hand twice as often as the right or both feet, and will never call for both hands to be moved.
+
**Therefore, setting this field to <tt>2 1 0 1</tt> will call for the subject to move the left hand twice as often as the right or both feet, and will never call for both hands to be moved. In our example, <tt>1 1 0 0</tt> (equally distributed left and right hand) is recommended as a initial session.
 +
*Finally, save the parameter file where you deem appropriate.
 
*Click '''Set Config'''.
 
*Click '''Set Config'''.
 
*Instruct the subject as described in the section below.
 
*Instruct the subject as described in the section below.
 +
 +
[[Image:Stimuli.PNG|right|700px]]
 +
 +
{|
 +
|height="400px"|
 +
|}
  
 
==Instructions to the Subject==
 
==Instructions to the Subject==
During the initial session, the subject's screen will either be blank, or displaying an arrow pointing up, down, left or right.
+
During the initial session, the subject's screen will either be blank, or displaying a command of left or right.
*When a left or right arrow is displayed, imagine movement of the respective hand. The imagined movement should be continuous opening and closing of the hand (e.g., squeezing a tennis ball) at a rate of about one opening/closing per second.
+
*When a left or right command is displayed, engage movement of the respective hand. It is recommended that the movement be continuous opening and closing of the hand (e.g., squeezing a tennis ball) at a rate of about one opening/closing per second.
*When an up arrow is displayed, imagine simultaneous movement of both hands. This should be the same kind of movement as described for a single hand.
+
For future sessions with hands and feet involved,the subject's screen will either be blank, or displaying an arrow pointing up, down, left, or right.
*When a down arrow is displayed, imagine movements of both feet. The movement should be similar to the one described for hands, i.e., imagine opening and closing your feet as if you could use them to grip an object.
+
*When an up arrow is displayed, engage simultaneous movement of both hands. This should be the same kind of movement as described for a single hand.
*When you see a blank screen, please relax and stop any movement imagery.
+
*When a down arrow is displayed, engage movements of both feet. The movement should be similar to the one described for hands, i.e., opening and closing your feet as if you could use them to grip an object.
 +
*When you see a blank screen, please relax and stop any movement. This is crucial as it takes time for mu rhythm to settle and ready for the next peak.
  
 
==Performing the Initial Session==
 
==Performing the Initial Session==
Each run gathers 20 data points that differentiate between moving the left hand, the right hand, both hands, and both feet. Ideally, there should be 100 points of data, meaning that five runs are suggested. This is done as five separate runs instead of one to allow the subject a chance between each run to rest, blink, swallow, speak, or have some water if so desired.
+
To start an experimental run, click '''Run''' in the operator window. Each run takes five minutes and gathers 25 data points, or "trials", that differentiate between moving the left hand and the right hand. Ideally, there should be 100 trials, meaning that four runs are suggested. This is done as four separate runs instead of one to allow the subject a chance between each run to rest, blink, swallow, speak, or have some water if so desired.
 +
 
 +
[[Image:InitialSession.PNG|center|400px]]
  
 
==Next Step==
 
==Next Step==
Once all data points have been collected, the [[User Tutorial:Analyzing the Initial Mu Rhythm Session|Analyzing the Initial Mu Rhythm Session]] page shows you how to analyze data from the initial session in order to determine parameters for online feedback.
+
Once all data have been collected, the [[User Tutorial:Analyzing the Initial Mu Rhythm Session|Analyzing the Initial Mu Rhythm Session]] page shows you how to analyze data from the initial session in order to determine parameters for online feedback.
  
 
==See also==
 
==See also==

Latest revision as of 15:36, 27 February 2020

Although the basic properties of the Mu rhythm are identical for all humans, spatial patterns and exact frequencies are different across people. Thus, it is necessary to obtain these individual parameters prior to any feedback experiments, i.e., to calibrate the BCI system using data acquired from an initial session.

Experimental Design

In this initial session, the subject is instructed to incorporate hand and/or foot movements in response to visual cues. To identify a subject's Mu Rhythm, offline analyses then determine the frequency and location whose activity changes the most across conditions (e.g., hand movement and rest). These analyses result in spectra calculated at different locations or in topographical plots at particular frequencies. For the purpose of conceptual demonstration, the tutorial will mainly focus on one dimension control (up and down of a cursor) using hand movements. Once familiarized, one can then engage foot movements for more tasks.

Preparing for the Initial (Screening) Session

To begin, you first need to gather some system data. This tutorial will assume that you will be using a dual-monitor setup as shown below, with the experimenter of the sessions operating on monitor 1, and the subject will be watching monitor 2.

Open Display Properties by right-clicking on an empty portion of the desktop and clicking Properties, and navigating to the Settings tab.

MonitorSetupOrientation.PNG
Make sure that Monitor 2, (which displays the instructions to the subject), is on the right of Monitor 1, (the experimenter's screen), and is aligned along the top.
MonitorSetupPrimaryRes.PNG
MonitorSetupSecondaryRes.PNG
What we need to make a note of is the width of monitor 1, and the width and height of monitor 2.
In this example we see that Monitor 1 is 1920 pixels wide, and monitor 2 is 1600 pixels wide by 900 pixels tall.

Connect your amplifier to the computer, and turn it on.

If your amplifier is from the gUSBamp family, drivers can be downloaded from official website of gtec. In this example we are using a gUSBamp-8 amplifier.

If your amplifier is from the gMOBIlab family, you will need to make a note of the port it is connected to. In order to determine that port, in Windows XP, go to the Windows Start Menu, and choose Start → Control Panel → System → Hardware → Device Manager → Ports (COM & LPT). Different versions of Windows may have the Device Manager in a different location.

You can now close all open windows.

Configuring BCI2000

  • When you are using a source module that is not part of the BCI2000 core distribution, you will need to create a batch file and parameter file for your amplifier first. Please follow the steps described on this page.
  • Start BCI2000 by double-clicking batch/StimulusPresentation_<YourAmplifier>.bat.
    • For repeated use, placing a link to this file on the desktop might be a good idea.
  • In the operator module, click Config.
  • Click Load Parameters, and load parms/examples/SMR_screening_left_vs_right.prm. Then, load parms/fragments/amplifiers/<YourAmplifier>.prm.
  • In the Storage tab:
    • Set SubjectName to the subject’s initials.
    • Set SubjectSession to 001
    • Set SubjectRun to 01
WindowSize.PNG

In the Source tab, set:

  • ChannelNames to the electrode positions according to the 10-20 convention.
    • This names the channels according to their respective electrode positions.
    • In our example, F3 F4 T7 C3 Cz C4 T8 Pz has been entered.
  • TransmitChList to the channel names entered into the ChannelNames parameter
  • If using a gMOBIlab amplifier, set COM port to the port name that you found earlier.


In the Application tab, set:

  • WindowWidth to the width of the display monitor, found earlier.
  • WindowHeight to the height of the display monitor, found earlier.
    • In our example, WindowWidth would be set to 1600 and WindowHeight would be set to 900.
  • WindowLeft to the width of the experimenter’s monitor.
    • In our example, this would be 1920.
    • This shifts the character display to the right 1920 pixels, making it display on the secondary monitor.
  • Take note of the Sequence field:
    • This field contains four single-digit numbers separated by one space. Initially it will be 1 1 0 0.
    • These numbers are frequencies of calling for the different subject activity. The first number corresponds to the left hand, the second is the right hand, the third for both hands, the fourth for both feet (details can be inspected under StimuliEdit).
    • Therefore, setting this field to 2 1 0 1 will call for the subject to move the left hand twice as often as the right or both feet, and will never call for both hands to be moved. In our example, 1 1 0 0 (equally distributed left and right hand) is recommended as a initial session.
  • Finally, save the parameter file where you deem appropriate.
  • Click Set Config.
  • Instruct the subject as described in the section below.
Stimuli.PNG

Instructions to the Subject

During the initial session, the subject's screen will either be blank, or displaying a command of left or right.

  • When a left or right command is displayed, engage movement of the respective hand. It is recommended that the movement be continuous opening and closing of the hand (e.g., squeezing a tennis ball) at a rate of about one opening/closing per second.

For future sessions with hands and feet involved,the subject's screen will either be blank, or displaying an arrow pointing up, down, left, or right.

  • When an up arrow is displayed, engage simultaneous movement of both hands. This should be the same kind of movement as described for a single hand.
  • When a down arrow is displayed, engage movements of both feet. The movement should be similar to the one described for hands, i.e., opening and closing your feet as if you could use them to grip an object.
  • When you see a blank screen, please relax and stop any movement. This is crucial as it takes time for mu rhythm to settle and ready for the next peak.

Performing the Initial Session

To start an experimental run, click Run in the operator window. Each run takes five minutes and gathers 25 data points, or "trials", that differentiate between moving the left hand and the right hand. Ideally, there should be 100 trials, meaning that four runs are suggested. This is done as four separate runs instead of one to allow the subject a chance between each run to rest, blink, swallow, speak, or have some water if so desired.

InitialSession.PNG

Next Step

Once all data have been collected, the Analyzing the Initial Mu Rhythm Session page shows you how to analyze data from the initial session in order to determine parameters for online feedback.

See also

User Tutorial:Mu Rhythm BCI Tutorial