updated comm_stat_function