Macy's (M 0.16%) is a retail favorite among investors. However, the stock opened lower on Thursday after the company posted disappointing sales for its second-quarter and slashed its forecast for the year. Many now wonder if this is the beginning of a downward trend for the retail industry at large. While Macy's disappointing results took Wall Street by surprise, shareholders shouldn't panic just yet. First, let's dig into the facts.

By the numbers
For the quarter ended Aug. 3, Macy's delivered earnings of $0.72 per share for a profit of $281 million. This is an increase of 7.5% from the year-ago period. Unfortunately, analysts were looking for earnings growth of 16% and earnings per share of $0.78 for the quarter. Revenue hobbled in at $6.07 billion, also below consensus.

However, the retailer's comparable-store sales really burned. Macy's same-store sales declined 0.8%, whereas analysts had anticipated a comparable-sales increase of 2.3% for the quarter. Same-store sales is a key metric for retail stocks because it measures the performance of stores open at least a year. This helps investors get a more accurate read on the operational health of the business. In this case, Macy's blames the consumer for its negative comps.

Looking ahead, the department store chain now expects fiscal 2013 comparable sales growth of between 2% and 2.9%, which is significantly lower than the company's earlier prediction for a 3.5% growth in comps.

Blaming the consumer
While Macy's was the first major retailer to report earnings, it wasn't the first mall retailer to blame weak sales on the consumer. Nordstrom's (JWN 4.40%) same-store sales for its second quarter also came up short of expectations, and similar to Macy's, Nordstrom reduced its sales outlook for the year. The high-end department store chain now expects same-store sales to increase just 2% to 3%, down from the 3% to 5% growth it had previously forecast.

These disappointing results from both Macy's and Nordstrom fueled analyst's concerns about the retail industry as a whole. Adrienne Tennant of Janney warned, "We perceive headwinds for the sector for the fall season." 

Nevertheless, I think the market's pessimism is overblown. Here's why.

A shopping bag half full
It hasn't been all bad news for the retail sector this week. Kohl's (KSS 4.53%), for example, traded higher on Thursday after the retailer reported second-quarter results that met analysts' expectations. Earnings per share increased $0.04 to $1.04 in the period ended Aug. 3. Additionally, Kohl's delivered better-than-expected same-store sales, with revenue at stores open at least a year climbing 0.9% in the quarter.

One thing to keep in mind here is that retail stocks are extremely cyclical. This is particularly true today as consumers grapple with higher payroll taxes and expensive gas prices. However, that doesn't mean all retail stocks are bad investments. In fact, despite a tough retail environment, these department store stocks have performed exceptionally well so far this year. As you can see in the chart below, Macy's, Nordstrom, and Kohl's have all posted strong gains year to date.

M Chart

Macy's data by YCharts.

Moreover, as a whole, consumer discretionary stocks have "tallied the second-best earnings growth of the 10 S&P 500 industry sectors, with 8.5 percent growth in the second quarter," according to data from Thomson Reuters. As more retailers release earnings in the coming week, investors should remember to take a long-term view.

Sure, Macy's quarterly results weren't great, but one quarter of down sales doesn't merit selling the stock. The market reacted to the fact that Macy's missed earnings for the first time in 25 straight quarters. However, that's hardly a reason to cash out, especially if you're a long-term investor.

In an industry as competitive as retail, Macy's stock still looks attractive at where it trades today, around $46 or just 10 times forward earnings. For comparison, shares of Nordstrom currently trade around $57 apiece at nearly 14 times next year's earnings, while Kohl's trades at 11 times forward earnings and will cost you about $52 a share. With Nordstrom and Kohl's both trading at pricier multiples than Macy's today, I think there's more upside for Macy's stock from here.

Importantly, Macy's continues to reward shareholders through share repurchases as well as dividend payouts. In fact, Macy's share repurchases were better than expected in the recent quarter, according to Citigroup analyst Deborah Weinswig. In May, Macy's boosted its quarterly dividend by 25% and increased its share buyback program by $1.5 billion, according to The Wall Street Journal. Together, these things tell me that Macy's is still a winning stock even in the face of a challenging retail environment.