As DV says...it could just be one ferrous component causing problems.
In a previous life I used to build new a/c,when compass swing time came along we sometimes had problems with magnetic 'hotspots' affecting either the main flux detector or the E2 standby compass.
We used a magnetic field detector...
But I also used an E2 compass sometimes...just moving it around the cockpit to see where the largest swing was (keeping the E2 orientation constant).
Sometimes we had (say) a magnetised tailplane or occasionally something like a magnetised Ejection seat gun
...but it can obviously be any ferrous component