Friday was a down day for the stock market, but major benchmarks didn't slip too far from where they started the day. A drop in crude oil took prices back below $46 per barrel, igniting debate about whether the global economy is sufficiently strong. An accelerating rise in the value of the euro against the U.S. dollar also raised some concerns among investors looking for stability as central banks seek to remove financial crisis-era stimulus measures. Even though many market participants were downbeat today, some stocks did manage to post gains. Plug Power (PLUG -5.17%), Capital One Financial (COF 0.90%), and athenahealth (ATHN) were among the best performers on the day. Below, we'll look more closely at these stocks to tell you why they did so well.

Plug Power makes a new deal

Shares of Plug Power jumped 15% after the fuel-cell technology specialist announced a new arrangement with partner Wal-Mart Stores (WMT 0.46%). The big-box retailer had already made a deal to obtain hydrogen fuel-cell-powered forklifts from Plug Power, but the announcement gives Plug Power access to project financing at a lower cost of capital, facilitating the partnership. The fuel-cell company expects to provide GenKey hydrogen fueling stations and fuel-cell energy solutions to as many as 30 more Wal-Mart locations in North America over the next three years, with 10 sites already under contract and scheduled for completion by the end of this year. CEO Andy Marsh was pleased with the arrangement, noting that "our expanding relationship with Wal-Mart validates Plug Power's advanced capabilities in fuel cell products and systems, allowing the world's largest retailer to maintain its leading position as an industry innovator." Investors hope that the deal will lead to more business from other customers, and they were willing to overlook the dilutive impact of more than 55 million warrants that Plug gave Wal-Mart as part of the arrangement.

Plug Power charging equipment.

Image source: Plug Power.

Capital One banks a good quarter

Capital One Financial stock rose 8.5% in the wake of the release of the company's second-quarter financial report. The bank said that net interest income climbed 7% from year-ago levels, helping to lift earnings by 15% to $1.94 per share. Capital One was especially pleased that its provisions for credit losses were down by 10% compared to the first quarter of 2017, and it also expressed confidence that it would be able to work with the Federal Reserve to come up with a modified capital plan to address issues that the central bank had raised in its stress test review earlier this year. Investors were willing to overlook a rise in delinquent loan-related write-offs and an increase in loan loss reserves because of better earnings performance than expected, but Capital One will need to stay strong in order to sustain the share price's gains.

Athenahealth's earnings pick up

Finally, shares of Athenahealth climbed 8.5%. The provider of network services and point-of-care mobile applications for hospital and healthcare institutional clients said that revenue climbed 15% during the second quarter of 2017 compared to the year-ago period, and adjusted earnings soared by half. Athenahealth said that its efforts to expand its network are still paying off with better growth metrics, and it reaffirmed its guidance for the full 2017 fiscal year. Coming after a disappointing quarterly report in April, Athenahealth's results this time around reassured investors that long-term growth prospects for the company remain strong.