Abnormalities in brain function have traditionally been detected using electroencephalography (EEG), which involves the measurement of the ongoing electrical activity generated by the brain.