From b9a8aab5369b51f0d9f8fe91d934822a110acf40 Mon Sep 17 00:00:00 2001 From: admin <admin@example.com> Date: 星期五, 25 四月 2025 14:50:35 +0800 Subject: [PATCH] 有概念的 过滤列表更新 有强度的 过滤列表更新 解决一个9:15的除以零BUG --- strategy/basic_methods.py | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/strategy/basic_methods.py b/strategy/basic_methods.py index f3b50d3..0740517 100644 --- a/strategy/basic_methods.py +++ b/strategy/basic_methods.py @@ -88,6 +88,7 @@ if last_price != 0: growth = (price - last_price) / last_price * 100 # 璁$畻娑ㄥ箙鐧惧垎姣� return growth + finally: history_price[symbol] = price # print(f"price======={price}") @@ -148,6 +149,7 @@ frying_plate_day_min_index = next((i for i, d in enumerate(k_line_data[0:7]) if 'attribute' in d and d['attribute'] in data_cache.frying_plate_type), None) # 濡傛灉娌℃湁鎵惧埌锛岃繑鍥濶one # 鎵惧埌鏈�杩�7鏃ュ唴鐨勬湁璺屽仠鐨勫簭鍙� limit_down_day_min_index = next((i for i, d in enumerate(k_line_data[0:7]) if 'attribute' in d and d['attribute'] in data_cache.limit_down_type), None) # 濡傛灉娌℃湁鎵惧埌锛岃繑鍥濶one + # 鏈�杩戠殑娑ㄥ仠搴忓彿瀛樺湪 涓� 闈炴槰鏃� if limit_up_day_min_index is not None and limit_up_day_min_index > 0: # 寮�鐩樹环 < 娑ㄥ仠褰撴棩鏈�楂樹环 <= 浠婃棩娑ㄥ仠浠� -- Gitblit v1.8.0