implemented peak classification function. need to test