(Reuters) - Warren Buffett's Berkshire Hathaway Inc BRKa.N on Friday reported a 15 percent drop in second-quarter profit, as lower investment gains and a loss from insurance underwriting offset improvement in its BNSF railroad business.

FILE PHOTO: Berkshire Hathaway CEO Warren Buffett visits the BNSF booth before the Berkshire Hathaway annual meeting in Omaha, Nebraska, U.S. May 6, 2017. REUTERS/Rick Wilking/File Photo

Operating profit also fell short of analyst forecasts, though Berkshire attributed much of the decline to currency fluctuations and its accounting for a major contract with the insurer American International Group Inc AIG.N.

Net income for Omaha, Nebraska-based Berkshire fell to $4.26 billion, or $2,592 per Class A share, from $5 billion, or $3,042 per share, a year earlier.

Operating profit declined 11 percent to $4.12 billion, or $2,505 per Class A share, from $4.61 billion, or $2,803 per share.

Analysts on average expected operating profit of about $2,791 per share, according to Thomson Reuters I/B/E/S.

Buffett believes operating income is a better gauge of how Berkshire and its more than 90 businesses are doing than net income, which fluctuates more because it incorporates investment and derivative gains, which fell 64 percent from a year earlier.

Book value per share, Buffett’s preferred measure of growth, rose 2.7 percent from the end of March to $182,816.

The company’s stock price, meanwhile, set a record high on Friday, with Class A shares closing up $1,629.80 at $270,000.

“They had a good quarter,” said Bill Smead, chief executive of Smead Capital Management Inc in Seattle, which owns Berkshire shares. “The results reflect Berkshire’s positioning in the U.S. economy.”

RAILROAD

BNSF saw profit rise 24 percent to $958 million, helped by high single-digit percentage increases in freight revenue from consumer and industrial products, and double-digit increases from agricultural products and coal.

Profit from manufacturing, service and retailing units rose 10 percent to $1.66 billion, helped by greater demand for products from its IMC International Metalworking unit.

Such gains helped offset a second straight quarterly loss from insurance underwriting, totaling $22 million compared with a year earlier $337 million profit.

Berkshire said that weakness reflected losses from currency changes, higher claims payouts at the Geico auto insurance unit, and the amortization of deferred charges from its January agreement to take on long-term AIG property and casualty risks in exchange for $10.2 billion upfront.

That contract helped boost float, or the amount of insurance premiums collected before claims are paid and which help fund Berkshire’s growth, to $107 billion from $91 billion at year end.

MORE CASH, MORE STOCKS

Berkshire ended June with about $99.7 billion of cash and equivalents, plus large investments in shares of Kraft Heinz Co KHC.O, Wells Fargo & Co WFC.N, Apple Inc AAPL.O and Coca-Cola Co KO.N.

It bought just over $3 billion of stocks in the quarter, and is poised to become Bank of America Corp's BAC.N biggest shareholder by exercising stock warrants at below-market prices, for what would now be a $12.5 billion paper profit.

Berkshire has found uses for some of its growing cash hoard.

Its Berkshire Hathaway Energy unit, whose quarterly profit rose 7 percent, hopes to spend $9 billion to buy the parent of Texas power transmission company Oncor Electric Delivery Co out of bankruptcy.

And in June, Buffett threw a C$2 billion financing lifeline to Home Capital Group Inc HCG.TO, Canada's largest nonbank lender, which was struggling with a deposit exodus and had admitted to concealing mortgage fraud.

Thanks to Buffett, Home Capital said this week that issues over whether it can survive have been resolved.

Berkshire’s operating businesses also including smaller units that sell such things as See’s Candies, Dairy Queen ice cream and Brooks running shoes.