In the late 1990s, the medication used to treat HIV-positive patients improved significantly with the introduction of a new “cocktail” of drugs used to slow the development of the illness. This opened the way for new research: Shortly after this new kind of antiretroviral treatment became available, Gail Ironson, a professor of psychology at the University of Miami, recruited patients for a longitudinal study on HIV, and was later joined by Heidemarie Kremer, a former AIDS activist and researcher at Florida International University and University of Miami. Every six months during the first half of the study, participants would answer questions, write essays, and participate in interviews. Most of them were on medication when the study began, and that number went up as the study went on. Ironson said she and her team controlled for this kind of variation, along with other factors like demographics and substance abuse.

The researchers looked for qualitative signs that the participants were thinking or acting in religious or spiritual ways—mentions of God or prayer, for example. One patient “spoke about going back to church to help other people who had HIV who were basically under cover,” Ironson said. “She felt chosen by God and found meaning in HIV, feeling that she had gotten HIV in order to help others.” Another said he felt “he had gotten HIV so that God could get him to pay attention and change his lifestyle.” These are examples of what Ironson called “positive spiritual reframing”—people finding a way of thinking about their situation more positively using the language of spirituality. Roughly one-fifth of those in the study seemed to use this technique, and the survival rate among these people was about four times that of other participants. This was just one of 17 different forms of spirituality and religiosity that the researchers looked for.

Because this is a qualitative study, a lot of interpretation was involved in getting the results, like listening for certain phrases and coding them a certain way. For spiritual reframing to be coded, for example, the participants’ reasons had to involve God or the divine; they couldn’t just be generically positive. That’s one major limitation of the study: It’s not clear whether non-spiritual, non-theistic, equally positive mindsets would lead to the same survival rates.

It’s also difficult to claim that certain spiritual views and practices cause people to live longer. In a previous study, Ironson and her colleagues looked at how HIV-positive patients viewed God—as benevolent, loving, and merciful, or as harsh, judgmental and punishing. Although the researchers found that people with a positive view of God had significantly slower disease progression, “the true nature of God is clearly beyond the scope of this article,” Ironson wrote. “While our finding that view of God predicts disease progression is noteworthy, it does not imply that view of God causes disease progression.”