Your house is set up for a fan with a light on itblack wire the fan you purchased seems to have no lightno black wire wire your fan red red white white green ground and cap the black wire. Each of these colors indicates the purpose of the wire whether for charging or data transfer.
16 Ga Four Conductor Duplex Wire Black White Red Green
Red black and green wires. Although the standard wire colors in the usb cable are red black white and green dont worry if that is not the case for your cable. The standard colors found on the inside of usb cables are red black white and green. Like black wires they can also be used in some types of switch legs. Attach the black wire to the outlet you want to always be on usually the top one and the red wire to the switched outlet. Also black wires are often used as switch legs in circuits which is the connection linking a switch to the electrical load. The different colors of electrical wires indicate the function of the wire with black and red indicating the wires carry electric current white usually indicating neutral charge and green indicating the wire is grounded.
While wires designated as hot black or red insulated wires carry power from the service panel breaker box to the device neutral wires carry power back to the service panel. In fact any color wire except white gray or green may be used in conduit to carry ungrounded power. The colors regulated by the national electrical code in the united states are standardized for safety. You can now screw the outlet to the box and proceed to the switch box. No wire with any of those colors can be used for establishing a ground or neutral connection. It is important to note that neutral wires may also be carrying power and can shock you.
Green wires connect to the grounding terminal in an outlet box and run to the ground bus bar in an electrical panel. Connect the white wire to either of the chrome screws remember they are still joined and the ground wire to the green ground screw. If you see a white wire marked with black or red or a piece of black or red electrical tape at its ends that means its acting as a hot wire and is no longer neutral. Thus both hot and neutral wires have the potential to shock and injure you. Four conductor speaker wire usually has a black green red and white or yellow wire. If the fan doesnt come on first make sure you have power then wire the red to the black and cap the red.
In 220 volt circuits red wires are the secondary live wires. Although there is no standard that we know of we have found that most contractors use the following logic. According to nec a black or red wire must be used as an ungrounded conductor or hot wire. Consider all black wires to be live at all times. Try the switch after you wire it up. Black and red wires.