To muddy the waters a bit further, there's a safety aspect to white lights along the shore, too.
Based on several instances of nearly needing to have somebody's bow surgically extracted

, it seems a bit difficult for some folks to tell the difference between a (white) stern light and somebody's (white) dock light.
Silver Duck