Research finds a flat environment is best for stocks of all stripes, but there are some surprising results when the Fed is cutting or raising rates.