Every day, Wall Street analysts upgrade some stocks, downgrade others, and "initiate coverage" on a few more. But do these analysts even know what they're talking about? Today, we're taking one high-profile Wall Street pick and putting it under the microscope...

With $52 billion in annual sales and a $90 billion market capitalization, Lockheed Martin (NYSE:LMT) is a bona fide titan of American industry -- and the biggest pure-play defense stock in the world. Maker of the vaunted F-35 Lightning II stealth fighter, it's going to be America's premier fighter-jet maker for decades to come.

Boeing's (NYSE:BA) even bigger, boasting $96 billion in annual sales, and more than $190 billion in market cap. Boeing sits atop the commercial jetliner market, and according to Statista.com, is the "[l]eading aerospace and defense manufacturer worldwide based on sales."

Swiss bank UBS likes them both.

F-35 fighter jet in flight

Boeing and Lockheed Martin win UBS' endorsement as the best stocks in aerospace and defense. Image source: Getty Images.

Upgrading Boeing and Lockheed

Yesterday, in a report covered on TheFly.com, UBS announced it is initiating coverage of the aerospace and defense industry. Citing an expectation that aerospace and defense sales will grow 5% annually through 2020, UBS gave the industry as a whole a "favorable outlook," and two of the companies UBS is most enthused about are Boeing and Lockheed.

Why? Well, you've probably heard that the U.S. military budget is on the rise, right? Increasing 9% in fiscal year 2018 to about $716 billion or so?

That already sounds like a lot, but what you've probably not heard is this: "[T]he Department of Defense's weapons budget is up 40% in three years," and it's likely we'll see "acceleration in revenues through 2020," according to UBS. "[D]efense spend will accelerate into 2019," argues the analyst, which should benefit Boeing and will certainly benefit Lockheed, the world's biggest publicly traded purveyor of weapons. At the same time, UBS says that emerging market growth is going to give a tailwind to Boeing's commercial airplanes business.

"[T]he 14-year reflation of air transport demand continues," argues UBS, and Boeing's customers are "profitable" and flush with cash with which to buy new airplanes to carry their own customers. Also, with "high oil" prices raising the cost of operating older planes, there's even greater incentive for airlines to buy new fuel-efficient airplanes from Boeing.

Is competition a factor? Yes, potentially it is. Still, UBS sees "favorable duopoly dynamics" in a market still dominated by Boeing and its archrival, Airbus. There may be emerging threats from new regional airframes in development in China, Japan, and Russia, but UBS sees competition from these sources as being at least a decade away and not an immediate threat to Boeing stock.

The upshot for investors

All things considered, UBS says Lockheed Martin is its favorite stock in the defense space. The analyst recommends investors buy Lockheed and predicts it will hit a share price of $400 within 12 months, predicated on a prediction that Lockheed will enjoy "EPS growth of 23% through 2020." (To put that in context, the average analyst polled by S&P Global Market Intelligence is predicting Lockheed will grow its earnings at only 12% annually over the next five years, so while UBS is looking at a shorter timespan, its forecast is way ahead of the rest of the market.)

In commercial aerospace, Boeing is UBS' favorite pick. Here, the analyst has a price target of $515.

But is UBS right, and are both these stocks buys?

In the case of Boeing, most analysts have the plane maker pegged for 15% annualized earnings growth over the next five years. With $12.5 billion in annual free cash flow, and a market cap of $190.6 billion (i.e., a price-to-free-cash-flow ratio of 15.2), I can't say I disagree with UBS' assessment. Despite having already risen 40% in price over the past year, Boeing stock still looks fairly priced to me -- maybe even cheap, once you factor in the effect of the company's strong 2% dividend yield.

The situation with Lockheed is a bit trickier. At $90 billion in market cap and $2.6 billion in free cash flow (and also, incidentally, $2.6 billion in net profit), Lockheed costs nearly 35 times GAAP earnings and 35 times free cash flow. That's clearly too much to pay for a stock growing at the 12% annual rate that S&P Global has on file for Lockheed stock. It might even be too much to pay if UBS is right, and Lockheed actually grows at 23%.

I like both of UBS' picks as businesses. But when it comes to valuation, I think Boeing stock is by far the safer stock to invest in.