In contrast to 2016, US investors greeted 2017 full of optimism under a Donald Trump presidency. By reducing corporate regulation, cutting taxes and increasing infrastructure spending, his policies should help generate higher employment that will pull the economy along and boost share prices. That’s the theory at least; never mind that it might take three or four years before any holes are dug, or that many of Trump’s policies face opposition from within his own party, as many don’t want to see America’s huge pile of debt get much bigger.

For anyone looking to profit from Trump’s policies, keep in mind that share prices have already moved to factor them in. In fact, we enter 2017 with one of the most expensive US sharemarkets ever. The chart shows the median valuation of the stocks in the S&P 500 measured by the ratio of price to revenue, which aims to slice through the numerous ways earnings can be manipulated.

As a side note, it’s been said that the gap between generally accepted accounting principles earnings and non-GAAP earnings (the manipulated earnings that management likes you to focus on) is at a cyclical high.

This situation might turn you off stocks altogether, but it’s hard to see how anyone is going to live a comfortable retirement investing in alternatives such as real estate or fixed-interest investments, whose prices reflect a 30-year fall in interest rates to virtually zero. This is a trick that not even the 220 PhDs working at the Federal Reserve will be able to replicate.

It also spells danger for anyone invested in passive investment strategies based on a broad US index. Buying an index fund in March 2009 was smart and sensible, as valuations were low and the impact of zero-interest-rate policies allowed you to triple your money without ever needing to consider what you owned.

Distinguish between individual stocks

Valuations have now reached a point where distinguishing between individual stocks is key to achieving respectable returns. As is usually the case in the mature stage of a bull market, many investing alumni who focus heavily on risk have underperformed. Those who pay the least attention often do best; for example, the most popular names, such as Facebook, Google, Netflix and Amazon, continue to climb as more money from passive index funds and ETFs buys more of the largest and most expensive stocks.

Their combined market value has now reached US$1.4 trillion ($1.8 trillion), so they can absorb large amounts of capital. They’re also an easy sell to clients, because their share prices keep going up as their revenues increase. This reinforces investor confidence, even if it’s only the tidal wave of money from passive funds driving up the valuations.

History is a good teacher, though, and there have been long periods where index funds have underperformed, such as 1966-82 and 2000-03. The risks of another similar period increase as valuations continue to bake in more good news. Fortunately, there are simple ways to avoid following the herd and protect your hard-won gains since the GFC.

The simple way, though not easy, which is why more investors don’t do it, is to build a portfolio of unloved and undervalued businesses. Their low valuations are what compensate and protect you from the numerous risks that markets and businesses face in the most competitive world we’ve ever experienced, driven by new technology.

Active on Twitter

Take Twitter, for example. It’s as contrarian an investment idea as you’ll find right now. While it’s easy to sell the merits of a rapidly growing, well-managed business like Facebook, its virtues are well and truly priced into the stock. Not so with Twitter.

If you weren’t aware of Twitter before the US presidential race, then you surely are now. Provided you don’t use more than 140 characters, Twitter is a social-media platform that largely lets you share any thought that crosses your mind with the entire world.

What’s not as well known about Twitter is its financial and operating history as a listed company. It has largely been left for dead, down 35 per cent since its float at $26 on November 7, 2013, and 70 per cent from its high of $70 a month later. Discussions to sell the company last September amounted to nothing.

Twitter’s problems are many, but despite management’s best efforts, it seems it can’t be killed. The resilience of a business despite mismanagement is usually a clue that you’ve found a potentially great long-term investment.

The company’s recent, belated moves to silence trolls (the name given to people posting hate speech and other degenerate material) should also make it more attractive to advertisers that will continue to switch their marketing budgets away from, for example, linear TV.

Twitter’s recent experiment streaming live National Football League matches is also gaining momentum, quickly increasing its audience for matches from about 2 million to 3 million.

If the company could deal with its bloated cost structure and increase operating profit margins towards 40 per cent (still well below Facebook’s), the stock would be trading at under 13 times pre-tax income, less than half of what Facebook now trades on.

Should management botch things yet again, the company’s cash-rich balance sheet, absence of dual-class share structure with super voting rights, and minuscule market value compared with other social media companies should eventually make it a takeover target, potentially limiting our downside. A classic case of heads we win, tails we shouldn’t lose too much.

Only time will tell whether management can create the value we see in Twitter, but what we do know from decades of experience is that filling a portfolio with unloved stocks like Twitter will produce respectable returns with less risk.

Right now, it also seems investing with an active manager about as contrarian as you can get. Given the market usually does what it can to confound as many investors as possible, this bodes poorly for the future returns of index funds after such a monumental run since 2009.

Disclosure: Peters MacGregor Capital Management Limited holds a financial interest in Twitter through various mandates where it acts as investment manager.

Join the discussion