| | |
| | | rate = round(canceled_num / total_num, 3) |
| | | |
| | | # 除开最大单的影响权重 |
| | | if not must_buy: |
| | | temp_thresh_hold_rate = round((total_num - max_num * max_num_count) * 0.8 / total_num, 2) |
| | | if thresh_hold_rate > temp_thresh_hold_rate: |
| | | if cancel_rate_info and cancel_rate_info[1] > 0: |
| | | pass |
| | | else: |
| | | # 没有人为设置 |
| | | # 目标撤单比例大于大单撤单比例就取比例均值 |
| | | thresh_hold_rate = round((thresh_hold_rate + temp_thresh_hold_rate) / 2, 2) |
| | | # if not must_buy: |
| | | # temp_thresh_hold_rate = round((total_num - max_num * max_num_count) * 0.8 / total_num, 2) |
| | | # if thresh_hold_rate > temp_thresh_hold_rate: |
| | | # if cancel_rate_info and cancel_rate_info[1] > 0: |
| | | # pass |
| | | # else: |
| | | # # 没有人为设置 |
| | | # # 目标撤单比例大于大单撤单比例就取比例均值 |
| | | # thresh_hold_rate = round((thresh_hold_rate + temp_thresh_hold_rate) / 2, 2) |
| | | |
| | | real_place_order_info = self.__real_place_order_index_dict.get(code) |
| | | is_default_place_order_index = real_place_order_info[1] if real_place_order_info else False |