It has to do with how the districts are drawn up. The shape of districts in a state has a large part to do with how the votes are represented in the house. Say you have. City with 1 million people, and 70 percent are democrats and live in one central area. If you make the area one district, and make a lot of smaller districts around it, the house will be majority republican from that city, with only one district being Democrat.