duration_date = 5
            print("duaration: %s duration_date:%s" % (cct.get_today_duration(du_date), duration_date))
        log.info("duaration: %s duration_date:%s" % (cct.get_today_duration(du_date), duration_date))
    set_duration_console(du_date)
    # all_diffpath = tdd.get_tdx_dir_blocknew() + '062.blk'
    parser = cct.MoniterArgmain()
    parserDuraton = cct.DurationArgmain()
    st_key_sort = ct.sort_value_key_perd
    st = None
    while 1:
        try:
            # df = sina_data.Sina().all
            # top_now = tdd.getSinaAlldf(market='cx', vol=ct.json_countVol, vtype=ct.json_countType)
            # top_now = tdd.getSinaAlldf(market='次新股',filename='cxg', vol=ct.json_countVol, vtype=ct.json_countType)
            if st is None:
                st_key_sort = '%s %s'%(st_key_sort.split()[0],cct.get_index_fibl())
                
            time_Rt = time.time()
            market_blk = '雄安特区'
            top_now = tdd.getSinaAlldf(market=market_blk, filename='xatq', vol=ct.json_countVol, vtype=ct.json_countType)
            # top_now = tdd.getSinaAlldf(market=u'次新股',filename='cxg', vol=ct.json_countVol, vtype=ct.json_countType)

            # top_now = tdd.getSinaAlldf(market='���', filename='mnbk',vol=ct.json_countVol, vtype=ct.json_countType)

            # top_dif = top_now
            # top_now.to_hdf("testhdf5", 'marketDD', format='table', complevel=9)
            now_count = len(top_now)
            radio_t = cct.get_work_time_ratio()
            # top_now = top_now[top_now.buy > 0]
            time_d = time.time()
            if time_d - time_s > delay_time:
예제 #2
0
    search250.get_roll_mean_all(single=False, tdx=True, app=False)

    # all_diffpath = tdd.get_tdx_dir_blocknew() + '062.blk'
    parser = cct.MoniterArgmain()
    parserDuraton = cct.DurationArgmain()
    st_key_sort = '2'
    st = None
    # st_key_sort = '6'

    while 1:
        try:
            # df = sina_data.Sina().all
            time_Rt = time.time()
            if st is None:
                st_key_sort = '%s %s' % (st_key_sort.split()[0],
                                         cct.get_index_fibl(default=2))

            # top_now = tdd.getSinaAlldf(market='060', vol=ct.json_countVol, vtype=ct.json_countType)
            # top_now = tdd.getSinaAlldf(market='次新股',filename='cxg', vol=ct.json_countVol, vtype=ct.json_countType)
            market_blk = 'rzrq'
            # market_blk = '060'
            # top_now = tdd.getSinaAlldf(market= market_blk , vol=ct.json_countVol, vtype=ct.json_countType,trend=True)
            # top_now = tdd.getSinaAlldf(market='次新股,060', filename='cxg' , vol=ct.json_countVol, vtype=ct.json_countType,trend=True)
            top_now = tdd.getSinaAlldf(market=market_blk,
                                       vol=ct.json_countVol,
                                       vtype=ct.json_countType,
                                       trend=False)

            # top_now = tdd.getSinaAlldf(market='央企',filename='yqbk', vol=ct.json_countVol, vtype=ct.json_countType,trend=False)

            # top_now = tdd.getSinaAlldf(market='all', vol=ct.json_countVol, vtype=ct.json_countType)
예제 #3
0
        st_key_sort)
    # st_key_sort = '9'
    # st_key_sort = '7'
    # st_key_sort = ct.sort_value_key_perd23
    st = None
    while 1:
        try:
            # df = rl.get_sina_all_json_dd(vol, type)
            # if len(df) > cut_num:
            #     df = df[:cut_num]
            #     print len(df),
            # top_now = rl.get_sina_dd_count_price_realTime(df)
            # print len(top_now)
            if st is None and st_key_sort in ['2', '3']:
                st_key_sort = '%s %s' % (
                    st_key_sort.split()[0], cct.get_index_fibl())
            time_Rt = time.time()
            # top_now = tdd.getSinaAlldf(market='??,rzrq',filename='yqbk', vol=ct.json_countVol, vtype=ct.json_countType)
            top_now = tdd.getSinaAlldf(
                market='all', vol=ct.json_countVol, vtype=ct.json_countType)
            # top_now = tdd.getSinaAlldf(market='??',filename='yqbk', vol=ct.json_countVol, vtype=ct.json_countType,trend=False)

            # top_now = tdd.getSinaAlldf(market='rzrq', vol=ct.json_countVol, vtype=ct.json_countType)
            # top_now = tdd.getSinaAlldf(market='??¹?060',filename='cxg', vol=ct.json_countVol, vtype=ct.json_countType)

            time_d = time.time()
            if time_d - time_s > delay_time:
                status_change = True
                time_s = time.time()
                top_all = pd.DataFrame()
예제 #4
0
    # market_sort_value, market_sort_value_key = ct.get_market_sort_value_key('3 2')
    # market_sort_value, market_sort_value_key = ct.get_market_sort_value_key('1')
    # st_key_sort = '2'
    st_key_sort = ct.sort_value_key_perd23
    market_sort_value, market_sort_value_key = ct.get_market_sort_value_key(
        ct.sort_value_key_perd23)
    st = None
    top_list = []
    while 1:
        try:
            # df = sina_data.Sina().all
            time_Rt = time.time()

            if st is None:
                st_key_sort = '%s %s' % (st_key_sort.split()[0],
                                         cct.get_index_fibl())
            # top_now = tdd.getSinaAlldf(market='060.blk', vol=ct.json_countVol, vtype=ct.json_countType)
            # market_blk = '次新股'
            market_blk = 'all'
            # market_blk = 'cyb'
            # market_blk = '060'
            top_now = tdd.getSinaAlldf(market=market_blk,
                                       filename='cxg',
                                       vol=ct.json_countVol,
                                       vtype=ct.json_countType)
            now_count = len(top_now)
            radio_t = cct.get_work_time_ratio()
            # top_now = top_now[top_now.buy > 0]
            time_d = time.time()
            if time_d - time_s > delay_time:
                status_change = True