Tuesday, April 29, 2014

Concentration - Birds Beat the Internet

Now I'm getting serious.  In my last post, I finally saw for myself what "concentration" looks like in my EEG signals.  And now I'm totally hooked.  Now I want to expand my goals.  How?  Well, let's see how my concentration varies during natural activities, not just during my synthetic concentration exercise.  Where to start?  Well, how about at breakfast?  For me, breakfast includes some eating, some Internet, some bird watching...good stuff!  I hoped that my new EEG metric for "concentration" might reveal some interesting trends about my brain while breakfasting.  And, as you'll see, I was not disappointed...

Today's Breakfast Attire...Electrodes on the Forehead and Ear Lobes.

Goal:  My goal was to record some EEG signals to see how my concentration varies with different natural activities.  Today, I recorded EEG while breakfasting.

Setup:  My setup for recording my EEG was similar to the previous post -- a gold electrode on the forehead, a gold electrode on my left ear lobe as reference, and a ear clip electrode on my right ear as bias.  Today, I also added a second gold electrode to my forehead (Chan 1 is my left, Chan 2 is might right).  The picture above shows their locations.  To keep the wires out of my face (important for eating), I looped the electrode wires over my ears.  I connected the electrodes to my OpenBCI V2 board (shown below) and recorded the data using my GUI in Processing.  My electrode impedances measured about 20 kOhm.

My Usual Connection to my OpenBCI Board.  Confusingly, my electrode breakout
is mislabeled..."SRB1" is actually SRB2.

Procedure:  Since I wanted to record natural activities, I did not define a rigid test procedure prior to the test.  Without a scripted procedure, it's really tough to know what you did (and exactly *when* you did it) during a long test such as this.  To address this problem, I setup my camera to record a video of the whole test.  That video is my "truth".  In the movie (some example frames are below), I saw that I spent some time setting up the electrodes, some time eating my food, some time on the Internet (reading and writing), some time gazing out the window at the birds (my favorite part), and some time doing more work on the Internet.  Finally, at the end, I did my regular EEG concentration test -- counting backwards by 3 from 100.  I've got all this as one long EEG record.

I used my camera to record a movie of me eating breakfast.  I used this
as a record of "truth" to see what activity caused what EEG signal.

Data, The Quick Overview:  The EEG spectrogram below is the whole data record as seen my the electrode on the left side of my forehead.  As you can see, there's a block of activity at the beginning (up to 240-300 sec).  This is what was recorded while I was attaching the electrodes to my head.  After that, there's a block of activity from 300-650 sec with some really crazy signals, followed by a long block with more typical EEG signals.  What was happening during that crazy time?

The Complete EEG Record During Breakfast.  Chewing is clearly a very
intense signal that masks all true EEG activity.

Chewing Destroys EEG Signals:  By aligning the EEG data with the movie, it is clear that this period from 300-650 seconds is when I was eating my breakfast.  That morning, breakfast was some wheat Chex and grapefruit juice.  Pretty exciting?  No?  Well, the EEG signals sure are exciting.  See all that strong broadband red activity?  That's the effect that chewing has on EEG.  Dramatic!  I don't know if the cause is muscle artifact or if it is the jiggling of the electrode wires (or both), but the signals are huge!  If you zoom in (not shown), you can see each individual chew.  So, if you wanted a "CCI" (a Chew-Computer Interface) in addition to a "BCI" (Brain-Computer Interface), an EEG system would be a great way to do it.  But, if you wanted to see brainwaves while eating (like I was hoping to see), the act of chewing will basically destroy your data.

The Rest of My Data:  After eating, I still had another 20 minutes (1200 sec) of EEG data, so it wasn't too sad that chewing destroyed the early part of my data.  The spectrogram below zooms in on just the data after my chewing.  This looks like a more normal EEG recording.  Below the spectrogram, I show some processed results.  Specifically, I show the magnitude of the EEG signal in just the 22-100 Hz band, which was chosen based on the "count backwards by 3" experiment in my previous post.  So, if "counting backwards by 3" is considered "concentration", then this blue line is a measure of concentration.  At least, it is a measure of one type of concentration.  In the figure, note that my concentration level does seem to change in response to my different activities.  I find this to be very cool.

Zooming in on the activity after my chewing.  The top plot is the spectrogram of the data.
The bottom plot shows the magnitude of the portion of the EEG in the 22-100 Hz band.

Birds are Better than the Internet:  Looking at the graph above, you can see that my concentration level starts pretty low while I'm working on the Internet.  Surprisingly, the movie shows that I'm not passively reading.  No, it shows that I am actively engaged (mostly typing a reply regarding a theremin).  Given this engagement, I would have expected my concentration to be strong.  Nope.  Compare this to the next section of time, where I'm simply gazing out the window at the birds and trees.  My apparent concentration level (or, at least, my EEG activity in the 22-100 Hz band) gets noticeably higher.  Wow!  Then, when I return to my Internet work, it drops strongly.  I guess that birds are more stimulating than the Internet!  Go birds!

