| | |
| | | has_limit_down_in_5 = True if k_format and len(k_format) >= 13 and k_format[12] else False |
| | | # 是否是强势10分钟 |
| | | is_in_strong_time = now_timestamp <= int("094000") |
| | | |
| | | # 量参考是否在最近30天 |
| | | # is_refer_volume_date_in_30_days = False |
| | | # try: |
| | |
| | | situation = cls.__MarketSituationManager.get_situation_cache() |
| | | zylt_threshold = buy_condition_util.get_zyltgb_threshold(situation) |
| | | zyltgb = global_util.zyltgb_map.get(code) |
| | | if is_special: |
| | | # 具有辨识度 |
| | | zyltgb = zylt_threshold[2] + 1 |
| | | |
| | | if zyltgb >= zylt_threshold[1]: |
| | | return False, True, f"{zylt_threshold[1] // 100000000}亿以上的都不买({zyltgb})" |
| | | |
| | | if zyltgb < zylt_threshold[0]: |
| | | return False, True, f"{zylt_threshold[0] // 100000000}亿以下的都不买({zyltgb})" |
| | | |
| | | if is_special: |
| | | # 具有辨识度,算作最优市值 |
| | | zyltgb = zylt_threshold[2] + 1 |
| | | |
| | | # 是否是最优自由流通市值 |
| | | is_best_zylt = True if zylt_threshold[2] <= zyltgb <= zylt_threshold[3] else False |
| | | |
| | | if HighIncreaseCodeManager().is_in(code): |
| | | if code in cls.volume_rate_info and cls.volume_rate_info[code][0] < 0.8: |
| | |
| | | # 独苗 |
| | | if not can_buy_result[0] and can_buy_result[1]: |
| | | msg_list.append("独苗") |
| | | if zyltgb < zylt_threshold[2] or zyltgb > zylt_threshold[3]: |
| | | if not is_best_zylt: |
| | | # 如果没有辨识度才不买 |
| | | if not is_special: |
| | | return False, True, f"强势10分钟,无辨识度, 独苗({can_buy_result[4]})不下单({can_buy_result[4]})自由流通市值({zyltgb})不满足条件" |
| | | return False, True, f"强势10分钟,无辨识度, 独苗({can_buy_result[4]})不下单({can_buy_result[4]})自由流通市值({zyltgb})不是最优" |
| | | if k_format and (k_format[1][0] or k_format[3][0]): |
| | | msg_list.append("股价创新高或者逼近前高") |
| | | # 股价创新高或者逼近前高 |
| | |
| | | return False, True, f"强势10分钟,无辨识度,独苗({can_buy_result[4]}),当日量比({cls.volume_rate_info[code][0]})小于{volume_rate_thresholds[0]}" |
| | | else: |
| | | msg_list.append("非独苗") |
| | | if zyltgb < zylt_threshold[2] or zyltgb > zylt_threshold[3]: |
| | | if not is_best_zylt: |
| | | msg_list.append("不满足自由流通") |
| | | if k_format and (k_format[1][0] or k_format[3][0]): |
| | | # 股价创新高或者逼近前高 |
| | |
| | | |
| | | # 非强势10分钟只买主线 |
| | | if not can_buy_result[0] and can_buy_result[1]: |
| | | if not is_special: |
| | | return False, True, f"非强势10分钟,无辨识度,独苗({can_buy_result[4]})不下单" |
| | | if not is_special and not is_best_zylt: |
| | | return False, True, f"非强势10分钟,无辨识度,非最优自由流通市值,独苗({can_buy_result[4]})不下单" |
| | | if can_buy_result[3]: |
| | | # 强势主线 |
| | | if zyltgb < zylt_threshold[2] or zyltgb > zylt_threshold[3]: |
| | | if not is_best_zylt: |
| | | if k_format and (k_format[1][0] or k_format[3][0]): |
| | | # 股价创新高或者逼近前高 |
| | | if code in cls.volume_rate_info and cls.volume_rate_info[code][0] < volume_rate_thresholds[1]: |
| | |
| | | return False, True, f"非强势10分钟,强势主线后排,满足自由市值,股价创新高或者逼近前高, 当日量比({cls.volume_rate_info[code][0]})小于{volume_rate_thresholds[0]}" |
| | | else: |
| | | # 非强势主线 |
| | | if zyltgb < zylt_threshold[2] or zyltgb > zylt_threshold[3]: |
| | | if not is_best_zylt: |
| | | if code in cls.volume_rate_info and cls.volume_rate_info[code][0] < volume_rate_thresholds[ |
| | | 1] and not is_special: |
| | | return False, True, f"非强势10分钟,非强势主线后排【主线后排】,不满足自由市值,无辨识度, 当日量比({cls.volume_rate_info[code][0]})小于{volume_rate_thresholds[1]}" |