Replacing a ballast of the same type (3 lamp with 3 lamp, parallel with parallel) is fairly simple. The wiring connections and colors match up.
Replace 3 Lamp Parallel Ballast Wiring Diagrams
After 3 Lamp Ballast is Replaced
Replace 3 Lamp Parallel Ballast with 4 Lamp Parallel Ballast
In this example, a fixture with a 3 lamp parallel ballast is replaced with a 4 lamp parallel ballast. The colors of the old and new ballasts do not match. This replacement can be difficult to do unless a person totally understands how this wiring works.
A 3 lamp parallel ballast can be replaced with a 4 lamp parallel ballast. The two yellow wires on a 4 lamp ballast are connected together inside the ballast.
Cut and cap one yellow and one red or blue wire with a wire nut.
Connect each of the blue ballast wires to the each of the two blue lampholder wires.
Connect the red ballast wire to the third blue lampholder wire.
Connect the yellow ballast wire to the red lampholder wire.