Since the 1950s, with few exceptions, upper-income voters have leaned more Republican than the broader population. In a study of national elections, Mr. Gelman found that “census and opinion poll data since 1952 reveal that higher-income voters continue to support the Republicans in presidential elections.”

Mr. Gelman said the wealthy naturally favored policies that favor them, and Republican staples like lower taxes and smaller government were preferable than larger government and redistribution of wealth. “They support policies that benefit their group, because in their view, those are the best policies and best ideas,” he said.

If the wealthy voted according to their pocketbooks, their choice for president would be clear.

Mr. Trump has pledged to cut the federal income taxes of the top 1 percent by more than 25 percent, allowing them to keep an extra $215,000 each year, according to the Tax Policy Center. He would eliminate the estate tax, reduce regulations, cut the capital-gains tax rate and create a special, superlow tax rate for some business owners.

Mrs. Clinton, by contrast, would make the top 1 percent pay an average of $117,000 more a year while superearners in the top 0.1 percent would see their taxes go up more than $800,000 a year. She would also increase taxes on certain capital gains, limit loopholes used by the wealthy and target dynastic wealth with a steeper estate tax.

In recent decades, there is evidence that wealthier voters have been leaning more Republican. In 1956 and 1960, the share of Republican-identified voters in the top income quintile “was only slightly higher in the highest than in the lowest quintile,” Mr. Gelman said. By 2000, those at the top were more than twice as likely to identify as Republican than those at the bottom, according to Mr. Gelman’s study.

The closest comparison to the current election among affluent voters is the one in 2008, when Barack Obama carried about half of voters who earned more than $100,000. Yet Mr. Gelman said John McCain still did better among the rich than the poor, and compared with the broader electorate, the wealthy voted Republican more often.

In the current election, Mrs. Clinton is poised to capture a far larger share of the affluent vote than Mr. Obama. And if the numbers hold, the elite would lean more Democratic than Republican for the first time in at least 50 years, Mr. Gelman said.