Community factors influence how long you’ll live, study shows