His recently completed thesis on spirituality in New Zealand hospice care included interviews with 24 terminally ill patients.
He found that when people were dying spiritual questions naturally arose, such as "Who am I?", "What have I been doing?" and "What's going to happen to me?"
One of Mr Egan's impressions was that those who had thought about such issues well in advance of their terminal illness appeared to have an easier time dealing with their impending death.
Some people found their identity was challenged.
One patient interviewed said when a person had cancer they entered the cancer world and once there "you never leave.
"It affects who you are and what you do from there on."
The majority of people had spiritual needs related to ideas on the meaning of life, peace of mind, regret and fear.
"Why me?" was another question often asked, although Mr Egan said some people asked "Why not me?"
He was surprised by how many people felt guilt, which was a block to peace of mind.
When people talked about the need to get their affairs in order before dying, it was not just about financial matters, but also about addressing whatever it was that was preventing peace of mind.
It was not apparent that people suddenly found a belief in God while dying if they had not had one previously.
Rather, people tended to examine their beliefs and become more reflective.
In addition to interviews with patients, Mr Egan's research covered interviews with family members, staff, chaplains and Maori authorities, a survey of hospices and a literature review.
This work showed that two-thirds of people wanted spiritual care, but up to 30% did not want their spirituality to be addressed by hospice staff.
It also showed that about 70% of those involved with the survey believed in God and 79% in an afterlife.
More than 50% also believed in paranormal events, such as seeing dead relatives appear to them.
Mr Egan said he did not specifically ask about the paranormal in his research, but it was often mentioned.
The possible role of medication in these events was not explored.
It was also clear that most patients wanted or received spiritual care from family members, but this could be challenging if there was conflict between the patient's beliefs and those of family members.
Part of Mr Egan's research involved coming up with a definition of spirituality (see above).
He accepted that people's feelings on the issue ranged from regarding it as a total farce, at one end, to those who considered that spirituality involved the essence of what it meant to be human.
however, there was an increasing body of research showing a "fairly consistent positive association between spirituality and other health outcomes".
The range of feeling on the subject meant that people caring for the dying had to ensure that any spiritual care given was patient-led.
No-one should ever force their beliefs on anyone else.
It was not ethical, for instance, for staff to instigate prayer with a patient.
Some health practitioners inherently understood the need for spiritual needs to be addressed, Mr Egan said.
One such person was the late Dr Pat Farry.
"He told me he had been asking about spirituality for 20 years in general practice.
"If someone had a cancer or serious illness he would ask them 'How is this going to affect you spiritually?'."
Definition of spirituality
Spirituality means different things to different people. A working definition may include:
• One's ultimate beliefs and values
• A sense of meaning and purpose in life
• A sense of connectedness
• Identity and awareness
• Religion for some people