10 U.S.C. § 8166
Precedence accorded commanding officers
The commanding officer of a vessel or of a naval station takes precedence over all officers under his command.
The commanding officer of a vessel or of a naval station takes precedence over all officers under his command.