Here’s why the stock market could be primed for a year-end rally