Arizona continued to emerge from the worst of the housing market crash in May, with foreclosure filings down 59.3 percent from May 2012, a foreclosure marketing company reported Thursday.

Additionally, the Phoenix metropolitan area experienced a 64 percent decline in foreclosure activity from one year to the next for May, reported RealtyTrac of Irvine, Calif. Phoenix just a few years ago was among the three worst metro areas in the nation for foreclosure filings.

RealtyTrac reported that it counted 3,797 foreclosure filings in the state in May, 2,645 of them in the Phoenix metro area. The state was ninth worst in the country in foreclosure filing rate per housing units, while Phoenix ranked eighth worst among the 20 biggest metropolitan areas.

Foreclosure filings are defined as default notices, scheduled auctions and bank repossessions, and thus, one property could have more than one filing and the filings number does not indicate the actual number of properties in foreclosure.

Nationally, foreclosure filings fell 28 percent in May from the same month in 2012, RealtyTrac reported.