Quick Calculations #679
damnpenguins
started this conversation in
General
Replies: 1 comment 1 reply
-
Why not use class S(Strategy):
def init(self):
self.hourly = self.I(lambda: self.data.df.resample('1H', label='right').agg(OHLCV_AGG).dropna())
def next(self):
if self.data.Close[-1] > self.hourly[-1]:
... |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi Everyone!
Hitting my head against a brick wall here. Is there an easy way to reference both the Daily Open level (say 08:00GMT) and the current Hourly open from within the next loop? I'm utilising 1m data resampled to 5M and 60M.
Struggling to get my head around pandas, numpy etc
Im wanting to test some really simple bar based logic, ie buy the next 5M Bar if we are above the Hourly and Daily open. hold for one bar... that kind of stuff just to get my head around things....
Many thanks for your help :)
P.S I have gone through all the discussion here and have searched StackExchange to no avail ;)
Beta Was this translation helpful? Give feedback.
All reactions