I usually only do it with a leftover bag, but it can give really good results. I've also ruined quite a bit of espresso shots this way, so it doesn't always work out.
This can also be nice for people who want to cut back on caffeine, but not completely. Just mix decaf beans with regular beans.