cleaning up and testing iq_MH_iter.py