With the Republican party making big gains in the recent midterm elections, many investors are looking for legislation that will benefit businesses and consequently generate market gains.

But history shows that the market performs strongly around the mid-term elections no matter which party prevails. As a result, it's investors who have historically been the real winners.

The 17 mid-term election cycles since 1946 have invariably served as catalysts for market gains, notes Sam Stovall, chief equity strategist of S&P Capital IQ.

In midterm election years, the S&P 500 index's average return between October 31 and the following October 31 has been a jaw-dropping 17.5%, he reports. The S&P has produced a positive return in every single the midterm election year since 1946.

This trend tends to get overshadowed by the passionate emotions that swirl up around election time, however. Democrats point to historical evidence that the market grows more when they're in power. Republicans counter that they're better fiduciaries of taxpayers' money and that they're more business-friendly.

The volatility that occurs around election time, I believe, is partly due to investors getting caught up in the emotions accompanying politics. If one party wins, the market will soar; if the other party wins, the world will go to pot.

But pulling your money out of the market when the other party wins, and vice versa, is a silly idea. Investors are best served by compartmentalizing their political views and their investment decisions. No matter the political situation, investing is still about following a long-term plan to meet your goals and objectives without taking on an in appropriate level of risk.

My advice to clients: Don't make knee-jerk investing reactions based on elections—or on headlines of any sort. Stay on course with your investment plan, and make sure your portfolio is properly balanced to reap the potential gains in the stock and fixed-income markets.

Don't forget that the right financial advisor can help to keep you focused on your portfolio, not on Washington, D.C. And if history is a guide, the market may offer good risk-adjusted returns over the coming year.