... | @@ -5,14 +5,14 @@ Throughout the pipeline the scripts make many decisions that result in marks on |
... | @@ -5,14 +5,14 @@ Throughout the pipeline the scripts make many decisions that result in marks on |
|
|
|
|
|
To visualise some of the choices that were made in the pipeline either create your own plotting functions, or try running the diagnotics script.
|
|
To visualise some of the choices that were made in the pipeline either create your own plotting functions, or try running the diagnotics script.
|
|
|
|
|
|
# Using the Diagnostics Script
|
|
**Using the Diagnostics Script**
|
|
Open up a EEG dataset that has complete the dipfit stage of the pipeline to get all of the available figures. Most typically these will have the ending *_dip.set.* Make sure that the diagnostics.m file is on the MATLAB path. In the matlab editor call the diagnostics function in the MATLAB editor:
|
|
Open up a EEG dataset that has complete the dipfit stage of the pipeline to get all of the available figures. Most typically these will have the ending *_dip.set.* Make sure that the diagnostics.m file is on the MATLAB path. In the matlab editor call the diagnostics function in the MATLAB editor:
|
|
```
|
|
```
|
|
diagnostics
|
|
diagnostics
|
|
```
|
|
```
|
|
By typing the function name you are calling the diagnostics script. This function does not contain any input values but directly starts accessing your loaded dataset. Figures will be generated and you can browse them as you would like. The figures contain some visual representations of the calculations that are being preformed based on the quality of the data file. Follow along below for a more in depth view of some of the figures.
|
|
By typing the function name you are calling the diagnostics script. This function does not contain any input values but directly starts accessing your loaded dataset. Figures will be generated and you can browse them as you would like. The figures contain some visual representations of the calculations that are being preformed based on the quality of the data file. Follow along below for a more in depth view of some of the figures.
|
|
|
|
|
|
**Data Quality**
|
|
# Data Quality
|
|
The first plot is a general overview of how much good data has been found in your data set. If the % of time and the % of channels of your data is very high you might want to reconsider your experiment modality. From the figure below:
|
|
The first plot is a general overview of how much good data has been found in your data set. If the % of time and the % of channels of your data is very high you might want to reconsider your experiment modality. From the figure below:
|
|
|
|
|
|

|
|

