Actually, it's not based on seniority at all. It used to be before the GOP came to power, but they wanted to keep RINOs out of power so they changed the rules so anyone can become a chair (based on either the leadership or the Republicans on the committee). One woman congresswoman from NJ (can't recall her name right now) retired in 2002 because of this. She was "in line" to be the chair, but was passed over.
So what are the new rules, and what procedures do they set for the ouster of a committee chair?