refactored initialisation of emapex into multiple methods