import pandas as pd if False: df1 = pd.DataFrame({'a':[1,2,3],'b':[4,5,6],'c':[7,8,9]}) df2 = pd.DataFrame({'a':[10,20,30],'b':[40,50,60],'c':[70,80,90]}) print df1 + df2 if False: df1 = pd.DataFrame({'a':[1,2,3], 'b':[4,5,6], 'c':['7','8','9']}) df2 = pd.DataFrame({'d':[10,20,30], 'c':[40,50,60], 'b':[70,80,90]}) df1 + df2 if False: df1 = pd.DataFrame({'a':[1,2,3], 'b':[4,5,6], 'c':[7,8,9]}, index=['row1','row2','row3']) df2 = pd.DataFrame({'a':[10,20,30],'b':[40,50,60],'c':[70,80,90]}, index=['row4','row3','row2']) print df1 + df2 entries_and_exits = pd.DataFrame({ 'ENTRIESn': [3144312, 3144335, 3144353, 3144424, 3144594, 3144808, 3144895, 3144905, 3144941, 3145094], 'EXITSn': [1088151, 1088159, 1088177, 1088231, 1088275, 1088317, 1088328, 1088331, 1088420, 1088753] }) def get_hourly_entries_and_exits(entries_and_exits): return None
import pandas as pd if False: df = pd.DataFrame({ 'a':[1, 2, 3], 'b':[10, 20, 30], 'c':[5, 10, 15] }) def add_one(x): return x + 1 print df.applymap(add_one) grades_df = pd.DataFrame( data={'exam1': [43, 81, 78, 75, 89, 70, 91, 65, 98, 87], 'exam2': [24, 63, 56, 56, 67, 51, 79, 46, 72, 60]}, index=['Andre', 'Barry', 'Chris', 'Dan', 'Emilio', 'Fred', 'Greta', 'Humbert', 'Ivan', 'James'] ) def convert_grades(grades): return None