In python I have a pandas data frame similar to the one below:
| AUG12 | UNDERLYING | VOL |
|---------------------| | |
| 45 | 49 | 50 | 55 | | |
====================================================|
2012-11-14 | 1 | 1 | 2 | 3 | 49 | ? |
... ... ... ... ...
The task is: For each row, find column names which are greater than UNDERLYING (49), sum the values (2+3) and put the result in to VOL (5). How can I accomplish this in python? Many thanks in advance!