Stronger Concentration Today:  At the end of this test, I closed my eyes and relaxed, which caused my the EEG signal level to drop, as expected.  Then, I opened my eyes and did my concentration exercise where I count backwards by 3.  This portion of my test repeats what I did in my previous post.  In today's recording, however, my signal levels were much higher.  As shown in the plot below, today's data shows 2.8 uV with my eyes closed and 7.6 uV while counting backwards.  Compare this to the previous post where I showed only 2.0 uV and 3.4 uV, respectively.  So, I was 3.4 uV and now I'm 7.6 uV.  This means that my "concentration" intensity is nearly twice as strong!  Why?  Was it because this data was from the morning, when I was fresher and could maybe concentrate "stronger"?  I don't know.  I do find it interesting, though.

Quantifying the EEG Signal Level During the Different Periods.

Summary So Far:  Even with just this simplistic analysis, the data has been way more surprising than I would have guessed.  I would have thought that breakfast would have been a little boring...I mean, I'm just sitting there.  But this data has been surprisingly rich.  Three things have surprised me:
  1. Chewing makes huge signals as seen by an EEG system
  2. Birds and trees stimulate my brain* more than the Internet
  3. My peak concentration level* can change a lot day-to-day
(* In both cases, "my brain" and "concentration level" really just mean "my EEG signals in the 22-100 Hz band".  But it sounds a lot less exciting when said that way.)

One More Thing...:  At this point, I figured that I was done.  I mean, three new findings is certainly enough excitement for me.  But then I remembered that I had data from the 2nd electrode that was on my forehead.  We already looked at the data from the left electrode (spectrogram repeated below).  What did the data from the right electrode show?  Its data as shown as the 2nd spectrogram below, though it's not particularly exciting by itself...it shares many of the signatures seen in the first electrode.  The excitement comes when I examine the "coherence" of the signals between these two electrodes.  The coherence as a function of time and frequency is shown in the third plot.  It looks pretty boring, except right there at the end.  What is happening there?

Measuring the Coherence Between the Left and Right Electrodes on my Forehead.
For the "concentration" signals prior to counting backwards, the signals are
not coherent.  For the counting backwards, they are coherent.  Why?!?
What is Coherence?:  Coherence is a measure of how two signals move together -- if one signal gets stronger, does the other get stronger, too?  If one gets weaker, does the other get weaker at the same time?  Signals that move together have a high coherence (ie, a value near 1.0).  Signals that do not move together have low coherence (near 0.0).  I've analyzed the coherence a couple of times before, such as in this earlier post.

Today's Coherence Data:  For today's data, the coherence plot above shows a few interesting features.  First, in the lower frequencies (10 Hz and below), this plot shows that the signals from the two electrodes on my forehead exhibit high coherence (the plot has a lot of red).  OK.  Above 10 Hz, though, the signals from these two electrodes are not coherent (blue).  Fine.  At then end, though, while I'm counting backwards, these higher frequency EEG signals suddenly become coherent (red). Whoa!  What happened?!?

Counting Backward Must be Different:  If "concentration" is reflected as activity in the 22-100 Hz band, this coherence plot suggests that my "concentration" is different at the end compared to the rest of the test. It appears that the Internet and the gazing outdoors both induce independent (ie, not coherent) activity in the left and right sides of my forehead.  Then, at the end, it appears that my counting exercise causes synchronized (ie, coherent) activity on both sides of my forehead.  Counting backwards must require different brain activity than the concentration associated with the Interent and birds.  While this sounds obvious, these objectively-recorded EEG signals are saying the same thing.  I think that's amazing.

Next Steps:  I've discovered many features in this single recording that get me really excited.  Before I get too excited, I should repeat the experiment.  If these phenomena appear again (especially the finding regarding the coherence), I would feel a lot more confident that it is true.  At that point, I would be really interested in seeing if something similar happens in other people.  If so, perhaps its a known phenomenon discussed in the literature.  Perhaps there is a known cause and a description of the brain mechanism(s) in action.  I'm interested to know!

Follow-Up:  Interested in getting the EEG data from this post?  Try downloading it from my github!

