A sophisticated analysis of polling data shows that the House Freedom Caucus saved the GOP’s House majority from a huge electoral backlash by helping to defeat the House Speaker Paul Ryan’s alternative to Obamacare, says Chris Wilson, head of WPA Research.

The “House Freedom Caucus members held the line, and the data show that is precisely what their constituents wanted,” he wrote in a report, titled “Analytics shows HFC saved GOP on Health Care.”

On Thursday, Texas GOP Rep. Louie Gohmert predicted any approval of Ryan’s healthcare overhaul would wreck the GOP’s House majority in 2018. “This bill is going to ultimately result in Republicans losing the majority … [and] If we pass a bill that doesn’t bring down premiums and give the American people hope, and not give more power to the government … then we will deserve to be voted out,” he said in a speech on the House floor, according to TheHill.

“While full repeal and replace of Obamacare has overwhelming support in these districts, even keeping Obamacare intact was more popular than the AHCA, often by more than a two-to-one margin,” said Wilson, who managed Sen. Ted Cruz’s voter analysis and tracking efforts in 2016.

The same analysis was applied to 2018 Senate races and concluded that “the House Freedom Caucus did … Republicans’ hopes of expanding their Senate majority, a great service in stopping the [Ryancare] bill before it made it across the Capitol,” Wilson wrote.

But Wilson’s analysis also shows strong public support for an alternative repeal-and-replace “plan that allows for the sale of insurance across state lines, expands Health Savings Accounts, incentivizes states to create high-risk pools, block grants Medicaid, and is portable so it can be taken from job to job.”

Wilson’s analysis is based a huge national survey, which allows his group to understand the preference of each population subgroup. For example, voters are asked three questions about each issue, he said. Typically, one question is skewed from a left-wing perspective, one question is skewed from the right, and the third question is intended to be unbiased, he said.

In turn, the team then used three voter-response models to predict preferences among each politicians’ particular subgroups of voters. In this survey, the models were used to gauge each district’s’ voters preference for three healthcare options — continuing Obamacare, establishing Ryan’s “Ryancare” replacement, and the third option, “Repeal and replace.”

Subsequently, the analysts spend much time check and rechecking the accuracy of the voter-response models in each district, he said, adding “you’ve got to spend time double-checking,”

Politicians are increasingly using this style of voter analysis to understand their constituents, amid constant pressure from lobbyists and donors, he said.

In the healthcare analysis, Wilson said he didn’t try to gauge why the voters approved or rejected each of the three policy options. “I don’t have the ability to discern or divine the reason why the voters answered as they did… that’s the next stage” of development, he added.