Essays on the Endogeneity of Preferences and Personality Traits