They're two of the biggest pharmaceutical companies in the world, but Merck (NYSE:MRK) and GlaxoSmithKline (NYSE:GSK) have had very different paths lately. While Merck's stock is up close to 30% over the last 12 months, shares of GlaxoSmithKline have declined.

Which is the better pick for investors now? Here's how Merck and Glaxo compare.

Three scientists in lab

Image source: Getty Images.

The case for Merck

There's one major reason behind Merck's tremendous stock performance: Keytruda. The cancer drug is off to a great start after receiving U.S. regulatory approval for treating advanced melanoma in 2014. Merck subsequently won approval for several other indications for Keytruda, including as a second-line treatment for non-small cell lung cancer and as a second-line treatment for head and neck squamous cell carcinoma.  

Perhaps the biggest story for Keytruda so far, though, is the FDA approval in October for the drug as a first-line treatment of non-small cell lung cancer. Merck is now emerging as the clear leader in the large lung cancer market in the U.S. and a major player in other oncology indications. 

Keytruda is Merck's top star, but the company does have other solid performers in its lineup. Sales for its vaccines are increasing at an impressive rate, as are sales for antibiotic Cubucin and cholesterol drug Zetia.

Merck is awaiting regulatory approval for four drugs. Its pipeline includes 24 late-stage clinical programs, 10 of which are evaluating Keytruda in additional indications. Merck also has 12 other phase 2 programs.

One of the biggest reasons to like Merck is its dividend. The dividend yield currently stands just below 3%. Although the company currently is using much of its earnings to cover the dividend payments, Merck's earnings growth prospects should allow the dividends to keep flowing at least at current levels.

The case for GlaxoSmithKline

GlaxoSmithKline doesn't have a single powerhouse drug like Merck does with Keytruda. However, the drugmaker does have a couple of big winners in Tivicay and Triumeq. Sales for the HIV drugs soared 70% year over year in the third quarter.

Like Merck, Glaxo is also seeing strong sales growth for its vaccines. Sales for quite a few other products in the company's lineup are increasing as well, including several of its respiratory drugs.

However, the main problem for GlaxoSmithKline is that sales for its top-selling drug, Seretide/Advair, are falling significantly. Generic competition has taken its market share away since Glaxo lost patent exclusivity for the respiratory drug.Still, though, GlaxoSmithKline's newer products are helping considerably. Around a quarter of the company's total pharmaceutical sales now come from new drugs.

Better yet, more winners could be on the way. Glaxo hopes to win regulatory approval for its Shingrix shingles vaccine soon. The company's pipeline includes over 90 clinical programs.

GlaxoSmithKline claims one of the highest dividend yields around at 4.7%. However, the company is spending more to pay the dividend than it's making right now.  

Better buy

Which of these stocks is the better pick? GlaxoSmithKline's pipeline could position the stock to be a bigger winner over time. Wall Street analysts expect Glaxo's earnings to grow more than 13% annually on average over the next few years. 

However, Merck appears to be in better shape right now. Keytruda is on its way to becoming the company's biggest seller. I think the edge, for now at least, goes to Merck. Glaxo's pipeline is promising, but there's still plenty of uncertainty. Investors can pretty much bank on Keytruda's success. That gives the edge to Merck.

This article represents the opinion of the writer, who may disagree with the “official” recommendation position of a Motley Fool premium advisory service. We’re motley! Questioning an investing thesis -- even one of our own -- helps us all think critically about investing and make decisions that help us become smarter, happier, and richer.