12 comments:

  1. Chip, hi.

    The terms or phrases you are more likely to find in research papers would be EEG task coherence ('task' instead of 'concentration'). A lot of work out there in this area:

    https://www.google.com/search?q=eeg+task+coherence

    In the neurofeedback field, Kirtley Thornton has a unique form of QEEG he does, that assesses coherence during different cognitive 'activations'. He uses a special form of coherence he calls SCC spectral correlation coefficient. Traditional QEEGs are done with no 'task', in separate segments of EC eyes closed and EO eyes open. Thornton has a unique and valuable perspective.

    http://www.chp-neurotherapy.com/eyes-closed-vs-act.html

    http://www.chp-neurotherapy.com/pdfs/SampleQReport.pdf

    ReplyDelete
    Replies
    1. William, thanks for the links! I'll check 'em out tonight...

      Chip

      Delete
  2. Very interesting finding Chip! I will definately repeat the same experiment to check my EEG recording with my system. I completed my board layout this week. I will have the board soon.

    Regard the Chew-Computer Interface, my lab partner used eye blink artifacts as a control signal. He used a low pass filter to detect whether there is an eye blink, pupil move to the left or pupil move to the right. The signals are very strong at some specific locations. Also, if you look around when you are watching bird, it may create some artifacts from eye movement I think.

    Great work and documentation! You inspired me alot!
    Bob.

    ReplyDelete
    Replies
    1. Thanks for the kind words! And I definitely look forward to any concentration results that you get with your system!

      Regarding eye tracking, I totally agree...eye blinks are strong in EEG and easy to detect. Changing eye position also causes a strong EEG signal (as a change in DC). I did a little examination of this effect in one of my posts from late last year:

      http://eeghacker.blogspot.com/2013/11/measuring-eog-with-my-eeg-setup.html

      Your lab partner was smart to exploit these effects as a control signal. They're probably way more reliable than using brainwaves.

      Thanks for continuing to come by and read my stuff...

      Chip

      Delete
  3. Hi Chip, your work with EEG and the its documentation here is just amazing. Around the time that you started this blog, late last year, I was working on my university project to build a Brain Computer Interface using DIY hardware like yours.

    I soon hit a road block when verifying that the acquired signals were indeed EEG and not random noise proved to be difficult. What is your approach to check that you are indeed picking up EEG ?

    Secondly, I am told that in clinical practice, preparation of the scalp - shaving the hair, removing excess dead skin etc. - is a major step before EEG signals are acquired. This helps to reduce the skin-electrode impedance below about 5 kOhms. Do you perform similar scalp preparation, especially when the electrode is to be placed on the back of the head ?

    Thanks a lot in advance for the reply and keep up the amazing work. It is really inspiring.

    ReplyDelete
    Replies
    1. Thanks a lot for both the replies. This is just the information I wanted.

      Delete
    2. The guidance to shave and to scrub hard were developed during the decades of EEG practice when the electronics were not as good. Now that they are better, skin preparation is not as critical.

      For me, to confirm that I'm getting decent EEG signals, my procedure is:

      1) Confirm that the EEG system is working by measuring my ECG. See my posts: http://eeghacker.blogspot.com/search/label/ECG

      2) If I get a good ECG, then I move on to EEG...specifically, I record my eyes-closed Alpha waves, beause they're the easiest to get. To do this, I put an electrode on the back of my head (working it so that it is definitely on my skin in between all my hair) and I put the reference electrode on my earlobe (or forehead). I close my eyes and, after a second or two, I get fairly strong signals around 10 Hz.

      Good luck!

      Chip

      Delete
  4. Also, kindly share how you attach the electrodes to the scalp and the forehead. I found that the adhesion of the Ten20 EEG paste was not sufficient.

    ReplyDelete
    Replies
    1. Hello Jobin,

      The picture that you see at the top of this post...those electrodes are held on with just the Ten20 paste. I'm sorry if it's not working for you.

      To my knowledge Ten20 is always the paste stuff. If they make a variant that is a gel, and if that's what you're using, I could understand why you're having troubles...EEG gel (like what you'd squirt into an EEG cap) is definitely not viscous enough to hold an electrode to your head.

      If the Ten20 isn't working for you, you could use the Ten20 and then hold them on with a headband or with strips of gauze + tape. When I watched them do an EEG at a hospital for a stroke patient, that's what they did...stuck on the electrodes and then wrapped the head.

      Chip

      Delete
  5. Hello Chip,

    Just came to know about this EEG thing and I'm literally illiterate in the EEG world but I do wish to learn more and more, tried and got the Thought Technology's ProComp2 for recoding EEG and stuff but having no background on how to interpret I wish if you could guide me to interpretation part or any literature about it.

    Thanks for your good posts.

    ReplyDelete
    Replies
    1. Hello Nakul,

      Thanks for your interest! I went to the Thought Technology website and looked at the ProComp2. I'm not familiar with their products nor with the more general field of commercially-sold neurofeedback devices such as this. I looked at some of the screenshots and, other than the spectrum displays, it was not clear to me what was happening. Sorry!

      Someone who might be more knowledgeable on commercially-available neurofeedback devices might be William Croft, who posts comments here (for example, he has one at the top of this comments section of this post). If possible you might see if you can contact him for his thoughts.

      Good luck!

      Chip

      Delete
    2. Nakul, I'd suggest you go to www.brain-trainer.com , Pete Van Deusen's site for home trainers. He does do some work with the Thought Tech equipment. Most of his designs and packages though are geared towards Bioexplorer, and amps such as those from Pocket Neurobics. I hope you got a good deal on a used TT amp, because the Pocket Neurobics units are generally lower priced, more features.

      Delete