NEW YORK ( TheStreet) -- Bank of America ( BAC) reported a second-quarter profit of $3.1 billion, or 27 cents a share, early Friday, saying credit costs improved for a fourth straight quarter.

Total revenue, net of interest expense, was $29.45 billion for the three months ended June 30.

The latest quarter's results reflect a number of special items related to asset sales, including a pretax gain of $1.2 billion from the sale of an equity interest in Itaú Unibanco Holding.

The average estimate of analysts polled by Thomson Reuters was for a profit of 22 cents a share in the June period on revenue of $29.75 billion.

In the same period a year earlier, the bank earned $3.2 billion, or 33 cents a share, on revenue of $33.1 billion.

"Our quarterly results show that we are making progress on our strategy to align around our three core customer groups - consumers, businesses, and institutional investors - and create the financial institution that customers tell us they want, built on a broad relationship of clarity, transparency, and helping them manage through challenging times," said Chief Executive Officer and President Brian Moynihan. "We improved our capital foundation through retained earnings, and credit quality improved even faster than expected."

The stock closed Thursday at $15.39, down 1.8% for the session. Year-to-date, it's up 2.2%, but has pulled back significantly from a 52-week high of $19.86 set on April 15.
More on Earnings
Today's Top Earnings
Earnings Calendar

-- Written by Michael Baron in New York.
Disclosure: TheStreet's editorial policy prohibits staff editors, reporters and analysts from holding positions in any individual stocks.