Well Magneto in the first two movies is MILES BETTER. I mean McKellan is an awesome actor and gives a brilliant performance. Machmon is a decent actor but Ian McKellan is on another level as one of the greatest British actors to ever live (see him play MacBeth or King Leer).
His Magneto is iconic and only second to Jack Nicholson's Joker in terms of movie villains (of superhero films). However, in the third X-Men movie he seemed rather bored. Only in his scenes with Patrick Stewart (who seemed equally bored in the non-McKellan scenes) did he liven up and give a stirring eccentric scene. But he seemed to know the script sucked this time and I doubt Ratner gave very good direction (he and Singer went back to Apt Pupil, another good performance for him) and other than that he only had second rate actors like Rodreguiez to work with as they steal his partner in crime (Rebecca Romjin) from him in this movie and betray a character relationship he built in the second.
However, with all the bumbling Ppenn and Ratner and Kinberg did with his character (almost ruining him) he still had an authenticity and a charisma at his most phone worthy send in. On the other hand Dr. Doom was screwed up from day one as a poor Green Goblin (comparetively he doesn't even match Willem Dafoe's brilliant and superb turn as the Green Goblin, which Kinberg copied and ripped off for his mediocre Fantastic Four script) with no depth or menace.
He was boring and compare Magneto's speech about no tolerance or land of peace to rogue in X1 or his defiance towards the X-Men in Lady Liberty's Head to....Marco Polo.
Case closed, then.