Here's a great little article from AltEnergyMag.com that all you city-dwellers should check out. The piece poses the following question: for an urban citizen given a small, open space (whether rooftop, patio, or disused building site), is it more beneficial to plant a small garden or to use the space for harvesting solar electricity?
The article examines the question under three lenses: energy, economic and transport energy.
Lest you dismiss it as op/ed, take a moment to read the first section of the article that compares the "energy balance" of the two options. These folks did their homework. There's real math in there.
Of course, what can't be quantified is the spiritual or emotional value of having a garden over solar power or vice versa. This only the reader can determine. Personally, I'd prefer the garden, as it requires getting the hands dirty and forces upon me some meditative time. Others might prefer the less labor-intensive solar panel.