Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def EventHist(db,dk): #db is a Shelve object of pandas dataframes, dk is a list of keys
- for dbKey in dk:
- hist,bins=fn(db[dbKey]) # this function is only thing that changes by event
- plt.semilogx(hist,bins,label=dbKey)
- db.sync()
- # bunch of other plot properties
- plt.show()
- @EventHist
- def myEvent(df):
- return np.hist(df['foo'].values+df['bar'].values)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement