add support configable MaxDisplayItems in 'stats' function.

in case there are lot of items need to display. you can specify the
MaxDisplayItems in CLI or in patterns files.