added some more analyze functions and rough draft of menu