The recently released UK GDP figures had George Osborne and co dancing in the aisles.

Opposition doubters like Ed Balls and sceptical economists at the IMF were treated to a barrage of ‘I told you so’.

Annual GDP growth of 3.1 per cent to June 2014 and a return to pre-crisis levels of economic output are being hailed as a return to the good times and a triumph for government economic policy.

Leaving aside the questions of why it took so long and how much government policy actually drives economic recovery, it has to be good news and surely it follows that this must be a good time to invest in UK PLC.

An increase in economic output must lead to increased profits which will be reflected in higher stock market values. It’s certainly true that there appears to be a greater appetite among investors to invest in booming economies, but do the figures back up the feeling? Unfortunately, it would seem not.

Take the FTSE All share index over the last couple of years. The index is up 25 per cent since June 2012, but the majority of that growth was achieved up to May 2013, a period when the UK economy grew by a paltry 1.3 per cent. The index is broadly at the same level now as it was 12 months ago despite the stellar GDP figures.

This is a specific index over a short period of time, but studies have shown that similar patterns come up over much longer periods and across global stock markets.

The economic miracle that is China grew GDP by an astonishing 18 per cent per annum from 1994 to 2011. Over the same period the value of its listed companies actually fell by three per cent per annum. In contrast, the US market grew by over seven per cent annually over those 18 years on the back of a modest four per cent annual GDP growth.

So why is the expected outcome so out of line with reality? And what can investors do to allow for this?

The main aspect is that stock markets are forward looking and build in investors’ expectations of future earnings either from an individual stock or the market as a whole.

So investors in the UK in early 2012 anticipated higher economic growth in the future so bought into UK companies to take advantage of assumed higher earnings.

This sent the FTSE index higher in 2012/13. As it turned out, these expectations were largely met in 2014 but not exceeded. Expectations for company earnings over the next 12-24 months are largely flat, so the index has been largely flat.

There are many other factors which mean the connection between stock market values and GDP growth is weak at best. In the UK & USA, for example, many of the larger constituent companies listed on the main indices generate the majority of their sales overseas, so local economic conditions have little bearing on their profits.

Sales are only half the story when it comes to profitability – companies that can control their costs, by reducing wage costs for example, can maintain profitability. By contrast, companies that are more at the mercy of the market when it comes to input costs, may struggle for profitability even in the good times.

The UK market is dominated by large mining companies. High oil prices have pushed their costs up at the same time as falling commodity prices have hit their income. The FTSE as a whole has suffered because of this.

Many of the emerging markets where investors have looked to achieve high returns, such as China and Russia, are dominated by the state. Resources are allocated according to the government’s plans rather than by market forces.

This can lead to dramatic economic growth, but it is difficult for investors to find companies that are willing and able to maximise earnings in the face of state interference. Investors have tended to buy into the story rather than the reality.

Ultimately, investors should remember what they are buying into: the future flow of earnings of an individual company, not the whims of the market.

Investors and their advisers should be looking at the valuation and prospects of a business before investing.

The local economic and political conditions may influence the decision to invest but it is just one of many factors to consider.

A globally diversified portfolio of stocks, consistently managed, will protect investors from market risks and provide consistent returns over the long term.

* Trevor Law is a director with Merito Financial Services, chartered financial planners, based in Solihull.

E-mail: tilaw@meritofs.com