Buy stocks just when a recession is confirmed? Here's why the risk can pay off.