It’s disheartening to see the FBI used to promote a political agenda, but that’s what we got with the bureau’s release last month of a study claiming to show a sharp rise in mass shootings, a la Newtown, Conn.

The FBI counted 160 “mass” or “active” shootings in public places from 2000 to 2013. Worse, it said these attacks rose from just one in 2000 to 17 in 2013. Media outlets worldwide gave the “news” extensive coverage.

Too bad the study is remarkably shoddy — slicing the evidence to distort the results. In fact, mass public shootings have only risen ever so slightly over the last four decades.

While the FBI study discusses “mass shootings or killings,” its graphs were filled with cases that had nothing to do with mass killings. Of the 160 cases it counted, 32 involved a gun being fired without anyone being killed. Another 35 cases involved a single murder.

Three-quarters of the missing cases came in the first half of the study’s time period, thus again biasing the results toward finding a larger increase over time.

It’s hard to see how the FBI can count these incidents, which make up 42 percent of its 160 cases, as “mass killings.” They plainly don’t fit the FBI’s old definition, which required four or more murders, nor even its new one of at least three murders.

And these non-mass shootings, with zero or one person killed, drive much of the purported increase in the number of attacks. If you consider cases where no one or only one person was killed, 50 came in the last seven years of the period the FBI examined and only 17 during the first seven years.

For example, in 2010, the FBI reports that there were 29 of these active shooter cases, but just nine involved more than a single fatality.

The FBI study also ignored 20 out of what should have been a total of 113 cases where at least two people were killed.

For example, it missed a 2001 shooting at a Chicago bar that left two dead and 21 wounded, as well as a 2004 Columbus, Ohio, attack at a concert that left four dead.

Three-quarters of the missing cases came in the first half of the study’s time period, thus again biasing the results toward finding a larger increase over time.

Another trick was the choice of 2000 as the starting date. Everybody who has studied these attacks knows that 2000 and 2001 were unusually quiet years, with few mass shootings.

Thus, by starting with those years and padding the cases in later years with non-mass shooting attacks, the study’s authors knew perfectly well they would get the result they wanted.

The picture looks quite different if you use good data and a longer time period. Back in 2000, Bill Landes of the University of Chicago and I gathered data on mass public shootings from 1977 to 1999; I’ve now updated the database.

Our criteria were similar to what the FBI said it would follow: non-gang attacks in public places.

Shootings that were also part of some other crime, such as a robbery, were also excluded. But we counted cases where at least two people had been murdered in these public shootings.

Overall, there has been a slight increase in deaths from mass public shootings over these 38 years, but even then the upward trend largely depends on the single year 2012, when there were 91 deaths.

To be fair, the FBI study isn’t as shoddy as what Michael Bloom­berg’s Everytown has been pushing.

The group was greatly embarrassed after it first claimed that there had been 74 school shootings between the Newtown tragedy in December 2012 and the end of this past school year, but the true number of school attacks in which the shooter intended to commit mass murder turned out to be only a small fraction of that, just 10.

Similar to the FBI report, Bloom­berg’s group padded the numbers by classifying everything as a “Newtown type attack” — including when a Florida student defended himself with a gun from two attackers, a 40-year-old man committed suicide in a school parking lot at 2 a.m., and gang fights after hours.

But at least Bloom­berg is spending his own money to manufacture “evidence” to push his gun-control agenda. The politicization of the FBI and use of taxpayer dollars to scare Americans into supporting an agenda is far more disturbing.

John R. Lott Jr. is the president of the Crime Prevention Research Center and the author of “More Guns, Less Crime.”