Split running and plotting in separate macros