IMprove with pointers (for interactive mode) and better legend