Skip to content

Instantly share code, notes, and snippets.

@quantra-go-algo
Last active June 2, 2022 14:39
Show Gist options
  • Save quantra-go-algo/ebe85fbbe3c8c3c46810bf80b4a50ef8 to your computer and use it in GitHub Desktop.
Save quantra-go-algo/ebe85fbbe3c8c3c46810bf80b4a50ef8 to your computer and use it in GitHub Desktop.
# Resample LTP column to 15 mins bars using resample function from pandas
resample_LTP = data['LTP'].resample('15Min').ohlc(_method='ohlc')
# Resample LTQ column to 15 mins bars using resample function from pandas
resample_LTQ = data['LTQ'].resample('15Min').sum()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment