There are many things to consider when installing a bathroom fan, but when we went to install one in a viewer's home, we were stopped short when we discovered that the old one had no duct at all attached to it. It just shot right into the attic. You must get that hot moist air beyond the attic and to the outdoors. I have heard recommendations that suggest that you can just lay the duct on top of the insulation, and the moisture will dissipate. NO. I often see the duct just placed down in the soffit area. NO. I have seen the duct attached in the soffit area and pointing downwards. NO. Remember that hot air rises and no matter how hard you try to direct it out, the warm moist air will just rise up and come back into the attic. We are talking about rotting out the roof deck and/or causing water leaking into the house, sometimes in surprisingly large quantities.
When the duct is simply stuck into a roof vent, most of the moisture will escape, but much of it will form frost on the underside of the roof vent and then drip back into the house. If you must go out through the roof, use a proper roof exhaust hood, which allows for the duct to be attached to the vent, and for any condensation to drain out onto the roof rather than back into the bathroom. The best is not to go uphill through the roof, but downhill through the vertical gable end of the attic. That way condensation will drain out to the outdoors. Better yet is to ventilate in the same way as with an "HRV" and run the duct down inside the house and out through the basement with a stronger fan to take it far enough. This way the ductwork remains warm and there are no problems in the attic either.
There are two other important aspects to installing a new fan. First, noise. Noisy fans will not get used. Fans are rated in Sones -- one Sone being about the noise of a quiet refrigerator hum. 1 sone is very good -- 4 sones will begin to bother you, but can be acceptable for high speed exhaust for short periods of time. If a fan has no sone rating, count on it being noisy.
The second problem is the ductwork itself. If you use flexible ducting that has pronounced ribs on the inside (even worse if the ribs form a spiral) then the air will have a lot of trouble flowing through this duct, generally facing twice as much resistance as through a smooth, rigid metal duct. Then elbows or curves. Every curve slows down the air -- the tighter the curve, the more it slows it down. We call all of this "equivalent duct lengths" -- how long the duct appears to be to the fan, compared to a smooth straight duct. So if you use flexible ducting with a rough inside and snake it around rafters and other obstructions, you could end up with little or no air coming out the other end. Of course that rough flexible ductwork is what is generally sold with DIY units, because it is inexpensive and easy to install. But it reduces the air flow significantly compared to a professional installation with smooth, rigid ductwork.
The quiet fans that we looked at in this segment were made by Air King.