updated donut.js file to accept inputs