A study analysing 38 million obituaries has revealed the things people believe constitute a good life