Tsunami warnings for Cuba, Honduras, the Cayman Islands, Puerto Rico and the Virgin Islands have been cancelled after an earthquake hit the Caribbean Sea.