|
... | @@ -27,7 +27,7 @@ The designation of *Bad* is based off a few simple calculations which parameters |
... | @@ -27,7 +27,7 @@ The designation of *Bad* is based off a few simple calculations which parameters |
|
|
|
|
|
*As a side Note is is possible but not likely for a channel to be flagged for more than one of these classifications. This would mean diagnostics will find high numbers of bad channels but a lower number of removals. Make sure you look at the printout in the editor.*
|
|
*As a side Note is is possible but not likely for a channel to be flagged for more than one of these classifications. This would mean diagnostics will find high numbers of bad channels but a lower number of removals. Make sure you look at the printout in the editor.*
|
|
|
|
|
|
**Channel Flags**
|
|
# Channel Flags
|
|
Channel flags are the way that channels are identified and staged for removal. A few examples of channel flag calculations are:
|
|
Channel flags are the way that channels are identified and staged for removal. A few examples of channel flag calculations are:
|
|
* Standard Deviation (Comicaly Bad)
|
|
* Standard Deviation (Comicaly Bad)
|
|
* High correlation (Bridging)
|
|
* High correlation (Bridging)
|
... | @@ -45,9 +45,9 @@ This plot expands on the values from the first sub figure. In this plot only the |
... | @@ -45,9 +45,9 @@ This plot expands on the values from the first sub figure. In this plot only the |
|
* ```[sd_chan_z] ``` for standard deviation. Default is 2.326 deviation, a higher number will produce less marks, lower will flag more.
|
|
* ```[sd_chan_z] ``` for standard deviation. Default is 2.326 deviation, a higher number will produce less marks, lower will flag more.
|
|
* ```[r_chan_z]``` for correlations. Default is 2.326, a higher number will produce less marks, lower will flag more.
|
|
* ```[r_chan_z]``` for correlations. Default is 2.326, a higher number will produce less marks, lower will flag more.
|
|
* Sub Figure 3
|
|
* Sub Figure 3
|
|
The third plot uses the results from the second plot. It adds up the marks for each of the channels and finds the % of teach channel that was flagged. Looking at the example below the red segment had a high deviation, and produced a high % of the channel being covered in flags. This causes the waveform on the right to peak at this channel. This peak crosses the threshold vertical line, meaning the channel has to much time in which it is comically bad. The criteria line can be adjusted left and right to allow for more or less acceptable deviation. You can adjust the criteria of the flagging by adjusting variables like:
|
|
The third plot uses the results from the second plot. It adds up the marks for each of the channels and finds the % of each channel that was flagged. Looking at the example below the red segment had a high deviation, and produced a high % of the channel being covered in flags. This causes the waveform on the right to peak at this channel. This peak crosses the threshold vertical line, meaning the channel has to much time in which it is comically bad. The criteria line can be adjusted left and right to allow for more or less acceptable deviation. You can adjust the criteria of the flagging by adjusting variables like:
|
|
* ```[sd_chan_p] ``` for standard deviation. Default is 0.1(10%) of the channel flagged with the ```[sd_chan_z] ``` mark, a higher number will make the % required larger and thus less channels will be flagged.
|
|
* ```[sd_chan_p] ``` for standard deviation. Default is 0.1(10%) of the channel has to be flagged with the ```[sd_chan_z] ``` mark, a higher number will make the % required larger and thus less channels will be flagged.
|
|
* ```[r_chan_p]``` for correlations. Default is 0.1(10%)of the channel flagged with the ```[r_chan_z] ``` mark, a higher number will make the % required larger and thus less channels will be flagged.
|
|
* ```[r_chan_p]``` for correlations. Default is 0.1(10%)of the channel has to be flagged with the ```[r_chan_z] ``` mark, a higher number will make the % required larger and thus less channels will be flagged.
|
|
|
|
|
|
***
|
|
***
|
|
|
|
|
... | @@ -68,12 +68,28 @@ This would increase the criteria for making the flags, and increase the amount t |
... | @@ -68,12 +68,28 @@ This would increase the criteria for making the flags, and increase the amount t |
|
**Yellow:** Little deviation is visible, no flags are made, channels are under the % criteria and not marked.
|
|
**Yellow:** Little deviation is visible, no flags are made, channels are under the % criteria and not marked.
|
|
**Green:** The % criteria threshold. Any channel that peaks past this line will be marked for removal. As indicated this line can be moved based on your goals.
|
|
**Green:** The % criteria threshold. Any channel that peaks past this line will be marked for removal. As indicated this line can be moved based on your goals.
|
|
|
|
|
|
*Time Flags*
|
|
***
|
|
|
|
|
|
|
|
# Time Flags
|
|
|
|
Time flags work in a very similar way as the channels, but marks are place on time segments rather than channels. Since time is important to look at the figures have been rotated starting with 1 at the top and 3 at the bottom. A few examples of time flag calculations are:
|
|
|
|
* Low Correlation
|
|
|
|
* Independent Component Standard Deviation (ICSD) (usually several rounds)
|
|
|
|
|
|

|
|

|
|
|
|
|
|
|
|
* Sub Figure 1
|
|
|
|
This figure works the same as before with channel marks, containing the raw calculated values of the test preformed.
|
|
|
|
* Sub Figure 2
|
|
|
|
This plot expands on the values from the first sub figure, and works the same as with channels. Any raw calculated value that is over the z criteria will be flagged a 1, anything below will be a 0. To adjust this criteria change the following in the config files:
|
|
|
|
* ```[epoch_z] ``` in ```c01_scalpart.cfg``` for correlations . Default is 2.326 deviation, a higher number will produce less flags, lower will flag more.
|
|
|
|
* ```[epoch_z]``` in ```c03_compart.cfg``` (or c6,c13,c14) for ICSD. Default is 2.326, a higher number will produce less flags, lower will flag more.
|
|
|
|
* Sub Figure 3
|
|
|
|
The third plot uses the results from the second plot. It adds up the marks for each column of time and finds the % of each
|
|
|
|
time segment that was flagged between all of the channels combined. The percentage is displayed as a waveform travelling through time. When the wave spikes high it means there is a time segment where many channels are all detecting bad data, and if it passes the horizontal line it is passed your designated criteria. That time segment will then be flagged and marked for removal. This segment of time will be gone for all of the channels. The criteria line can be adjusted up and down to allow for more or less acceptable deviation. You can adjust the criteria of the flagging by adjusting variables like:
|
|
|
|
* ```[epoch_p] ``` in ```c01_scalpart.cfg``` for correlations. Default is 0.1(10%) of the channels in this time frame need to be flagged with the ```[epoch_z] ``` mark, a higher number will make the % required larger and thus less time segments will be flagged.
|
|
|
|
* ```[epoch_p]``` in ```c03_compart.cfg``` (or c6,c13,c14) for ICSD. Default is 0.1(10%) of the channels in this time frame need to be flagged with the ```[epoch_z] ``` mark, a higher number will make the % required larger and thus less time segments will be flagged.
|
|
|
|
|
|
*Component Classification*
|
|
# Component Classification
|
|
|
|
|
|

|
|

|
|
|
|
|
... | | ... | |