根据新的条件进行交易,添加交易规则

This commit is contained in:
Porter
2025-09-15 10:29:53 +08:00
parent 3c360ea35b
commit 0b9f63409c
8 changed files with 149 additions and 71 deletions
+2 -2
View File
@@ -79,12 +79,12 @@ class ChanKLC():
if self.fx == Chan_FX_TYPE.TOP:
#print(self.end_time, self.fx, self.macd, self.macdhist, len(self.klus))
if self.macdhist < 0 and self.macd > 0:
#self.klc_fx_type = Chan_KLC_FX.TOP5
self.klc_fx_type = Chan_KLC_FX.TOP5
self.bb_out = True
else:
if self.fx == Chan_FX_TYPE.BOTTOM:
if self.macdhist > 0 and self.macd < 0:
#self.klc_fx_type = Chan_KLC_FX.BOTTOM5
self.klc_fx_type = Chan_KLC_FX.BOTTOM5
self.bb_out = True
def cal_macd_state(self, dir):