A political dispute over who will operate on the ex-shah of Iran -- American or Panamanian doctors -- delayed final arrangements yesterday for removal of his possibly cancerous spleen.

Panamanian doctors, with their government's support, insisted that Panamanian doctors "must be in charge" and "will do the operating."

The Panamanian government and medical community feel their nation will look like a U.S. stooge if American doctors are in charge at the operating table, sources said. The Panamanian government has already been under fire from left wing critics for admitting the exiled shah at the administration's urging.

In Houston, however, Dr. Michael DeBakey, Baylor University heart and blood vessel surgeon, said he will go to Panama to see the shah "in the next few days" and -- if he agrees surgery is needed -- will summon his team and do the operating.

In New York, the shah's spokesmen would not comment. Other sources said the matter has not been settled but will be, they hope, so the operation can take place within days.

"The negotiations are still going on," one source said. "It's gotten very political."

DeBakey will be welcome as a comsultant in the operating room, Panamanians said. Though best known as a cardiovascular expert, he has had extensive general surgical experience.

The shah has had bleeding problems in some past operations, and this makes a vascular of blood vessel surgeon's presence desirable, sources said. The spleen -- the organ in the abdomen that probably must be removed -- is a swollen sacful of blood in its present condition.

Arrangements for the surgery are being made at Paitilla Hospital in Panama City. The shah was treated in New York last fall for lymph gland cancer and gall bladder disease.

He went to Panama in December. Tuesday, Dr. Benjamin Kean, his main American doctor, said the shah now has a massively enlarged spleen and severe anemia -- probably caused by spread of his lymph gland cancer, though there are other possible causes too.