When you swing a boat's compass, also known as "swinging ship," you're establishing the degree to which the compass is "off." A compass detects and points to the magnetic north pole. That's called magnetic variation. Compass deviation is the extent to which the compass is affected by the magnetic influence of things aboard the boat itself, like your radio or a wrench laying next to the compass. By having a record of your boat's compass deviation next to your compass, you may avoid some navigational errors.
Launch the boat on a calm day in a place where there's room to cruise for a mile north, a mile east, a mile south and a mile west, undisturbed. Tell the marina staff that you will "swing ship" to calibrate your compass, but that you will stay out of the way as much as possible. Once the boat is launched, turn on the GPS and switch the display to the "Compass" mode, to show the true heading.
Steer north, on a heading of 000-degress, according to the magnetic compass. Stay on this course for at least 10 knots, long enough to record the heading indicated on the GPS display. Turn to the east and steady the boat on a heading of 045-degrees using the compass. Continue on this course long enough to record, as before, the course indicated on the display of the GPS.
Turn east to a heading of 090 degrees by the compass and steer this course for long enough to record the course displayed on the GPS. Turn southeasterly to a course of 135 degrees by the compass and again, maintain this heading long enough to record the GPS. Turn south and steer a course of 180 degrees by the compass long enough to record this reading.
Turn southwesterly to a heading of 225 degrees, southwest, by the compass, and maintain this course long enough to record the GPS reading. Turn westerly and steady up on a heading of 270 degrees long enough to record the heading displayed on the GPS. Turn northwesterly to a heading of 315 degrees and, as before, steer this heading long enough to record the heading shown on the GPS.
Record, on the compass card next to the magnetic heading shown on the compass for "North - 000 degrees," the heading shown on the GPS while the boat proceeded north. Record the GPS readings for each of the cardinal and intercardinal points of the compass you steered as well. Post the compass card next to the boat's compass.
At 10 knots, it takes six minutes to travel one mile; if you have an isolated cove that's about 1/3 mile on each side, you should have plenty of room.
Keep a good watch while swinging ship. Although you are a vessel-not-under-command while doing so, if you hit something, you're partially to blame. If you're boat is large enough to fly the code flag "Oscar" over the code flag "Quebec," do so.