progress in implementing statistic functions