Make matplotlib optional and replacing docopt with click