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/plate_strength_analysis.py | 7 +++---- 1 files changed, 3 insertions(+), 4 deletions(-) diff --git a/strategy/plate_strength_analysis.py b/strategy/plate_strength_analysis.py index 72fd536..21a20b3 100644 --- a/strategy/plate_strength_analysis.py +++ b/strategy/plate_strength_analysis.py @@ -23,9 +23,8 @@ # now_time_str = tool.get_now_time_str() # if data_cache.OPENING_TIME < now_time_str < data_cache.NOON_MARKET_TIME: log_data = {plate_name: its_stock['list']} - # 灏濊瘯杩囨护鎺夋棤鎰忎箟鐨勬蹇垫澘鍧�(plate_name not in ['绉戝垱鏉�', '鍖椾氦鎵�', '娆℃柊鑲�', '鏃�', 'ST鏉垮潡', 'ST鎽樺附', '骞惰喘閲嶇粍', '鍥戒紒鏀归潻','瓒呰穼', '澹宠祫婧�', '鑲℃潈杞', '閫佽浆濉潈']) and '澧為暱' in plate_name - if (plate_name not in ['绉戝垱鏉�', '鍖椾氦鎵�', '娆℃柊鑲�', '鏃�', 'ST鏉垮潡', 'ST鎽樺附', '骞惰喘閲嶇粍', '鍥戒紒鏀归潻', '瓒呰穼', - '澹宠祫婧�', '鑲℃潈杞', '閫佽浆濉潈']) or ('澧為暱' in plate_name): + # 灏濊瘯杩囨护鎺夋棤鎰忎箟鐨勬蹇垫澘鍧� 銆愪唬琛ㄧ潃鏈夋棤寮哄害鍙兘銆� + if (plate_name not in ['绉戝垱鏉�', '鍖椾氦鎵�', '鏃�', '骞惰喘閲嶇粍', '鍥戒紒鏀归潻', '瓒呰穼', '澹宠祫婧�', '鑲℃潈杞', '閫佽浆濉潈']) or ('娆℃柊' in plate_name or 'ST' in plate_name or '鐮村噣鑲�' in plate_name): # print(f"{i[1]} 寮哄害:{i[2]}") # 閫氳繃鏉垮潡ID鑾峰彇鍏朵笅闈㈢殑涓偂寮哄害鍒楄〃 @@ -52,7 +51,7 @@ # 鍒濆鍖栬偂绁ㄥ己搴﹀垪琛� stock_power_list = [] for s in its_stock['list']: - # 杩囨护鎺夋定骞呭ぇ浜� and s[6] < 6.5 涓斿皬浜�0%鐨� 鍜� 鍚嶇О涓寘鍚玈T鐨� 鍜� 娑ㄩ�熷皬浜庣瓑浜�0%鐨� 鍜� 鍙鏄ㄦ棩鏈定鍋� 鍜� 涓婅瘉鎴栨繁璇佺殑姝h偂 and s[9] > 0.0025 涓婂搴︽満鏋勬寔浠� >0 + # 杩囨护鎺夋定骞呭ぇ浜� 褰撴棩娑ㄥ箙s[6] < 0% 鐨� 鍜� 鍚嶇О涓寘鍚玈T鐨� 鍜� 娑ㄩ�熷皬浜庣瓑浜�0%鐨� 鍜� 鍙鏄ㄦ棩鏈定鍋� 鍜� 涓婅瘉鎴栨繁璇佺殑姝h偂 and s[9] > 0.0025 涓婂搴︽満鏋勬寔浠� >0 if s[6] > 0 and s[1].find("ST") < 0 and s[1].find("XD") < 0 and s[23].find("鏉�") < 0 and s[24].find("鏉�") < 0 and (s[0].startswith('60') or s[0].startswith('00')) and s[9] > 1 and int(s[42]) > 0: # print(f"{s[1]}锛屼釜鑲′唬鐮侊細{s[0]}锛� 娑ㄥ箙锛歿s[6]}% 娑ㄩ�燂細{s[9]}% 姒傚康锛歿s[4]} 涓诲姏璧勯噾鎺ㄦ祴锛歿s[2]} 棰嗘定娆℃暟锛歿s[40]} 浠婃棩绗嚑鏉匡細{s[23]} 鏄惁鐮寸増{s[24]}") # 瀵逛釜鑲″己搴� 涓昏 灞炴�у垪琛ㄨ繘琛岃濉� -- Gitblit v1.8.0