添加中枢识别在klc和笔

This commit is contained in:
Porter
2026-04-05 11:43:30 +08:00
parent ea317fb6f9
commit 6a6d24f601
9 changed files with 89 additions and 44 deletions
+5 -4
View File
@@ -1262,7 +1262,7 @@ class TF_DF():
if (last_top.low < klc.pre.high or last_top.low < klc.next.high) and (klc.index - last_top.index < 10):
return False
return True
# 建议用这种方式生成笔中枢
def cal_bi_zs(self, seg_list):
bi_zs_list = []
for seg in seg_list:
@@ -1270,6 +1270,7 @@ class TF_DF():
if len(zs_list) > 0:
bi_zs_list = list(bi_zs_list) + list(zs_list)
return bi_zs_list
# 这个种方式不是很好,会有很多重叠的
def cal_bi_zs_list(self, bi_list):
"""
根据缠论笔中枢定义计算中枢(参照 get_zs_list 线段中枢判断规则)
@@ -1714,9 +1715,9 @@ class TF_DF():
bsp_list.append(bsp)
return bsp_list
def calculate_zs(self, seg_list):
return self.get_zs_list(seg_list)
def get_zs_list(self, seg_list):
def calculate_seg_zs(self, seg_list):
return self.get_seg_zs_list(seg_list)
def get_seg_zs_list(self, seg_list):
"""
根据缠论线段中枢定义计算中枢
从第4根线段开始(索引3),每3根线段为一组检查