I am puzzled by your problem, so I'll make some suggestions and questions rather than give a definitive answer.
First, are you absolutely sure that the problem is interference, rather than simply a weak signal caused by a location with poor reception at your dock? With digital TV, it is essentially impossible to tell the difference simply by looking at the screen -- both circumstances (as well as multipath "ghosts" and other issues) will lead to image break-up or disappearance, and when you are near the threshold of reception, a VERY small change in signal conditions changes an essentially perfect image to an unwatchable one. This question matters because its answer directs the search for solutions. The fact that your TV works at home does not say whether its working was absence of interference or presence of a stronger signal. A stronger signal at home might overcome interference whose level is low enough to disrupt reception of a weaker signal (such as your boat's antenna at your dock might generate).
Second, I thought the TV in the boat worked on 12Vdc, so I'm puzzled by your extension cord at home. I assume you mean that you plugged the boat's 120Vac input into an outlet in your home. Assuming I am right that the TV works on 12Vdc, have you tried it with the boat disconnected from shore power and with the boat's inverter OFF? If the TV works on the boat's 12Vdc supply, then I don't understand why switching between the inverter or shore power would make a difference -- unless the interference comes from a device that is powered only from the shore power, such as the air conditioning.
If the interference is generated on the boat, I would have thought the inverter was more likely to do so than shore power, since the inverter uses some switching circuits that might generate RF. If you are certain the the problem is interference associated with the shore power, then you need to look for one of the devices other than the TV that is plugged into the shore power. Is the microwave off? What about the air conditioner and its water pump? Unplug or turn off anything that might be using the 120Vac. If the problem persists after all your 120Vac devices are OFF, then look elsewhere on your dock. Persuade your neighbors to turn off suspect devices. Find out if anyone is using a WiFi device with an amplified transmitted signal -- if that is close to your TV antenna, it could cause problems. Are there any other transmitters nearby (a local FM station, perhaps)?
You also should try switching off all 12Vdc devices on the boat, especially including the GPS and the VHF radio.
What channels do you think are available at your dock location? Do all of them fail in the same way? The channel numbers may give some guidance to the interference frequency and thus the source, but this is a long shot.
Your report that the sound is good even though the picture is not is also puzzling. Unlike our former analog television system, digital television does not transmit the audio data in a way that is significantly more robust than the video data. Normally, digital TV picture and sound fail at almost exactly the same signal conditions. If your sound is truly solid, it indicates to me that you are very close to a signal level that would allow the video to operate as well.
Let us know.
-- John H