Investors have struggled to navigate the election, underlining the difficulty Wall Street so often has with politics.