It happened at about 10:15 a.m. at a crossing at Railroad Avenue and Frowein Road.
The train was bound for New York City.
The victim's identity has not yet been released.
Service was suspended in both directions on the Montauk Branch between Montauk and Patchogue due to the accident, but has now been restored.