This is one in a series of profiles showcasing some of Harvard’s stellar graduates.

Viridiana Rios is a proud chilanga, or native of Mexico City. She spent her youth traversing her working-class neighborhood on bicycle, just like any other kid. But she was not just any other kid. Rios was preternaturally clever and earned scholarships to the city’s prestigious private schools. “There,” she said, “I became very aware of income inequality.”

She studied political science at the Instituto Tecnológico Autónomo de México. Afterward, she took a job with the Ministry of Social Development and noticed that much of the country’s crime was pointed at Mexico’s poorest people. “It seemed counterintuitive,” she said. “Why weren’t the wealthy being impacted?”

Rios, a graduating doctoral student in the Graduate School of Arts and Sciences’ Department of Government, also is an adviser to Mexico’s minister of finance, with an office overlooking the historic Mexico City Zócalo. She wears pearl necklaces to perform a job that melds traditional economics with matters of Mexico’s headline-making security, including crime, extortion, and narcotrafficking.

“My motivation has always been to change my country,” she said.

Harvard presented a set of problems different from those Rios was used to — including English. “It was hard to have a social life, to date, to be in a bar and converse and understand the jokes,” she said. But her adviser, Jorge Dominguez, the Antonio Madero Professor for the Study of Mexico, encouraged her to think in English and truly immerse herself. Finally, she was able to get those jokes.

She was also able to get ahead.

“I had the idea of studying organized crime,” she said. “Back then, it was not a topic anyone was paying attention to. But in the middle of my dissertation, as I was looking for the dataset on drug-related murders, I couldn’t find one. I knew two groups had that information: the government, which would never give me the data, and journalists.”

She turned to the nearby Nieman Foundation, where she met fellows Alfredo Corchado and Monica Campbell. “I said, ‘Alfredo, please take me with you to the border,’” she recalled.

Their trip was one of many she’d make to Matamoros, Tijuana, Juárez, Nogales, Mexicali, and Reynosa, which would present Rios with both danger from cartels — which knew her agenda and whereabouts — and bigger ideas.

Rios garnered international attention for an algorithm — devised with Michele Coscia, a fellow at Google and at the Harvard Kennedy School’s Center for International Development — that employs Google to track cartel activity.

“I never thought I would be using math to help Mexico,” said Rios, who calls Harvard the most gratifying intellectual experience she has had. “When my parents told my neighborhood friends I was going to Harvard, they didn’t believe it! They thought I was pregnant and left the city to not shame my family,” she said with a laugh.

Rios is happiest in Mexico City, working to make her country a better place. “I’m an idealist, and I believe change is possible. Even if one little thing is changed, it will have been worth it.”

But if she ever needs a reminder of why she pursued this work, Rios recalls that research trip to Ciudad Juárez, where she said she was forced to flee as threatening cartel members closed in. “I was with Monica, and we called the U.S. Embassy for help and they said, ‘We can help Monica, but we can’t help Viridiana. She is Mexican,’ ” she said. “So I called Jorge, and I said, ‘Just stay on the phone with me while we take this taxi to the border.’ ”

Rios and Campbell made it safely to El Paso, Texas, where they checked into a hotel. “It was the Fourth of July, and the next day we’d fly back to Cambridge,” Rios said.

“That night, I looked out of my hotel window, and on one side I saw fireworks in El Paso, and on the other side was my Mexico. And it was so unfair.”

The path to fighting injustice