President Donald Trump is fond of walls, cops, and anecdotes. But he’s savvy enough to like statistics, tooas long as they tell the right story.

“When you cook the books you shouldn’t pretend to be surprised by the results,” Tom Jawetz, the vice president for Immigration Policy at American Progress, a liberal think tank in Washington, D.C., told The New York Times in December. He was referring to the Alien Incarceration Report—a quarterly report on incarceration rates of immigrants, created by an executive order that Trump signed in January 2017.

According to the report, in the fiscal year 2017, one-fifth of federal prison inmates were foreign-born. Of those confirmed to be “aliens,” meaning non-citizens, over 90 percent were unlawfully present.

“Report reveals 92 percent of foreign nationals in federal prisons are illegal immigrants,” announced Fox News on December 21, 2017, the day the administration released the findings. A Breitbart headline reported the statistic as “nearly 95 percent.”

In the weeks that followed publication, right-wing media outlets and members of the Trump Administration used the statistics to argue that immigrants were dangerous criminals. But such reasoning misses the fact that many immigrants are incarcerated for immigration offenses, such as unlawfully entering or remaining in the U.S., which do not threaten public safety. In the early 2000s, immigration offenses accounted for 28 percent of federal arrests, according to the Pew Research Center. Today, the Center reported, the number is closer to 50 percent.

In fact, the argument is tautological: The reason for the high immigrant incarceration rate is that undocumented immigrants are incarcerated for being undocumented immigrants. Citing the high rate as proof that undocumented immigrants are more dangerous than citizens is illogical for two reasons: One, immigration offenses are not dangerous, and two, citizens—by definition—cannot commit the offenses that make up about half of federal arrests.

High immigrant incarceration is a product of developments in the U.S. law enforcement and justice systems over the past three decades. Immigration law and criminal law have become increasingly enmeshed, as Stanford law professor David Sklansky argues in his 2012 article, “Crime, Immigration, and Ad hoc Instrumentalism.” Sklansky describes “routine incarceration” as a “concrete practice that immigration law has imported from criminal law.” He calls the hybrid law “crimmigration.”

Far from an exercise in “transparency”—the administration’s stated reason for collecting the data—the Alien Incarceration Report is a recent case study in a centuries-old American tradition: the misuse of statistics to ascribe criminality to marginalized groups.

Over a century ago, Frederick L. Hoffman—a then-renowned American statistician—analyzed crime and incarceration data and concluded that black Americans were morally and biologically inferior to white Americans.

In his 2010 book, “Condemnation of Blackness,” Khalil Gibran Muhammad describes a practice in 19th-century American statistics of “writing crime into race.” He discusses Hoffman’s pioneering statistical studies of black crime and incarceration rates. From the high rates that he found, Hoffman concluded that black Americans were morally and biologically inferior to white Americans.

To be sure, the comparison between Hoffman’s studies and the Alien Incarceration Report is imperfect. The criminalization of blackness in the U.S. has taken the form of vagrancy laws, false accusations, and differential treatment by the authorities, including police and judges. The problem with Hoffman’s account was that he attributed high black crime rates to a supposedly innate criminality, when social and economic forces—such as racism, poor education, poor health care, poverty, and malnutrition—were the real culprits.

But, as Sklansky discusses in his article, studies have shown that immigrant populations today do not have higher violent crime rates than the general population. The statistical work behind the Alien Incarceration Report falls short in a fairly simple way: It disregards easily quantified factors, like how many incarcerated immigrants have committed crimes that only non-citizens can commit, such as unlawful presence, or misdemeanors less likely to be discovered or prosecuted if the offender were a citizen.

Still, Hoffman’s work and the report have clear parallels. Behind the inscription of crime into marginalized groups is the idea that exposing identity-based criminality is necessary for the well-being of American citizens. (That is, the chosen American citizens—white Americans in Hoffman’s case and, often, in the case of immigration, since racist sentiment often accompanies anti-immigrant sentiment.)

“Beginning with Hoffman,” Muhammad writes, many 19th-century white race-relations writers “wanted their fellow Americans to see the indisputable evidence of black criminality as the key to binding the nation together to keep the ‘negro’ in his place.”

