Q:

pandas get minimum value of two columns as part of an equation

How can I reference the minimum value of two dataframes as part of a pandas dataframe equation? I tried using the python min() function which did not work. I'm sorry if this is well-documented somewhere but I have not been able to find a working solution for this problem. I am looking for something along the lines of this:
data['eff'] = pd.DataFrame([data['flow_h'], data['flow_c']]).min() *Cp* (data[' Thi'] - data[' Tci'])

I also tried to use pandas min() function, which is also not working.
min_flow = pd.DataFrame([data['flow_h'], data['flow_c']]).min()

InvalidIndexError: Reindexing only valid with uniquely valued Index objects

I was confused by this error. The data columns are just numbers and a name, I wasn't sure where the index comes into play. 
In [108]: data['flow_c']
Out[108]: 
0       74.014640
1       74.150579
2       74.014640
3       73.960195
4       74.069046
5       73.960195
6       73.987423
7       73.905710

A:

Your question is not very clear to me, but my guess is that you are trying to get element-wise mininum of two Series (not DataFrames). If that's what you want, try: data[['flow_h','flow_c']].min(axis=1).

