Andrzej Wajda, Poland's best-known movie director, has been fired by the government from his post as head of the prominent Warsaw film group, Zespol X. The authorities charged Wajda, whose films include "Man of Marble" and "Man of Iron," with misguided leadership and too much time spent out of Poland.

The dismissal, disclosed today, comes amid a toughened line by communist officials against the country's key cultural associations. Many of the members of these groups were once closely associated with the banned Solidarity trade union.

Last month the 12,000-member artists' union was suspended for refusing to recant resolutions supporting Solidarity, criticizing the government for actions against other cultural bodies and appealing for a general amnesty for political prisoners.

In the meantime, negotiations between authorities and leaders of the filmmakers' and writers' unions about reactivating those associations, which were suspended with the declaration of martial law in December 1981, have been deadlocked for weeks over a government demand that some leaders be purged and that the unions pledge loyalty to the communist system. Wajda chairs the filmmakers' union.

Two other former hotbeds of Solidarity supporters, the journalists' and students' associations, were dissolved under martial law and reconstituted in tamer forms.

Announcing the ouster of Wajda and two of his close associates from the film group, government spokesman Jerzy Urban accused the studio under Wajda's leadership of demonstrating "a significant concentration of activities inconsistent with the cultural policies of a socialist state."

He said "a significant number" of films produced by the group, which includes some of Poland's most outstanding directors, were not suitable for distribution in Poland. "This does not mean the film group itself will be dissolved," he explained. "This only means a change in its leadership."

The associates fired with Wajda were the literary director Boleslaw Michalek and managing director Barbara Pec-Slesicka.

"This decision is very hostile to us and hurts and pains the members of the film group," said Pec-Slesicka, who has managed the studio for 11 years, in a phone interview. "I do not know what will happen to the group. I feel now as if my children have been taken from me to an orphanage."

Wajda himself is currently out of the country working on a film and was reportedly notified by telex at the end of last week of the government's action against him.

Urban said a second factor in the decision to dismiss Wajda was the substantial amount of time the 57-year-old filmmaker has been spending abroad in recent months. Wajda was in France for a good part of 1982 filming his latest release "Danton," and is now in West Germany directing a love story.

Though Wajda has won a number of international film awards, most of his pictures have been taken off the Polish market. His talent for incisive political storytelling has made authorities wary of him.