Preprocessing of the titanic dataset