LONDON—Commodities outperformed other assets this year as a recovery from the pandemic boosted demand though gold’s poor showing dented investor appetite. Heading into 2022, commodities, which often perform well late in economic cycles, are due to remain competitive with equities as global growth extends its upward trek, analysts said. “We like both equities and commodities and we have an overweight view for both in 2022. It’s hard to say which one will do better,” said Koen Straetmans, senior multi-asset strategist with NN Investment Partners in the Netherlands, which had 298 billion euros ($336 billion) under management at end of September. The S&P Goldman Sachs Commodity Index index has surged 35 percent this year, trumping the U.S. equity index S&P 500 for the first time in a decade. The S&P 500 has gained 23 percent, the dollar index has added 7 percent while U.S. benchmark 10-year treasury bonds are down 3 …