O N ANY GIVEN day since he took office, Donald Trump has had a lower job-approval rating than almost every other modern president at the same point in their tenure. But over the past two weeks the polls have finally been giving Mr Trump some good news. According to an average of public polling data calculated by FiveThirtyEight, a data-journalism website, he is more popular than he has been since March 2017, two months after he took office. The BBC called it Mr Trump’s “best week” yet in office. Political betting markets increased his chances of re-election by roughly ten percentage points.

These positive appraisals have overlooked a crucial fact about the methods of conducting opinion polls in America. Because the people who take part in surveys are often not representative of the population as a whole, pollsters use a statistical procedure called “weighting”, which adjusts the findings to meet certain demographic targets. The technique helps firms ensure that their surveys have enough young people in them, for example, and that they achieve a good balance of minorities and working-class whites.

But even after correcting for demographic biases, pollsters’ data can still be unrepresentative. They may have the right shares of Latino voters and boomers, but nevertheless have too many Republicans or Democrats. This concern is pronounced when an event causes especially good, or bad, news for a political party. At such times surveys can suddenly be swamped with partisans who are eager to voice their love, or hate, for the president.

In the wake of Mr Trump’s acquittal in the Senate, pollsters suspect that such a bias could be affecting polls. Courtney Kennedy, the director for survey research at the Pew Research Centre, says that there is a “strong possibility” that the recent uptick in Mr Trump’s ratings has a wave of optimistic Republicans as its source. She says that outlets can control this problem by adjusting their data to have the correct shares of Democratic- and Republican-leaning voters, but the idea is relatively new and few pollsters have data good enough to perform such corrections.