John King Jr., now U.S. Education Secretary, congratulates a student for improving his attendance at D.C.’s Patterson Elementary in October 2015. King was deputy education secretary at the time. Also present were Ward 8 council member LaRuby May, left, then-Education Arne Duncan and Secretary of Housing and Urban Development Julian Castro. (Evelyn Hockstein/For The Washington Post)

The nation’s public schools suspended significantly fewer students in 2014 than they did in 2012, according to new federal data released Tuesday, but stark racial gaps persisted — not only in the way students were disciplined but also in their access to experienced teachers and advanced math and science courses.

Nationwide, 2.8 million students were suspended from public schools during the 2013-2014 school year, according to the Civil Rights Data Collection, which the U.S. Education Department releases every two years. That represents a drop of nearly 20 percent compared to the 2011-2012 school year.

But black students were nearly four times as likely to be suspended as white students, and nearly twice as likely to be expelled. The same pattern showed up in preschool: Black children represented 19 percent of all preschoolers but accounted for 47 percent of those who received suspensions.

“Fewer suspensions is an important sign of progress,” said Education Secretary John B. King Jr. “But I don’t think there’s any way you can look at this data and not come away with a tremendous sense of urgency about continuing to close our equity gaps.”

The Education Department has gathered and published civil rights data on public schools every two years since 1968. The figures released Tuesday were not estimates but a representation of more than 50 million students’ actual experiences, drawn from a survey of nearly every one of the nation’s 95,000 public schools.

They show that even as the nation’s high school graduation rate has risen, many students lack access to college-preparatory classes in math and science. Just 48 percent of the nation’s high schools offer calculus, for example, and the proportion is even lower — 33 percent — among schools with predominantly black and Hispanic populations.

“We in this nation do not offer high-rigor coursework to all students across the board,” said Catherine Lhamon, assistant secretary for civil rights.

Aside from detailing disparities by race, the data collection also offered the first federal count of the numbers of children who are chronically absent from class, putting them at a greater risk of academic failure and dropping out.

More than 6.5 million students, or 13 percent of all public school students, missed 15 or more school days in the 2013-2014 school year. And teenagers are not the only students missing class: More than 3.5 million of the chronically absent students were in elementary school.

King said the new federal education law, the Every Student Succeeds Act, could help spur progress. The law allows states to hold schools accountable not only for test scores but also for performance on other measures — such as rates of absenteeism and discipline.

Also for the first time, the survey gathered information about sworn law enforcement officers in schools, whose interactions with students have drawn scrutiny in recent months amid the broader public debate about policing.

Twenty-four percent of the nation’s elementary schools and 42 percent of high schools have such officers. Among high schools with high black and Hispanic enrollment, more than half — 51 percent — have sworn law enforcement officers.

And approximately 1.6 million students attend a school that has an officer on campus but no school counselor.

The new data also show that despite the Obama administration’s push for more public preschool, more than 40 percent of U.S. school districts still do not offer preschool programs.

And students with disabilities are more likely to be physically restrained or secluded than others, according to the data. They also are more than twice as likely to be suspended.

GreatSchools, a website that aims to give parents a snapshot of public schools through test scores, demographics and reviews, announced Tuesday that it would begin including the federal civil rights data in its school profiles.

Activists have long pushed back against schools’ use of suspensions, which have been linked to higher dropout rates and a greater likelihood of entering the criminal justice system. They also are costly: UCLA’s Civil Rights Project last week estimated that suspensions of 10th graders lead to an additional 67,000 dropouts each year, which costs taxpayers billions of dollars because of lost tax revenue and social services.

The Obama administration began a high-profile push to reduce disparities in suspension rates in early 2014, in the middle of the 2013-2014 school year. Lhamon predicted that the results of that effort likely will not be fully known until two years from now, when the 2015-2016 Civil Rights Data Collection is published.