Warren Buffett’s Berkshire Hathaway Inc on Saturday posted a 23% decrease in quarterly operating profit, while soaring prices in stock holdings such as Apple Inc enabled the conglomerate to smash its old record for full-year earnings.

In his annual letter to Berkshire shareholders, Buffett defended Berkshire‘s foray into stocks, which comes amid a four-year drought since its last major acquisition that has left Berkshire sitting on $128 billion of cash.

Berkshire did step up repurchases of its own stock, buying back roughly $2.2 billion in the quarter. Repurchases totaled $5 billion for the full year.

“I am delighted with the increased commitment to share repurchases,” said Thomas Russo, a partner at Gardner, Russo & Gardner, which invests $13 billion, of which 13% is in Berkshire. “It may be a very large arrow in Berkshire‘s quiver to increase intrinsic value on a per-share basis.”

Nonetheless, while the BNSF railroad and Berkshire Hathaway Energy units showed improvement, reinsurance operations weighed on operating results, and the Geico car insurer posted “subpar performance” as loss claims eclipsed premium growth, according to Cathy Seifert, an analyst at CFRA Research.

“The big miss was on the insurance front, though energy and railroads were stronger,” Seifert said. It will be interesting see the impact of coronavirus on freight traffic in the first quarter and beyond.”

Berkshire Hathaway said it produced a $325 million in insurance underwriting operating profit for all of 2019, but that compares to close to $1.6 billion in 2019. For the 2019 fourth quarter, the company booked an $857 million insurance underwriting operating loss, up from a $225 million loss in the 2018 fourth quarter.

Insurance investment income, on the other hand, reached more than $1.4 billion in the 2019 fourth quarter, compared to more than $1.1 billion in Q4 2018. For the full year, Berkshire Hathaway said it produced $5.5 billion in insurance investment income, up from more than $4.5 billion in 2018.

Fourth-quarter operating profit fell to $4.42 billion, or approximately $2,720 per Class A share, from $5.72 billion, or about $3,484 per share.

Berkshire did not write down its 26.6% stake in Kraft Heinz Co, which is struggling to rebound from years of cost-cutting amid changing consumer tastes, though its market value is well below the $13.8 billion carrying cost on Berkshire‘s balance sheet.

Net income, reflecting stock gains, totaled $29.16 billion, compared with a net loss of $25.39 billion a year earlier.

For all of 2019, net income totaled $81.42 billion, topping the record $44.94 billion for 2017, when Berkshire benefited from a lower U.S. corporate tax rate.

Such huge swings stem from an accounting rule requiring Berkshire to report paper gains and losses from its stock holdings with net income.

Buffett wrote that companies whose stocks Berkshire owns are generating returns that are “remarkable under any circumstances,” especially compared with returns on bonds.

Apple soared 86% in 2019 and 31% in the fourth quarter alone, leaving Berkshire with a $73.7 billion year-end stake.

Berkshire‘s stock was a laggard in 2019, rising 11% compared with a 31.5% gain in the Standard & Poor’s 500 including dividends, in part reflecting the drag from the cash stake.

*Carrier Management added insurance financial results information to this story.