restored factorial to statCalc