A mass shooting at a bar in the Los Angeles-area suburb of Thousand Oaks has left 13 people dead, including a police sergeant and the shooter.

Recently, researchers from the University of Toledo in Ohio analyzed 155 mass shootings that occurred in the US to investigate trends and risk factors.

They found a few clear patterns. Their results suggested that communities with better access to mental-health services had less risk of a mass shooting.

While not all gun laws made a difference, two were associated with lower risk of a mass shooting: reporting of mental-health records in background checks, and restrictions on open carry .

Lead investigator Dr. Stephen Markowiak said the study was intended to highlight a holistic approach to reducing gun violence.

There have been 307 mass shootings in the US so far in 2018.

On Wednesday, a 28-year-old Marine veteran opened fire inside the Borderline Bar & Grill in Thousand Oaks, California, a Los Angeles-area suburb. Thirteen people are dead, including a police officer, Sgt. Ron Helus, and the shooter, Ian David Long, who killed himself. Up to 15 other people were injured and taken to hospitals.

Because these deadly events have become so common in the US, a team of researchers from the University of Toledo in Ohio set out to look for patterns or similarities among communities that have dealt with a mass shooting.

Read more: At least 13 dead, including gunman, at college-bar mass shooting in Los Angeles suburb of Thousand Oaks

They looked at 155 mass shootings in the US (defined as an event with four or more fatalities, excluding the shooter). Their research, which was presented at the American College of Surgeons Clinical Congress last month, found several factors that are clearly associated with a higher risk of a mass shooting.

These include a shortage of mental-health professionals, a lack of opportunities for social interaction, greater income inequality, and relatively high housing costs.

Two common gun restriction laws were also found to be correlated with a lower incidence of mass shootings: a requirement that mental-health records get reported in criminal background checks, and restrictions on open carry firearms.

Mental-health care as prevention

Dr. Stephen Markowiak, a general surgery research fellow at the University of Toledo, led the study.

"From the clinician side of things, when somebody gets shot, we’re on the receiving end of that," Markowiak told Business Insider. "We have entire chapters in our textbooks dedicated to how to fix the problem once it happens, but there’s relatively little available to us on how to keep it from happening in the first place. That's such a shame in a world where people know prevention is more powerful than cure."

From their research, Markowiak's team concluded that access to mental-health resources is an extremely important factor when it comes to the risk of a mass shooting. Communities with more mental-health providers per capita saw lower rates of mass shootings in their analysis.

That finding is similar to that of a 2016 study, which suggested that states that spend more money on mental-health care and K-12 education have fewer school shootings.

Such evidence highlights healthcare providers' role in improving and protecting communities, Markowiak said.

Another important risk factor was a lack of socialization.

"If you look at communities where these events occurred, the average individual had 10.5 to 11 people that they commonly associate with compared with an average of 13 or so close associations in communities where they didn't occur," Markowiak noted in a release about the study.

For their study, Markowiak's team used data from the FBI, US Census, Centers for Disease Control (CDC), National Institutes of Health (NIH), and Robert Wood Johnson Foundation. Their analysis controlled for variables like population density, urbanicity, and the proportion of males ages 20-44 in the community.

Does gun control work?

The study's results suggest that not all gun laws are equal when it comes to lowering the risk of a mass shooting.

States with strict regulations, like New York and California, had high rates of mass shootings. But stricter gun laws were associated with less violent crime overall.

Plus, the results showed that fewer mass shootings occur in places where criminal background checks require reports on an individual's mental health. The same correlation held true for areas in which the open carry of firearms is restricted.

This study is the latest in a growing body of evidence that certain gun-control policies can reduce rates of gun violence.

This week, research presented at a conference of the American Academy of Pediatrics showed that in states with the most lenient gun regulations, twice as many kids die because of firearms compared with states where gun laws are strictest.

And last month, a first-of-its-kind analysis found that gun injuries sent 75,000 US children and teens to emergency rooms over nine years. The total cost: almost $3 billion.

'We could solve this problem if we wanted to'

Markowiak stressed that his team's conclusions were apolitical and only based on correlation, not causation. So he doesn't have recommendations about specific gun-control policies. But he said he hopes the results lead political and community leaders to prioritize community health across the nation and take a holistic approach to combatting mass shootings.

Markowiak noted, though, that he fears the sharp divisions within the American political landscape are stalling potential improvements.

"If we could be more honest with ourselves, and talk about things with less of a heated political sense, we might move past some of these issues," Markowiak said. "We have to be able to agree on the facts. That's what our project is — trying to kick-start a discussion and provide some evidence."

Another barrier to progress in reversing the mass-shooting trend, Markowiak added, is that organizations like the NIH, CDC, and Bureau of Alcohol, Tobacco, Firearms and Explosives — which are known for gathering data that informs policy making — have seen their ability to research gun violence restricted.

Indeed, the US spends less money researching gun violence than it does on almost any other leading cause of death. That's because of "incredibly poor leadership decisions" from lawmakers, Markowiak said.

"The reality is, we could solve this problem if we wanted to," he said. "We have these excellent resources available to our country that have a decades-old history of solving public-health crises."