Given President Donald Trump’s controversial start, it’s no wonder friends and foes alike are already buzzing about his impact on the 2018 midterm elections. It’s still early in the cycle, but not too early to look at what various indicators say about the two parties’ prospects.

Presidential job approval and the right direction/wrong track questions are most often used to track changes in voters’ attitudes, but the generic ballot test is also useful.

The generic ballot question traditionally has asked respondents whether they plan to vote for the Republican or the Democratic nominee for the House in 2018, but the NBC News/Wall Street Journal asks the generic ballot this way: “What is your preference for the outcome of next year’s congressional elections — (ROTATE:) a Congress controlled by Republicans or a Congress controlled by Democrats?”

I’ve always preferred the NBC News/Wall Street Journal wording, since it leaves individual candidates out of the mix completely, focusing only on the two parties.

The NBC News/Wall Street Journal generic ballot question hasn’t been a perfect indicator of things to come, but it has often signaled the kind of midterm election ahead.

The October survey of the midterm year correctly projected a small Democratic gain in 1998, a modest GOP gain in 2002 and a large Democratic wave in 2006. But in 2010, it appeared to suggest a small GOP gain, not the 63-seat turnover that actually occurred. And, the modest Democratic gain it promised in 2014 turned out to be a 13-seat GOP gain on Election Day. So caution is warranted.

Still, looking more deeply at the generic ballot during two strongly partisan midterm outcomes — the Democratic wave of the 2005-2006 cycle and the GOP wave of the 2009-2010 cycle — is bound to generate some useful questions, even if it doesn’t produce perfect answers.

2005-2006

In July 2005, the NBC News/Wall Street Journal generic ballot stood at +5 for Democrats, but it grew to +9 in October (48%-39%) and +11 in November (48%-37%).

Over the next ten months, the Democratic generic ballot advantage remained in the high single digits to low double digits. In the final four NBC News/Wall Street Journal polls before the 2006 balloting, the Democratic advantage on the generic ballot ranged from 9 points in September (48%-39%) to 15 points (52%-37%), in October, the last pre-election survey.

That kind of advantage in the generic ballot is far from the norm, but starting about a year before the 2006 midterms, Democratic double-digit leads became the rule, not the exception.

On Election Day, the National House exit poll suggested that Democrats won by about 8 points — well below the final October poll’s generic ballot margin but still a considerable Democratic advantage that certainly explains the party’s 32-seat gain.

2009-2010

Four years later, the generic ballot behaved very differently.

Democrats started with a 9-point advantage in the April 2009 NBC News/Wall Street Journal poll (48%-39%) and held a 7-point advantage three months later in July (46%-39%).

President Obama still had solid job ratings well into 2009, and Democrats won two upstate New York special elections that year, which reflected the public’s mood. On March 31, Democrats held New York’s 20th C.D., and on September 21st they flipped an open GOP seat in New York’s 23rd C.D.

But while the October 2009 generic ballot suggested the public mood was stable (+8 Democrats), something clearly started to happen toward the end of 2009 and early in 2010.

The September 2009 generic was only +3 for Democrats (43%-40%), the December generic was +2 Democratic (43%-41%) and the late January generic remained at only +2 for Democrats (44%-42%).

Yes, Democrats continued to have an edge, but nothing like what they had earlier in the year. A significant change had occurred.

In late May 2010, the NBC News/Wall Street Journal generic ballot flipped to Republicans +1 (44%-43%), followed by a June generic of +2 for the GOP (45%-43%). Both the late August and September 2010 polls found the generic tied (43%-43% and 44%-44%), while the final NBC News/Wall Street Journal poll of the cycle, conducted October 28-30, found the GOP with a small 2-point advantage in the generic ballot question (46%-44%).

The national House exit poll found Republicans winning that vote by 7 or 8 points, very close to the Democrats’ margin in 2006. The GOP gained 63 seats, comfortably within the range 55-65 seat range projected by the Rothenberg Political Report immediately before the election.

Responses to the generic ballot question showed a huge Democratic advantage in 2006 but only a narrow Republican one in 2010, yet both midterms saw partisan waves. Of course, it is noteworthy that both cycles saw large swings in partisan sentiment during the two-year cycles.

The Democrats’ initial advantage in the generic ballot during their wave cycle started at 7 points in May of 2005 and 5 points in July. It ended up at 15 points in the last NBC News/Wall Street Journal poll of the cycle, in October 2006.

The GOP’s generic swing was comparable in 2009-2010. That cycle started with a 9-point Democratic advantage in April 2005 and a 7-point advantage in July. It ended up at a 2-point Republican edge in the last NBC News/Wall Street Journal poll of the cycle, in October 2010.

2017-2018

The April 2017 NBC News/Wall Street Journal poll showed Democrats with a 4-point advantage in the generic ballot, 47% to 43%. That advantage doubled to 8 points (50%-42%) in the June 17-20, 2017 poll.

The size of the Democratic advantage certainly doesn’t now guarantee a partisan wave in 2018. But if the advantage grows, Republicans will get very nervous, even though the round of redistricting that took place after the last census generally strengthened Republicans’ holds on their districts.

Of course, Donald Trump still has an opportunity to improve his standing with the general public, which would make it more difficult for Democrats to win back the House.

Democrats almost certainly need a double-digit advantage in the generic ballot question (and a slew of retirements) to net at least the 24 seats they need to re-take the House next year. That is still a heavy lift for the Democratic Congressional Campaign Committee. But given the president’s low job approval ratings and his style and behavior, Democrats have plenty of cause for optimism that the House of Representatives will be in play in 2018.