Investors today are more optimistic about the stock market than they’ve been in nine years, but they’re moving more money into cash and CDs. That’s just one of several perplexing findings of the latest Wells Fargo/Gallup Investor and Retirement Optimism Index.

The index gained 11% in the third quarter to a reading of 79, up from 62 in the second quarter, based on improving sentiment about the stock market. Slightly more than half of investors are now “very” or “somewhat” optimistic  about the 12-month outlook for markets, up from 42% last quarter.

But an almost equal percentage of survey respondents are more worried about stock market volatility than low interest rates, and 43% reported they have moved money to cash or cash equivalent savings over the past year. That’s substantially higher than the 29% who moved funds into individual stocks or stock funds.

“It’s hard to say that people are optimistic if they’re actually investing heavily in cash,” said George Rusnak, co-head of Global Fixed-Income Strategy at Wells Fargo Investment Institute, which provides advice to the company’s financial and wealth advisors and their clients. “Maybe it’s based on recent growth that they’ve seen in the stock market…but going forward they’re seeing the challenges and risks associated with low interest rates [and] with potential uncertainty with elections.”

Respondents held an average 30% in cash and CDs or money market accounts, 35% in stocks or stock mutual funds and 10% in bonds or bond funds, according to the survey, which was based on phone interviews in early to mid August with 1,021 investors. The remaining 12% of portfolios was held in “other investments,” which could include real estate, gold or other commodities or alternative investments.

Rusnak stressed that investors will not be able to reach their average 7% annual gain this year and over the long term, which he defined as 10 to 15 years, if they continue to hold about 30% in cash.

Those heavy cash holdings reflect investors’ risk aversion. Close to 60% of survey respondents said they preferred taking no risk at all or very little risk, and close to 90% were worried about the impact of the presidential election on financial markets.

Younger investors, between 18 and 49, were more worried about the election’s impact on markets than those 50 and older, by a ratio of 68% to 57%, and women were more worried than men: 69% to 56%.

The most positive election result for the market, according to a recent report from the Wells Fargo Investment Institute, would be a Democratic president with a Republican Congress, which it labeled as “slightly positive” but with the lowest odds (10%) of happening.

A more likely outcome, with 40% odds, was a Democratic president and divided Congress, which Wells Fargo labeled as “neutral.”  The report gave negative market impact ratings for a Republican president with a Republican Congress and for a Republican president with a divided Congress.

Stock market volatility, the other big worry for investors, was considered a long-term threat to portfolios by 52% of respondents. Only 38% thought the same about low interest rates.

Not surprisingly, however, fewer retirees preferred low rates (41%) than non-retirees (71%), but many investors didn’t understand the impact of interest rates on bonds. Seventy-one percent of respondents either didn’t know that bond prices rise when interest rates fall or thought that bond prices fall when rates fall, which is the opposite of what actually happens.

“There needs to be education now…when rates are low,” said Rusnak, about correcting this erroneous belief.

He said Wells Fargo Investment Institute is currently overweight investment grade bonds, especially financials, and neutral on stocks.

—Related on ThinkAdvisor: