Added user input and ability to define bin