Android devices have a screen that shows you approximately what applications and processes are using your battery, by percentage.
I'm wondering, in theory, can this be done on a MacBook? How do you think Android determines those numbers?
I'd say that what's really being measured there is average CPU usage per application. Then some maths is being done in the background to calculate based on CPU usage how many watts per hour are being consumed per app. Knowing current battery capacity/charge would make that pretty trivial in terms of calculation.
On a portable computer, similarly, if an app is really driving your CPU, then your battery is gonna run out faster.
I'd recommend getting hold of something like iStat Menus which can show you realtime CPU usage in the menu bar as well as a bunch of other stuff. Specifically, the CPU monitor in iStat breaks down CPU usage per application.
Remember that overall the programs that you run don't tell the full story about what is using your battery. I cannot put my hands to the benchmarks but the software you run can account for less than half of the usage. Consider that you can boot your laptop and leave it at the login screen (assuming you turn off sleeping etc) and it may last 6 hours (guestimate, for say an 11" macbook Air). Do the same again and start playing Portal 2, and this might only reduce to 4 hours (anecdotal, from my own usage of said Macbook Air).
So just powering the screen, keeping the power to the memory (which uses the same amount of power whether you have 20Mb or 2Gb in use), powering your ports, wireless, bluetooth, capacitive trackpad and so on uses say 2/3rds of your available juice, regardless of use.
Of the remanding third, you have to apportion it between CPU and GPU in most cases. CPU use is simple to quantify by looking into Activity Monitor, GPU use less so, especially if you end up running code that uses OPEN CL and pushes CPU tasks onto your GPU...
I believe that anecdotally the Android phones typically chew approx 60% battery on the screen alone.
So in short, I don't think its really feasible, and even if it was it wouldn't be the most important thing to monitor. I'd be more interested to know if notching your screen brightness down 25% for example would give me an extra X minutes, than if I quit for example DropBox...