| | |
| | | # volumes_data) |
| | | except Exception as e: |
| | | logger_first_code_record.error(f"{code}:{str(e)}") |
| | | logger_first_code_record.exception(e) |
| | | gpcode_manager.FirstCodeManager().add_record(codes) |
| | | # 初始化板块信息,暂时删除 |
| | | # for code in codes: |
| | |
| | | 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] < 0.6: |
| | | return False, True, f"非强势10分钟,强势主线后排,不满足自由市值,股价创新高或者逼近前高,当日量比({cls.volume_rate_info[code][0]})小于0.6" |
| | | return False, True, f"非强势10分钟,非强势主线后排,满足自由市值,股价创新高或者逼近前高, 当日量比({cls.volume_rate_info[code][0]})小于0.6" |
| | | else: |
| | | if code in cls.volume_rate_info and cls.volume_rate_info[code][0] < 0.3: |
| | | return False, True, f"非强势10分钟,强势主线后排,不满足自由市值,当日量比({cls.volume_rate_info[code][0]})小于0.3" |
| | | return False, True, f"非强势10分钟,非强势主线后排, 满足自由市值,当日量比({cls.volume_rate_info[code][0]})小于0.3" |
| | | return True, False, can_buy_result[2] |
| | | |
| | | @classmethod |
| | |
| | | def is_too_high(datas): |
| | | limit_up_price = round(datas[0]["close"] * 1.1, 2) |
| | | datas.reverse() |
| | | is_new_high = code_nature_analyse.is_price_too_high_in_days(datas,limit_up_price) |
| | | is_new_high = code_nature_analyse.is_price_too_high_in_days(datas, limit_up_price) |
| | | return is_new_high |
| | | |
| | | |
| | | if __name__ == "__main__": |
| | | code_str = "002861" |
| | | code_str = "002915" |
| | | codes = code_str.split(",") |
| | | for code in codes: |
| | | if not tool.is_shsz_code(code): |
| | |
| | | try: |
| | | limit_up_price = 16.96 |
| | | volumes_data = init_data_util.get_volumns_by_code(code, 150) |
| | | volumes_data = volumes_data[1:] |
| | | volumes = init_data_util.parse_max_volume(volumes_data[:90], |
| | | code_nature_analyse.is_new_top( |
| | | limit_up_price, |
| | | volumes_data[:90]) or code_nature_analyse.is_near_top( |
| | | limit_up_price, |
| | | volumes_data[:90])) |
| | | print(volumes) |
| | | is_too_high(volumes_data) |
| | | except: |
| | | print(code, "出错") |