| | |
| | | # high_level_general_code_blocks 高位泛化板块 |
| | | @classmethod |
| | | def update_can_buy_blocks(cls, code, current_limit_up_datas, limit_up_record_datas, |
| | | yesterday_current_limit_up_records, |
| | | latest_current_limit_up_records, |
| | | before_blocks_dict, current_limit_up_block_codes_dict): |
| | | yesterday_current_limit_up_codes = set() |
| | | yesterday_current_limit_up_records_dict = {} |
| | | yesterday_current_limit_up_records = latest_current_limit_up_records[0][1] |
| | | if yesterday_current_limit_up_records: |
| | | for r in yesterday_current_limit_up_records: |
| | | yesterday_current_limit_up_codes.add(r[0]) |
| | |
| | | if r[4].replace("连板", "").isdigit(): |
| | | count = int(r[4].replace("连板", "")) |
| | | if count >= 3: |
| | | latest_datas = latest_current_limit_up_records[:count-1] |
| | | # 是高位板 |
| | | # 当日精选 |
| | | blocks = set(r[6].split("、")) |
| | | if r[0] in yesterday_current_limit_up_records_dict: |
| | | # 昨日涨停原因 |
| | | blocks.add(yesterday_current_limit_up_records_dict.get(r[0])[5]) |
| | | for d in latest_datas: |
| | | for dd in d[1]: |
| | | if dd[0] == r[0]: |
| | | blocks.add(dd[5]) |
| | | break |
| | | f_blocks = [] |
| | | for b in blocks: |
| | | if b: |