An electroencephalogram, also known as an EEG, is a test that looks at the electrical activity of the brain.