President Trump invoked “racism, bigotry and white supremacism” in his speech Monday about the mass shootings in El Paso and Dayton, Ohio. That’s a step he has resisted taking in the past when perpetrators of violence have demonstrated those characteristics, so it was notable.

But the bulk of his comments suggested the hateful ideology described in the El Paso shooter’s alleged online screed was merely a byproduct of other things — with mental illness being chief among them. “If you look at both of these cases, this is mental illness,” he said Sunday. “These are really people that are very, very seriously mentally ill.”

This is part of a demonstrated pattern for Trump, but it’s one that often gets ahead of the evidence. And there is one conspicuous instance in which the pattern doesn’t hold: when the perpetrator of such atrocities is Muslim.

After at least nine high-profile or mass shootings, Trump has quickly pointed the finger at mental health. Here’s a recap of seven others, besides El Paso and Dayton:

  • New Zealand (March): “I think it’s a small group of people that have very, very serious problems. I guess if you look at what happened in New Zealand, perhaps that’s the case. I don’t know enough about it yet.”
  • Thousand Oaks, Calif. (November): “He was a very, very mentally ill person. He’s a very sick — well, it’s a mental health problem. He is a very sick puppy. He was a very, very sick guy."
  • Parkland, Fla. (February 2018): “This person that did this horrible act — he was mentally deranged and everyone knew it for a long period of time. I guess they had 38 red flags, 39 red flags.”
  • Sutherland Springs, Tex. (November 2017): “I think that mental health is your problem here. This was a very — based on preliminary reports — very deranged individual."
  • Oregon (October 2015): “It sounds like another mental health problem. So many of these people, they’re coming out of the woodwork. We have to really get to the bottom of it.”
  • Roanoke (August 2015): “In this case, it was pure mental health . . . Every place he worked he had problems. And very severe problems. And yet nobody comes out and reports him.”

In some of these cases, obvious red flags did emerge shortly after the gunman was identified. In others, Trump appeared to be speculating, at best.

The link between mental illness and mass shootings isn’t as firm and frequent as Trump indicates. One study from a psychiatrist at Columbia University found 22 percent of mass shooters across 235 incidents had mental illnesses. That’s a significant number, certainly, but it doesn’t account for the vast majority of mass shootings. And the link between mental illness and gun violence broadly is even more tenuous.

The American Psychological Association weighed in on Monday in a statement: “Routinely blaming mass shootings on mental illness is unfounded and stigmatizing . . . The rates of mental illness are roughly the same around the world, yet other countries are not experiencing these traumatic events as often as we face them."

To Trump’s critics, talking about mental illness is a way for him to avoid thornier issues. Those include gun control and the potential radicalization associated with his own rhetoric, which includes his recent racist tweets urging four nonwhite congresswomen to “go back” to their countries.

And there is some evidence that this is precisely what Trump is doing. That’s because, while Trump makes a point of invoking mental illness when it comes to large-scale tragedies, there is one instance in which he has never done it. And that’s when he’s talking about tragedies perpetrated by Muslims. In those cases, a hateful ideology isn’t a byproduct of existing mental issues; the ideology is the cause, full stop.

Trump has not made the kind of comments you see above when it comes to Sri Lanka, Paris, Manchester, Brussels or any other international tragedy perpetrated by Muslims. Nor has he done so when the attacks were domestic, such as in New York City, Orlando, San Bernardino, Calif., Boston and Fort Hood, Tex. About the only time he has alluded to mental issues with Muslim terrorists was in May, when he called the Islamic State “stone-cold crazy” and “nuts” and urged people to be on the lookout for its adherents.

A case in point is his big terrorism speech in August 2016. During it, he mentioned the Fort Hood shooter, Nidal Hassan.

“The Fort Hood shooter delivered a presentation to a room full of mental health experts before the attacks in which he threw out one red flag after another,” Trump said, referring to a slide show Hassan delivered to fellow Army physicians in 2007. “He even proclaimed that, ‘We love death more than you love life.’ Not good. These warning signs were ignored because political correctness has replaced common sense in our society.”

But were these “warning signs” like the mental-health “red flags” above? Nope. Even after talking about Hassan speaking to “mental health experts,” Trump never flagged Hassan as having some kind of illness. He argued that these “warning signs” pertained to Hassan’s ideology rather than his mental state. And he proposed a commission to study Islamic radicalization, not mental health.

By the end of that speech, Trump did allude to one person’s mental health. It was Hillary Clinton, who Trump said “lacks the mental and physical stamina to take on ISIS,” referring to the Islamic State by another name.