Each period's net-income flows into retained earnings, and each dividend flows out. It is a cumulative history, not a pot of cash: a company with $400M of retained earnings has spent most of it on factories and acquisitions long ago.
Traders use the trend rather than the level. Retained earnings that stop growing while revenue keeps growing means profits are being paid out or destroyed somewhere.
Example: Northwind Tools starts the year with $352M of retained earnings, adds $78M of net income, pays $28M of dividends and ends at $402M.
Related: shareholders-equity, net-income, dividend, capital-allocation, economic-profit