= Tutorial 19: Clusters of sensors = ''Authors: Francois Tadel, Elizabeth Bock, Sylvain Baillet'' In EEG, a lot of the analysis can be done directly on the electrodes values. This tutorial explains how to group sensors in a cluster and overlay channels from different conditions in the same graph. In MEG, we tend to avoid working at the sensor level because the signals are ambiguous, we work mostly in the source space, which is the topic of the next tutorials. If you are planning to work only with MEG recordings, you may skip this tutorial. <> == Cluster tab == The Cluster tab is not shown by default in the Brainstorm interface. * Click on the '''[+]''' button next to the Scout tab > '''Add: Cluster'''.<
>If the list of tabs is too busy, you can close some of them in the same way. <
><
> {{attachment:cluster_tab.gif||height="85",width="277"}} * The Cluter panel is similar to the Scout tab, but much simpler. It contains a toolbar to create and edit clusters, a list of existing clusters and a few display options at the bottom.<
><
> {{attachment:cluster_panel.gif||height="200",width="224"}} * '''[NEW SEL]''': Create a cluster containing the channels that are currently selected in the interface. * '''[NEW IND]''': Create a cluster with channels selected by index, name or type. * '''[Display clusters time series]''': Shows the time series of the selected clusters for all the files that are currently open in the interface. * '''Edit''': Menus to modify the selected clusters. == Creating clusters == A cluster is a group of one or multiple channels. * Display the MEG recordings for the '''standard average''' or '''Run#01''' (double-click on the file).<
> Add a 2D topography view (Ctrl+T) and select a group of sensors (right-click+move). <
><
> {{attachment:cluster_select.gif||height="117",width="356"}} * In the Cluster tab, click on '''[NEW SEL]'''. It creates a new cluster "c1". <
>Double-click on it to rename it (or menu Edit > Rename). * In the Cluster tab, click on '''[NEW IND]'''. Enter the name of the sensor "MLT12". Rename it.<
><
> {{attachment:cluster_ind.gif||height="181",width="428"}} * '''Selection''': When you change the selected cluster in the list, it selects the corresponding sensors in all the figures. The number of channels involved in the selection is displayed at the bottom of the tab. You can select multiple clusters at once, holding the Ctrl/Shift/Command button while clicking. == Displaying clusters == We have now two clusters available in the list. The second one contains only one channel, displaying it corresponds to displaying the channel time series. The first one contains multiple channels, we need to apply a function to group them into one signal only. * The cluster function used to group multiple signals into one is shown on the right of the cluster list. By default it uses a simple average ("Mean"). * Click on the '''[Display clusters]''' button (third from the left in the toolbar). <
><
> {{attachment:cluster_view1.gif||height="149",width="434"}} * Select the two clusters at once and click on '''[''''''Display clusters]''' again. <
><
> {{attachment:cluster_view2.gif||height="140",width="344"}} * To see the two signals in the same graph, select the option '''"Overlay: Cluster"'''. Click on '''[Display]'''. <
><
> {{attachment:cluster_view3.gif||height="124",width="438"}} * In the database explorer: Double-click on the '''deviant average '''of the same run.<
>Click on '''[Display clusters]''' again, now it will display the cluster values for the deviant condition.<
><
> {{attachment:cluster_view4.gif||height="130",width="439"}} * Unselect '''"Overlay: Cluster"''' and select '''"Overlay: Conditions"''', it will group the signals in a different way: one graph per cluster. <
><
> {{attachment:cluster_view5.gif||height="129",width="438"}} == Cluster function == == From the database explorer == <)>> <> <>