The military industrial complex often gets a bad rap because it manufactures the machines of war. However, much as we may dislike what companies like General Dynamics (NYSE:GD) and Lockheed Martin (NYSE:LMT) make, recent headlines about North Korea, Russia, and Syria suggest that world peace isn't around the corner anytime soon. Indeed, serving the U.S. military is both a vital and profitable niche market.

But if you're interested in investing in one of the defense industry leaders like General Dynamics and Lockheed, which one should you pick?

The conservative investor

I'm going to step back and look at this pair using a side by side comparison the way Benjamin Graham did in his highly influential investing classic The Intelligent Investor. This, however, is a look at the numbers, not a deep dive into the future opportunities at General Dynamic or Lockheed. The truth is, I don't need to dig that deep to make a choice here.

A hand drawing a scale showing value versus price

Image source: Getty Images

That said, both of these military specialists would likely qualify as conservative investments. According to Graham, that designation can be bestowed upon large, dividend paying companies with histories of profitability. General Dynamics is a roughly $60 billion market cap entity that's been in the black and paid a dividend in each of the last 10 years. And its earnings last year were more than twice what they were a decade ago. The story at Lockheed Martin, with a $90 billion market cap, is roughly similar. The balance sheet, meanwhile, isn't a material issue at either company.

Price is what you pay

So both Lockheed and General Dynamics would make it past my initial screen. But they wouldn't get past my second one: valuation. You see, a great company can be a bad investment if you pay too high a price for it. That's one of the core lessons Graham was trying to get across in The Intelligent Investor. And while I'm fairly confident that General Dynamics and Lockheed are well run companies with solid futures, I'm not nearly as pleased by the prices they fetch today.

GD PE Ratio (TTM) Chart

GD PE Ratio (TTM) data by YCharts

For example, Lockheed Martin's trailing price to earnings ratio is around 25.5. That's above the broader market and well above its own five year average of nearly 16. General Dynamics doesn't fare much better, with a trailing PE of almost 19, which is above its five year average of just under 15. Clearly, General Dynamics appears to be a better value than Lockheed Martin right now on this metric, but it is still far from cheap.

GD PS Ratio (TTM) Chart

GD PS Ratio (TTM) data by YCharts

Next, let's look at the price to sales ratio. Lockheed Martin's PS ratio comes in at 1.9 versus a five year average of 1.1. General Dynamics, meanwhile, has a PS ratio of 2 compared to an average of 1.2. This metric makes Lockheed look like the better deal. Both companies, however, are below the market on this metric, with the S&P 500's PS ratio sitting at around 2.2. That said, the PS ratios of Lockheed and General Dynamics are toward the high end of their longer-term trends. In the end, neither appears to be a particular bargain today.

GD Dividend Yield (TTM) Chart

GD Dividend Yield (TTM) data by YCharts

Last up is a personal favorite of mine: dividend yield. Both of these military industrial giants have solid dividend histories, which is impressive. However, Lockheed's yield is around 2.5% today, below its five year average of 3.2%. And while the yield is relatively high compared to its historical range, when you add in the PE and PS ratios Lockheed still comes off looking expensive. The story at General Dynamics is similar. This company's dividend yield is around 1.6% compared to a five year average of 2.1%. The yield is, at best, middle of the range compared to long-term trends. Take PE and PS into consideration and there's no compelling reason to jump aboard here, either.

I'd pass on both

While both General Dynamics and Lockheed Martin get through the initial screen as conservative investments, neither is particularly enticing when you look at valuation. Relatively high PE and PS ratios and relatively low dividend yields suggest you can find better opportunities elsewhere. So, in the end, if you are trying to figure out if General Dynamics Corporation or Lockheed Martin is the better buy, the real answer is that neither looks like a compelling opportunity right now. I'd pass on both for now until a better opportunity presents itself. 

Reuben Gregg Brewer has no position in any of the stocks mentioned. The Motley Fool has no position in any of the stocks mentioned. The Motley Fool has a disclosure policy.