calculate mean/median/mode in angular