script for statistic