But at least I adhered to my 1987 principle: I did not sell.

In the wake of the two-year bear market, I refined my strategy. I figured that if I bought every time the market average declined by 10 percent from its previous high — the standard definition of a correction — and then bought some more after each subsequent decline of 10 percent, then I’d never be buying at the top of the cycle.

I didn’t think of this as market timing, since I made no prediction where the market was headed. My strategy was a variation of the now-widespread practice of portfolio rebalancing — selling some asset classes and buying others to maintain a steady allocation.

I put this system into practice during the 2008 financial crisis. I recall shocked reactions that October when — with the market plunging and others boasting that they’d had the foresight to get out — I said I was buying.

My timing was hardly perfect. The market fell by 10 percent on five occasions — so I had plenty of opportunities to add to my stock positions. The last came in March 2009. In hindsight, the first of those 10 percent declines was a foolish time to have been buying, given that the market went down another 40 percent. But I reaped the gains even on those early purchases during the record-setting bull market that ended this month. Back in 2009, I didn’t have to worry about getting back into the market. I was already there.

What’s another virus scare?

There have been only five 10 percent corrections since then, and each was a buying opportunity for me. None was followed by a second 10 percent decline. The last of these corrections came at the end of 2018. As cash built up in my account, I wondered when, if ever, I’d get another such opportunity. I grew impatient. On Feb. 19, the S&P 500 closed at a record high. No one seemed to see a bear market or recession on the horizon, even as stock multiples teetered at record highs and a strange virus began to spread.

Until a week later.

Stocks fell, slowly at first, then gaining steam. By Feb. 25 the S&P 500 had dropped 7.6 percent from its peak.

From a financial standpoint, I wasn’t worried about the virus. Infections were leveling off in China. There were a few cases in the United States, most in a single nursing home in Washington State. Everyone was saying we had better medical care, better air quality and more effective means to prevent its spread than China. As an investor, I’d lived through many virus scares — SARS, MERS, swine flu, Ebola — and their ravages had no discernible impact on American stocks. Even the devastating AIDS epidemic had little effect on the broader economy or booming market.