Wal-Mart Stores (WMT -0.18%) has been trying its level best to outmaneuver economic headwinds, but unfortunately it hasn't been successful of late. The retailer's dull performance in the latest quarter shows that it is still not getting back on track. Let's take a deep look into Wal-Mart and also analyze its peers Costco Wholesale (COST -0.58%) and PriceSmart (PSMT -0.79%).

Fourth-quarter results
In the fourth quarter, Wal-Mart once again exhibited weak performance, as its earnings per share slipped by 4.2% to $1.60. However, total revenue climbed 1.5% to $129.7 billion. Severe weather conditions during the holiday season put pressure on the company's top-line growth. Furthermore, due to food stamp cuts, many low-income consumers didn't spend much while shopping.

Segment analysis
United States: In the US, net sales grew 2.4% and stood at $76.4 billion. Same-store sales declined by 0.4%, as the retailer continued to face tough economic challenges in the country.

International: Net sales from international operations declined by 0.4% to $37.7 billion; this was attributed to global economic headwinds and currency fluctuations. Operating income dropped massively, by 45%, due to higher operational expenses.

Sam's Club: Net sales at Wal-Mart's membership warehouse club rose 1.3% to $14.7 billion. Comparable sales declined by 0.1% compared to growth of 1.1% in the year-ago period. Operating income dipped by 15%.

What is Wal-Mart up to?
Wal-Mart's small-format stores continued to do well, as their comps grew 5% in the quarter. In the last quarter, Wal-Mart said that it will be opening 120 to 150 small stores in the domestic market. However, after seeing further success, the company has now announced its goal to open 270 to 300 small stores in the current fiscal year. These small-format stores are great for people living in urban areas that are far away from the company's large supercenters.

Wal-Mart is integrating its stores into e-commerce, as it wants to compete with Amazon.com in the online marketplace. Global e-commerce sales for Wal-Mart crossed $10 billion during fiscal 2014, surpassing the company's target. The retailer will continue to spend on e-commerce as it foresees huge growth in the online segment. These investments will exert pressure on the company's earnings in the coming quarters but will likely bear fruit in the long term as Wal-Mart attracts more online shoppers.

The Supplemental Nutrition Assistance Program is the largest anti-hunger program in the US, providing food stamps and economic benefits to low-income families. During the latter part of last year, President Obama signed legislation which will cut $8.7 billion in food stamp benefits during the next 10 years. This means that about 850,000 households will lose an average of $90 per month.

According to Cowen analyst Tal Lev, approximately 20% of Wal-Mart customers are reliant on food stamps. The cut has already affected the retailer, as its top-line growth suffered during the fourth quarter. The lower-income families will continue to shop Wal-Mart less, putting more pressure on the retailer's sales.

Wal-Mart gave a conservative outlook for the next quarter; it expects per-share earnings of $1.10 to $1.20, while sales are projected to grow by 3% to 5%. Comps are also expected to remain flat. For fiscal 2015, forecast earnings are $5.10 to $5.45, indicating a slightly better picture for the future.

Costco's performance remained strong in the latest quarter, as the retailer continued to target budget-conscious customers through its unique membership-based retail business. Total revenue, inclusive of membership fees and net sales, grew 5.5% to $25 billion while earnings edged up to $0.96 per share. Comparable sales growth was 3%.

Costco continued adding more members as a result of its highly competitive discount prices. The company has its eyes set on expanding both in the domestic and international markets. Moreover, it is investing in e-commerce and in-store IT to increase its store efficiency.

PriceSmart has been growing at a steady pace in the last few quarters. In the latest quarter, its per-share earnings grew 7.5% to $0.71, which was a direct result of solid top-line growth. Comps jumped by 7.9%, as the retailer was able to increase its membership base by more than 12%.

The company's January results showed that net sales increased 11.5%. For the five months ended Jan. 31, net sales jumped by 11.9% to about $1.1 billion, showing that the company is on the right track.

Final thoughts
Wal-Mart missed its earnings expectations once again, as it continued to face economic challenges coupled with changes in governmental regulations. During these trying circumstances, the company's small-format stores performed pretty well. Investment in these stores will certainly pay dividends, but it will take time; these small stores, at the moment, account for just 25% of Wal-Mart's total stores.

E-commerce, too, will reap benefits, but it also needs more time before it starts to strengthen Wal-Mart's earnings. To grow its profits substantially in the next few quarters, the retailer must find a way to enhance its top-line growth across its supercenters. But with severe competition in the US retail sector, this is easier said than done. Taking everything into account, I will remain neutral on Wal-Mart.