Visiting Agra in a single day from Delhi is totally doable. You've got a bunch of choices, depending on how much you want to spend and what you like. Here's the lowdown,
Buses, If you're looking to save cash, this is your best bet. They usually throw in a guide and tend to start at the crack of dawn, getting you back real late. Costs differ but they generally cover your ride and the guide, just remember you'll pay extra for food and getting into sights.
Trains, The Gatimaan Express is the speediest train in India and it's a smooth ride to Agra from Delhi. They feed you during the trip and it's fast, giving you more time to see the sights.
Cars, Go for a private car if you want things your way. You can take off whenever you like and tailormake your day to fit what interests you.