Marginalizing black Americans for the sake of national unity is reminiscent of the rhetoric surrounding the “alien incarceration” statistics, which stressed imagined threats posed by immigrants to the nation. In both cases, the minority population was disproportionately incarcerated, and the high rates of incarceration were interpreted as indicative of an innate tendency toward higher criminality. Both accounts were alarmist, ignoring systemic reasons for the incarceration rates and instead spreading fears among Americans that natural criminals were in their midst.

“The simple fact is that any offense committed by a criminal alien is ultimately preventable,” Attorney General Jeff Sessions said in response to the publication of the Alien Incarceration Report. “One victim is too many.”

Sessions’ emphasis on victims is striking, since immigration offenses, which are responsible for the disproportionately high immigrant incarceration rate, are victimless. Secretary of Homeland Security Kirstjen Nielsen also pushed the Trump Administration’s immigration agenda in her statement.

“While the administration is working diligently to remove dangerous criminal aliens from our streets, this report highlights the fact that more must be done,” Nielsen said.

Articles responding to the report’s publication in right-wing media—like the ones published on Fox News and Breitbart, both of which quoted parts from Sessions and Nielsen’s statements—illuminate the ways in which “alien incarceration” statistics are being used to write crime into immigration.

The authors of the articles and the members of the administration assume that there is no categorical difference between immigration offenses and traditionally criminal crimes, like those connected to drugs, gangs, theft, and violence. Increasingly, that assumption is indeed aligned with the way law enforcement works in the U.S. But it is not a result or objective reflection of the way American law is changing. Rather, it is part of a positive feedback loop between the growth of “crimmigration law” and the conflation of immigration offenses and violent crime in public discourse.

Anti-immigrant sentiment is part of the loop, too. Implicit in the statement, “immigration is criminal”—which, operationally in the U.S. today, approaches the truth—is the statement, “immigrants are criminals.”

The shift toward “crimmigration law” began in earnest in the 1990s. A chart in Sklansky’s article shows that the average daily population in immigration detention from 1994 to 2009 increased from 6,800 to 33,800 detainees over the 15-year span. According to Sklansky, who calls the system of detention facilities “a parallel prison system,” immigration centers were the first American private prisons.

Though not all of these centers are included in the Alien Incarceration Report—an omission criticized by the administration’s opponents—the trend is represented in the facilities that were included. The Federal Bureau of Prisons and U.S. Marshals Service both hold large populations of immigrants, as do state prisons and local detention centers. Immigration offenses account for the presence of 7.2 percent of inmates under the Bureau’s jurisdiction. Under the U.S. Marshals Service, whose historic function is detainment, the “fastest-growing population…by far, is immigration offenders,” according to a Quartz Media investigation from June 2017.

“The increase accelerated in the mid-2000s, when the federal government was rapidly expanding the practice of charging people detained entering the country with misdemeanors, and those who reentered with felonies,” the Quartz article states.

When crime is written into identity, the stakes are high. The practical implication of inscription is disappearance—of undocumented immigrants by deportation and stricter immigration control, and of black Americans by mass incarceration.

Prophetically, the executive order that created the report predicted the conclusions that would be drawn from the data. Sanctuary jurisdictions, the order stated, “have caused immeasurable harm to the American people and to the very fabric of our Republic.” (By sanctuary jurisdictions, the order was referring to cities that do not comply with the federal mandate to disclose information with the government about immigrants’ citizenship or legal status.)

The creation of the Alien Incarceration Report was an exercise in induction from incomplete data. It was an attempt to confirm, through pseudo-scientific means, what the administration had already stated as truth, and to provide statistical support for an ideological conclusion.

Crime is also still being written into race. The rhetoric surrounding “law-and-order politics,” as journalists and scholars have noted, has taken on a racial subtext. The superpredator theory of the 1990s was an alarmist (and ultimately debunked) account of a rising cohort of violent American youths—the majority black—who supposedly posed a dire threat to public safety.

The use of statistics to write crime into race is an older American tradition than the writing of crime into immigration. The inscriptions are distinct—but they are also mutually informative.

“Many white race-relations writers hoped to blaze a research trail to solve the Negro Problem by writing crime into race,” Muhammad writes. “In the process, they also hoped to save the nation by using black criminality as a rhetorical bridge to heal deep sectional divisions and distrust rooted in the postbellum era. These writers saw vital racial statistics as a pathway to certainty and serenity.”

But attempts to disappear black Americans did not foster unity. They sowed divisions not yet mended after more than one hundred years.