Some of your electron configurations are wrong.
Xenon has 18 $N$ electrons ($s+p+d$ sublevels full) and eight $O$ electrons ($s+p$ sublevels full). Radon has 18 $O$ and 8 $P$. Erbium does not have all the $f$ subleblvels full and ends up with $N^{30}O^8P^2$.
You may want to look up the Aufbau Principle. It's imperfect but more accurate than the shell-by-shell ordering you assume. Basically, when you have more than one electron the repulsions between electrons raises the energy of sublevels that have higher angular momentum and don't get close to the nucleus, and then they overlap with lower angular momentum orbitals of what you thought were higher shells.