No, it wasn't to keep slave owning states in the union. You're confusing the 3/5th compromise with the electoral college. The reason we have 50 little elections instead of one big one is to keep the largest states from dictating policy to everyone else.

Whenever you have voting you have swing votes. That's just Democracy. If it wasn't swing states it would be swing voters nationwide.