Update deprecated functions and hoa.map PD