Women and men with certain types of cancer appear to take very different approaches in deciding how to treat their disease, a new study of social media found.

The study, commissioned by Memorial Sloan Kettering Cancer Center in New York, analyzed thousands of Internet posts in leading cancer forums and other online communities. Men with prostate cancer were generally found to be analytical, methodical and data-driven in assessing their options. They sought out the latest scientific studies and outcomes research, and tended to obtain several doctors’ opinions.

By contrast, women with breast cancer were typically distrustful of scientific data and even of their own physicians. Anxious that their cancer might return—and viewing any risk of recurrence, however small, as too great—many women favored aggressive treatment such as double mastectomy.

Men with prostate cancer typically make decisions “deeply situated in science,” the study concluded. For breast-cancer patients, the online narratives, advice and anecdotes they heard from other women tended to “displace the voice of science and medical experts,” according to the study, which was performed by Treato, a health-care data-analytics firm with offices in Israel and New Jersey.

Jim Kiefert leads a support group for prostate-cancer patients in Olympia, Wash. Most of the men he encounters ‘analytically look at what their options are and study the side effects of each of the treatments,’ he says. Photo: Jim Kiefert

The findings have revived old controversies about gender differences and the dangers of playing into stereotypes, in this case the thoughtful, deliberative male versus the anxious and emotional female. Also, the study, part of a fast-growing field of analyzing data from social media, is by no means traditional academic research, with its emphasis on randomized trials and peer reviews. It was directed by Sloan-Kettering’s marketing arm, not its medical arm.

Sloan-Kettering is hoping the analysis will help it grapple with the growing role social media and online support groups play in guiding people on how to make decisions on cancer care. The hospital also expects the study will help it understand how patients speak and think about their cancers, so as to be better attuned to their needs.

Ido Hadari, Treato’s chief executive officer, points to the existence of a “parallel universe” online, where increasing numbers of patients engage with each other and seek advice on their medical conditions. It is now possible, he said, “to collect this massive amount of conversation” and shed light on “the human angle, the feelings, the decisions” that drive a cancer patient.

Vanessa Baker, of River Vale, N.J., says an online support group offered psychological sustenance and was influential in her decision to have a double mastectomy for Stage 1 breast cancer. ‘A lot of the doctors who are treating you haven’t had cancer,’ Ms. Baker says. Photo: Vanessa Baker

While gender differences in prostate- and breast-cancer populations were stark, Mr. Hadari noted that other diseases his firm is studying, such as lung cancer and lymphoma, don’t elicit significant differences in how men and women cope. That is a reflection of the personal nature of breast and prostate cancers, he believes, where the loss of sexual identity is at stake.

Men with prostate cancer face treatments that can cause side effects such as impotence and incontinence that challenge their sense of masculinity. Women with breast cancer may worry if they will remain attractive and feminine, and many opt for breast reconstruction after mastectomy. They cope very differently, Mr. Hadari said. While not always the case, women appear to take “a much more emotional approach” and opt for fast, aggressive solutions while men carefully weigh their options, he said.

Jim Kiefert, 77, a retired educator who belongs to Us Too, a Chicago nonprofit that runs a network of support groups for prostate-cancer patients, says the study’s findings about men staying calm and methodical in the face of a diagnosis rings true.

“There are the men who are emotional about it—it is, ‘Oh my God I have cancer, get it out,’ and they usually opt for surgery,” says Mr. Kiefert, who leads a support group in Olympia, Wash. But most of the men he encounters take a more systematic approach and “will analytically look at what their options are and study the side effects of each of the treatments,” including surgery, radiation or active surveillance. Mr. Kiefert has lived with metastatic cancer since being diagnosed with prostate cancer 26 years ago.

Nancy Touhill, of Charleston, S.C., says she went online after her breast-cancer diagnosis and experienced firsthand the pressure from other women to pursue aggressive surgical options. ‘I do think the prevailing thought in all of these groups is chop them off,’ she says. Photo: Nancy Touhill

Some traditional researchers are critical of the study’s conclusions, saying there is greater variability within the ranks of men and women than between the sexes. “To call women emotional and men analytical, that is 40 years of dusty nothing,” said Dr. Steven Katz, a researcher at the University of Michigan who studies how cancer patients make treatment decisions. He worries that drawing conclusions about gender differences could prompt doctors to treat men and women differently, perhaps offering a woman less data. “There can be small differences between genders—I am not going to say there are none—but this can’t be a factor in how doctors treat patients,” he said.

Dr. Michael Diefenbach, a research psychologist who works with prostate-cancer patients at North Shore-LIJ Health System in New York, questioned whether the study was representative of men with the disease, since older men may not go online and air their feelings.

Similarly, breast-cancer patients who appear in online forums may also be a “biased sample,” since women who vent online tend to be more anxious about their cancers, says Dr. Suzanne Miller, a psychologist and professor at Fox Chase Cancer Center in Philadelphia. In terms of women’s apparent distrust of doctors and the scientific community, she said, “Women generally have a poor history in the medical profession—they don’t feel they are as respected,” and “they look more to their peers.”

Treato officials say they performed a comprehensive analysis of social media for both diseases to obtain representative samples. In the case of prostate cancer, there were men from their 40s to their mid-60s and even older who posted online and sought advice from Internet communities, Treato said. The company identified nearly 72,000 prostate-cancer-related posts from 2012 to 2014. Of these, 1,339 were pulled for close reading and 633 were chosen for analysis, since they dealt specifically with how men decided on treatment.

For breast cancer, analysts identified 642,052 posts from online forums such as Breastcancer.org and Cancer-Forums.net from 2012 to 2014. They culled 3,585 posts for review then narrowed the field to 806 posts directly involving women’s decision-making about their treatment, including breast-sparing lumpectomy with radiation, single mastectomy or double mastectomy.

Vanessa Baker, 43, a mother of three small children in River Vale, N.J., says an online support group offered psychological sustenance and was influential in her decision to have a double mastectomy for Stage 1 breast cancer. Although she had in-depth conversations with her doctors, “I definitely took what the girls said in the support groups very seriously, because a lot of the doctors who are treating you haven’t had cancer,” said Ms. Baker.

Nancy Touhill, 34, an events planner from Charleston, S.C., went online after her breast-cancer diagnosis and says she experienced firsthand the pressure from other women to pursue aggressive surgical options. “I do think the prevailing thought in all of these groups is chop them off,” she said. Ms. Touhill says she deliberated a great deal, checked out different studies, then went with her doctors’ recommendation: conservative lumpectomy along with chemotherapy and radiation.

Dr. Deanna Attai, a breast surgeon at UCLA Health in Los Angeles, who co-moderates an online breast-cancer group, says the study should be a wake-up call to physicians to venture onto social media and be part of their patients’ world.

“It really would be helpful to these patient communities to have a physician voice,” Dr. Attai said. The doctors could then dispel the “myths” being circulated. “If a patient is told a bilateral mastectomy is safer, a physician can put out the information that it is not necessary.”

Write to Lucette Lagnado at lucette.lagnado@wsj.com