A trader works on the floor of the New York Stock Exchange, on Nov.12, 2013. Reuters/Brendan McDermid

Big pension funds and university endowments that shifted their investment portfolios to include fewer stocks and more alternative investments like hedge funds after the recent financial crisis have missed out on a stock rally that has lifted global markets to near record highs, according to a Wall Street Journal analysis.

The paper said on Tuesday that the investors that trimmed their asset allocation from stocks to alternative securities, as General Motors Co. (NYSE:GM) and Harvard University’s endowment did, had better returns than stocks had in 2008, probably the worst year of the crisis. But from 2009 until the present stocks have outperformed alternative investments.

The report qualified the data by pointing out that most of the investors studied have very long-term investment horizons, so those bets could still play out over time, or also be part of a broader hedging strategy. It also pointed out that when the time frame is expanded to 10 years, some of the alternative investments outperformed stocks.

"Missing out on recent stock gains, though, adds to challenges facing pension funds, some of which don't have enough assets to meet future obligations," the report concluded. "For universities dependent on endowment income, reducing stockholdings represents a lost opportunity in a time of stretched resources."