change statistics code