Administrator
2023-11-29 a933eb7fc507efd0632926a59af9700aba80d69c
test/test_code_attribute.py
@@ -5,19 +5,19 @@
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_up_too_high_in_10d_with_limit_up(datas)
    return is_new_high
if __name__ == "__main__":
    code_str = "000536,000625,000628,000670,000766,000829,001311,001331,002189,002275,002331,002341,002363,002406,002416,002655,002691,002848,002861,002885,002906,002917,002962,300217,300462,300552,301111,301215,301372,600107,600178,600222,600288,600513,600698,600960,601777,603029,603286,603297,603569,605020,688314,688789"
    code_str = "600148"
    codes = code_str.split(",")
    for code in codes:
        if code.find("00") != 0 and code.find("60") != 0:
            continue
        try:
            datas = init_data_util.get_volumns_by_code(code, 120)
            datas = datas[3:]
            datas = datas[0:]
            result = is_too_high(datas)
            if result:
                print(code, result)