Your investing playbook for a slow-growth economy

The economy is growing at a much slower pace than expected, but certain types of stocks have a history of thriving in such mediocre environments.

CNBC PRO used Kensho to study all the periods since 1981 where GDP increased at a pace between 0.5 percent and 1.5 percent. That's where we are now after Friday's Commerce Department report showed 1.2 percent annual growth in the second quarter and a 0.8 percent rate in the first period of the year.

Among major benchmarks, mid-cap stocks were the stars during slow-growth environments, according to Kensho.