refactor annual report table generation code.