preparing statistics