NEW YORK — A judge in New York City has thrown out a lawsuit challenging federal laws criminalizing marijuana.

U.S. District Judge Alvin Hellerstein ruled on Monday that the five plaintiffs had failed to pursue changes in the drug’s legal status by first going through the Drug Enforcement Administration.

Hellerstein did not address their claim that marijuana has medical benefits, but said the DEA has the authority to make that decision and not the courts.

Government lawyers had argued there were logical reasons to classify marijuana as a dangerous drug under federal law.

The plaintiffs included former NFL player Marvin Washington, co-founder of a company that sells hemp-based sports products. They claimed that classifying marijuana as a dangerous drug is irrational and unconstitutional.

Lawyers for the plaintiffs said they would appeal the decision.