An X-ray machine has capital and operating expenses, requires significant safety measures, licensing/inspection (at least in the US), and a trained technician.
That all is significantly more expensive than saying "you hand us a form telling us whether there's a pacemaker or not, and if you fuck it up you get in trouble."