If people really do vote for a person rather than a party, then politicians who decide to switch after getting elected have nothing to fear from resigning their seat, and standing for re-election.
There are a few reasons:
1. Special elections take time and money. For the House with its 2 year terms a few months out of office represents a significant portion of the term.
2. Legally they were elected to represent their districts (or states). That role is not altered by their party affiliation. They still have obligations to represent their constituents, especially on local pecuniary issues.
3. Switching parties is hard. Your old party's voters will feel like you abandoned them and will want someone of their own; your new party will feel like the seat should be filled by someone who's been fighting for the party for longer; the voters without party may or may not stick with you (and may not have voted for you in the first place).
4. Benefits: Someone who switches to the opposition party usually gets some sort of sweetener. It might just be the fact of joining the majority, or it might be a seat on a committee they value, or it might be the backing of a powerful funding source. Some of these things can be broken by the resignation
5. They might not even win the primary. This is true for their regular reelection attempt after the switch, but at least they'll have a chance to prove themselves to the party base first.
Party switching is a tricky tactic for legislators and it has a fairly low survival rating. I would think that resignation and special election would be lower.
Of course none of this applies in this case as the party switching member will not be in Congress after the end of the year since he did not run for reelection.