LAST weekend I ate a cricket on national television. Based on my statistical analysis of presidential polls, I made a bet that if Donald J. Trump won more than 240 Electoral College votes, I would chow down. Like millions of voters in both parties, I was surprised by the outcome. As a consolation, I’d like to learn what went wrong — and to figure out how pollsters might do better when they puzzle over our polarized electorate.

Data-based websites, from Facebook on down, have a responsibility to convey accurate information. In this regard, I owe an apology to readers of the Princeton Election Consortium, which I publish. My primary purpose was to show people where to put their campaigning energies by revealing which races were on a razor’s edge. I advised my readers to focus on close Senate races in states where the presidential race was also close. But I also reported an extremely high probability that Hillary Clinton would win, which was published by The New York Times alongside its own model.

Did we lull voters and the news media into a sense of complacency about the election? In hindsight, it would have been better to express Mrs. Clinton’s polling margin as equivalent to a 2.2 percentage point lead — and that the true margin could be higher or lower by several points. That would have better conveyed the race’s uncertainty.

Poll aggregation is built on the idea that pollsters are more accurate as a group than they are individually. During the primaries, I used state polls to argue that Mr. Trump was the strong favorite to win the nomination. However, general-election polls did less well, and so did I. State polls underestimated the Republican-versus-Democrat margin by four percentage points, the largest error in decades. This presidential-level polling error was echoed in the national House popular vote and Senate polls, which were also both off by a median of four percentage points. As Nate Silver of FiveThirtyEight has pointed out, errors are often correlated. A warped ruler is flawed no matter how many measurements are averaged.