Most commonly if Retained Earnings are not reporting correctly it is due to the Accounts being incorrectly allocated in the Cashflow settings:
Navigation is Budgets & Cashflow > Cashflow Settings > Bank & Equity
Review the accounts allocated to Retained Earnings and Current Year Earnings
Make any changes required
SAVE CHANGES and run the reports again to check