The man was being evaluated at Nassau University Medical Center in East Meadow.
State Park Police identified him as Pablo Perez, a 47-year-old resident of Flushing, Queens.
Police say a jogger encountered Perez on the boardwalk at about 6:15 a.m. Tuesday, wearing a wet suit under his clothes.
They say Perez told first responders he was carrying a gun. Police seized the gun and discovered it was loaded.
A 9-foot raft was found along the shore. The U.S. Coast Guard told police it had no reports of a missing fishing boat.