add state object to plot actions and tests