The stock market tends to lose a third of its value heading into recessions, RBC says