Deviation is the error in reading a bearing from the compass caused by the magnetic influence of some nearby object, such as a metal post or a car parked beside you. In the case of boats it may even be due to the materials from which the boat is constructed. Electric currents close to the compass will affect its behaviour. To avoid this type of error the compass should be kept away from all such influences. Most boats have some measure of deviation which should be minimised by careful mounting of the compass.
Deviation changes each time the boat alters course.
There are people skilled in compass adjustment who can issue a card for a particular compass with deviations listed for changes in direction. For a magnetic compass, the needle will point towards magnetic north rather than true north. At the equator the lines of magnetic force will be almost parallel to the earth's surface but as you move towards the poles they will be increasingly angled toward the surface giving the compass needle more 'dip'. In reality what happens to the compass needle is that it becomes unstable, wanting to dip a great deal but unable to do so. Compasses are specific and pre-set for whichever hemisphere they are to be used in.