Cleaned up spectralhistrogram.cpp