Working EQ

Placed filter in a callable function. Cleaned up and made comments in
the code.