Printed circuit board stocks have been very kind to investors lately. It is almost impossible to find a ticker in this sector that hasn't been beating the S&P 500 market tracker over the last 52 weeks.

How do you pick the top names in this broadly lucrative industry? I'm here to show you my three favorites in the printed circuit board market: Sanmina (NASDAQ:SANM), Benchmark Electronics (NYSE:BHE), and TTM Technologies (NASDAQ:TTMI), each one tailor-made for a different type of investor.

Read on to see what I mean.

Circuit board production in full swing.

Image source: Getty Images.

The towering giant

Sanmina's annual revenues are larger than TTM's and Benchmark's total sales put together. Printed circuit boards are a small component in this electronics manufacturing giant's global empire, with 45,000 employees spread out over 25 countries and six continents.

The company is among the world's largest circuit board manufacturers, but it consumes most of these materials in the process of putting together shelf-ready products for its customers. Sanmina does sell a small amount of printed circuit boards, cables, and other components directly to other electronics manufacturers and other clients, charging a small markup for these contracts.

Components and products produced 26% of Sanmina's gross profits over the last six months, culled from just 20% of the company's total sales.

The stock trades at just 13.6 times trailing earnings, and Sanmina investors have enjoyed a 49% return over the last year. Book-to-bill ratios stand at 1.1 today, which is a sign of revenue growth coming down the order pipeline. If you want safety and stability, this is your printed circuit board stock.

Woman counts growing piles of coins.

Image source: Getty Images.

The over-achieving cash machine

Like Sanmina, Benchmark Electronics makes most of its hay from electronics manufacturing services. Benchmark may not be able to match Sanmina's economies of scale, but it's an extremely efficient cash machine.

The company produced free cash flows of $241 million in the last four quarters, based on $2.3 billion in top-line sales. That works out to a 10.5% cash margin, far above Sanmina's 3.1%.

Moreover, Benchmark has been growing its cash profits steadily in the last three years. The company is pursuing even wider gross profit margins by doubling down on opportunities in the medical, industrial, and sensor markets. Benchmark's highest-margin divisions grew their sales in 2016, while the less profitable computing and telecommunications segments swooned.

Benchmark should continue to raise large cash profits out of modest revenues. The stock is trading at just 4.4 times trailing free cash flows, making it an attractive target for investors with an eye for strong cash generation.

High-tech car concept.

Image source: Getty Images.

The bottom-line growth story

Finally, TTM Technologies is the purest play on circuit boards you'll find anywhere. The market is fragmented, and many of its rivals include printed circuit boards as part of a diverse strategy, like Sanmina and Benchmark. But it's all TTM does. Hidden in the name is another clue to TTM's unique market position, focusing on quick "time to market" delivery of circuit board orders.

That strategy puts TTM at the vanguard of pretty much every technology sea change. This is where you go when you want to be first to market with a game-changing consumer product or military tool. The company was a major supplier to cell phone and tablet makers when those products categories were new and exciting. Today, TTM is exploring fresh vistas in automotive computing, with continued support from the smartphone market.

The billion-dollar merger with rival Viasystems in 2015 gave TTM's revenues an overnight boost while adding the target company's roster of auto makers to TTM's customer Rolodex. That deal looks more prescient than ever, as automotive computing slides deeper into the mainstream.

TTM's share prices have more than doubled in 52 weeks, but they still trade at less than 9 times forward earnings estimates and roughly 7 times trailing free cash flows. This company is going places, taking investors along for an enriching ride.

Anders Bylund has no position in any stocks mentioned. The Motley Fool has no position in any of the stocks mentioned. The Motley Fool has a disclosure policy.