Javascript Standard Deviation Function In Matlab