fixed errors from previous commit and added plot click -> print composition and sample