But as the campaign drew to a close, the candidates were locked in a tight race, a Marquette University poll found, after some Republican groups had already pulled television advertising to run in the state.

An influx of money in the last weeks of the campaign, totaling about $20 million, seemed to have an effect, as did Mr. Johnson’s attempt to soften his image with television ads portraying him hugging constituents and changing a diaper.