generate state variable so that the state transitions are more explicit
this allows us to generate separate callback functions for graph selection, table selection and reset button, rather than defining all three in the same function
create a parameter object to avoid passing around view and matrix objects, controlContainer and groups
Closes #19