请 [注册] 或 [登录]  | 返回主站

量化交易吧 /  数理科学 帖子:3364762 新帖:0

【重磅更新】研究模块调用回测功能

外汇老法师发表于:5 月 10 日 02:14回复(1)

为了进一步打通研究模块与回测模块,我们增加了在研究中调用回测的新功能。

主要功能如下:

  1. 可以在研究中创建回测
  2. 设定初始持仓
  3. 设定全局变量值
  4. 获取回测状态
  5. 获得回测参数
  6. 获得收益曲线
  7. 获得持仓详情
  8. 获得交易详情
  9. 获得所有 record 记录
  10. 获得总的风险指标
  11. 获得分月计算的风险指标

具体功能参看API - 研究中创建回测函数

具体用法见下面的研究内容。

研究模块调用回测功能¶

首先打开策略编译页面,找到algorithmId, 如下所示(上方红色隐去的部分): img

测试所使用的代码如下所示:

def initialize(context):
    # 定义一个全局变量, 保存要操作的股票
    # 000001(股票:平安银行)
    g.security = '000001.XSHE'
    # 初始化此策略
    # 设置我们要操作的股票池, 这里我们只操作一支股票
    set_universe([g.security])
    # 设置均线长度
    g.ma_long = 5
    g.m = 1.01

# 每个单位时间(如果按天回测,则每天调用一次,如果按分钟,则每分钟调用一次)调用一次
def handle_data(context, data):
    security = g.security
    # 取得过去五天的平均价格
    average_price = data[security].mavg(g.ma_long, 'close')
    # 取得上一时间点价格
    current_price = data[security].close
    # 取得当前的现金
    cash = context.portfolio.cash

    # 如果上一时间点价格高出五天平均价1%, 则全仓买入
    if current_price > g.m*average_price:
        # 用所有 cash 买入股票
        order_value(security, cash)
        # 记录这次买入
        log.info("Buying %s" % (security))
    # 如果上一时间点价格低于五天平均价, 则空仓卖出
    elif current_price < average_price and context.portfolio.positions[security].sellable_amount > 0:
        # 卖出所有股票,使这只股票的最终持有量为0
        order_target(security, 0)
        # 记录这次卖出
        log.info("Selling %s" % (security))
    # 画出上一时间点价格
    record(stock_price=current_price)

接下来设定初始化仓位,设定g.全局变量的值,当然也可以选择不设置

# 设定初始仓位
InitialPositions = [
    {
        'security': '000001.XSHE',
        'amount': '1000',  # 100股
        'avg_cost': '10.0' # 持仓均价10元
    }
]

# 设定g.全局变量的值
extra_vars = {'ma_long': 5, 'm': 1.01}

传入create_backtest函数的algorithm_id切记要改成自己的algorithmId,否则会提示错误:¶

Exception: can not find algorithm

获取 algorithmId 文章初始所示。¶

# 记得此处传入你自己的 algorithmId
out_algorithm_id = create_backtest('bfdde744e43517e4de41d8bc0ffd59d7','2015-01-01', '2016-06-01', \
                    frequency="day",initial_cash=100000, initial_positions=InitialPositions, extras=extra_vars)
out_algorithm_id
u'849c256bca210cd95e2d2bc9219239b3'
out_algorithm_id = '456bbf8cd483f21218528c45335cb229'
gt = get_backtest(out_algorithm_id)
gt.get_status()        # 获取回测状态
u'running'
gt.get_params()        # 获取回测参数
{u'algorithm_id': u'bfdde744e43517e4de41d8bc0ffd59d7',
 u'end_date': u'2016-06-01 23:59:59',
 u'extras': {u'm': 1.01, u'ma_long': 5},
 u'frequency': u'day',
 u'initial_cash': u'100000',
 u'initial_positions': [{u'amount': u'1000',
   u'avg_cost': u'10.0',
   u'security': u'000001.XSHE'}],
 u'start_date': u'2015-01-01 00:00:00'}
gt.get_results()       # 获取收益曲线
[{u'benchmark_returns': 0.030516412660366532,
  u'returns': 0.10932029999999981,
  u'time': u'2015-01-05'},
 {u'benchmark_returns': 0.03038001191384132,
  u'returns': 0.0919802999999999,
  u'time': u'2015-01-06'},
 {u'benchmark_returns': 0.031152855147783987,
  u'returns': 0.07158029999999993,
  u'time': u'2015-01-07'},
 {u'benchmark_returns': 0.007231503478643653,
  u'returns': 0.07018800000000014,
  u'time': u'2015-01-08'},
 {u'benchmark_returns': 0.003683952112584432,
  u'returns': 0.07018800000000014,
  u'time': u'2015-01-09'},
 {u'benchmark_returns': -0.005696287607482753,
  u'returns': 0.07018800000000014,
  u'time': u'2015-01-12'},
 {u'benchmark_returns': -0.005564980664769736,
  u'returns': 0.07018800000000014,
  u'time': u'2015-01-13'},
 {u'benchmark_returns': -0.008852465047308744,
  u'returns': 0.07018800000000014,
  u'time': u'2015-01-14'},
 {u'benchmark_returns': 0.01992696051311582,
  u'returns': 0.07018800000000014,
  u'time': u'2015-01-15'},
 {u'benchmark_returns': 0.028706697361551292,
  u'returns': 0.06680789999999992,
  u'time': u'2015-01-16'},
 {u'benchmark_returns': -0.050527703925483225,
  u'returns': -0.04029209999999994,
  u'time': u'2015-01-19'},
 {u'benchmark_returns': -0.03890619052807176,
  u'returns': -0.04255460000000011,
  u'time': u'2015-01-20'},
 {u'benchmark_returns': 0.0042957745482432586,
  u'returns': -0.04255460000000011,
  u'time': u'2015-01-21'},
 {u'benchmark_returns': 0.009595594425680698,
  u'returns': -0.04255460000000011,
  u'time': u'2015-01-22'},
 {u'benchmark_returns': 0.010761226531360135,
  u'returns': -0.04255460000000011,
  u'time': u'2015-01-23'},
 {u'benchmark_returns': 0.02102043039812318,
  u'returns': -0.044801300000000044,
  u'time': u'2015-01-26'},
 {u'benchmark_returns': 0.011666508664418762,
  u'returns': -0.06832130000000003,
  u'time': u'2015-01-27'},
 {u'benchmark_returns': -0.0023720146418561017,
  u'returns': -0.07833889999999999,
  u'time': u'2015-01-28'},
 {u'benchmark_returns': -0.014689115248726292,
  u'returns': -0.07833889999999999,
  u'time': u'2015-01-29'},
 {u'benchmark_returns': -0.028105062533516523,
  u'returns': -0.07833889999999999,
  u'time': u'2015-01-30'},
 {u'benchmark_returns': -0.050865875900789614,
  u'returns': -0.07833889999999999,
  u'time': u'2015-02-02'},
 {u'benchmark_returns': -0.027240530830955012,
  u'returns': -0.07833889999999999,
  u'time': u'2015-02-03'},
 {u'benchmark_returns': -0.03733673297572937,
  u'returns': -0.07833889999999999,
  u'time': u'2015-02-04'},
 {u'benchmark_returns': -0.04719097943942685,
  u'returns': -0.07833889999999999,
  u'time': u'2015-02-05'},
 {u'benchmark_returns': -0.06262124314282036,
  u'returns': -0.07833889999999999,
  u'time': u'2015-02-06'},
 {u'benchmark_returns': -0.0531408252811143,
  u'returns': -0.07833889999999999,
  u'time': u'2015-02-09'},
 {u'benchmark_returns': -0.03587226437973734,
  u'returns': -0.07833889999999999,
  u'time': u'2015-02-10'},
 {u'benchmark_returns': -0.02818033763429606,
  u'returns': -0.07833889999999999,
  u'time': u'2015-02-11'},
 {u'benchmark_returns': -0.025704183003391612,
  u'returns': -0.07833889999999999,
  u'time': u'2015-02-12'},
 {u'benchmark_returns': -0.018076494783803354,
  u'returns': -0.07861419999999986,
  u'time': u'2015-02-13'},
 {u'benchmark_returns': -0.00968445300329246,
  u'returns': -0.08055420000000002,
  u'time': u'2015-02-16'},
 {u'benchmark_returns': -0.0032212649329810272,
  u'returns': -0.0757042,
  u'time': u'2015-02-17'},
 {u'benchmark_returns': -0.015557608798697165,
  u'returns': -0.08831420000000001,
  u'time': u'2015-02-25'},
 {u'benchmark_returns': 0.00922261479099129,
  u'returns': -0.09046320000000008,
  u'time': u'2015-02-26'},
 {u'benchmark_returns': 0.01107562742220991,
  u'returns': -0.09046320000000008,
  u'time': u'2015-02-27'},
 {u'benchmark_returns': 0.01911874364158872,
  u'returns': -0.09046320000000008,
  u'time': u'2015-03-02'},
 {u'benchmark_returns': -0.007302533742912898,
  u'returns': -0.09046320000000008,
  u'time': u'2015-03-03'},
 {u'benchmark_returns': -0.000815857577245338,
  u'returns': -0.09046320000000008,
  u'time': u'2015-03-04'},
 {u'benchmark_returns': -0.010572755790310695,
  u'returns': -0.09046320000000008,
  u'time': u'2015-03-05'},
 {u'benchmark_returns': -0.015616753520738103,
  u'returns': -0.09046320000000008,
  u'time': u'2015-03-06'},
 {u'benchmark_returns': 0.0011446909122294624,
  u'returns': -0.09046320000000008,
  u'time': u'2015-03-09'},
 {u'benchmark_returns': -0.0037054592842357126,
  u'returns': -0.10688419999999998,
  u'time': u'2015-03-10'},
 {u'benchmark_returns': -0.002561617339308264,
  u'returns': -0.10118419999999995,
  u'time': u'2015-03-11'},
 {u'benchmark_returns': 0.016735692424806325,
  u'returns': -0.05368419999999996,
  u'time': u'2015-03-12'},
 {u'benchmark_returns': 0.023757500979849855,
  u'returns': -0.02803420000000001,
  u'time': u'2015-03-13'},
 {u'benchmark_returns': 0.04866450368664044,
  u'returns': -0.001434199999999941,
  u'time': u'2015-03-16'},
 {u'benchmark_returns': 0.06322457590545905,
  u'returns': -0.001434199999999941,
  u'time': u'2015-03-17'},
 {u'benchmark_returns': 0.08839164559576984,
  u'returns': 0.005215799999999993,
  u'time': u'2015-03-18'},
 {u'benchmark_returns': 0.086604286435908,
  u'returns': -0.015684200000000037,
  u'time': u'2015-03-19'},
 {u'benchmark_returns': 0.10155601557006033,
  u'returns': -0.01790499999999995,
  u'time': u'2015-03-20'},
 {u'benchmark_returns': 0.12404997021539721,
  u'returns': -0.01790499999999995,
  u'time': u'2015-03-23'},
 {u'benchmark_returns': 0.12432871447956173,
  u'returns': -0.01790499999999995,
  u'time': u'2015-03-24'},
 {u'benchmark_returns': 0.11509364816814083,
  u'returns': -0.01790499999999995,
  u'time': u'2015-03-25'},
 {u'benchmark_returns': 0.11780666467630985,
  u'returns': -0.01790499999999995,
  u'time': u'2015-03-26'},
 {u'benchmark_returns': 0.12394696218275159,
  u'returns': -0.01790499999999995,
  u'time': u'2015-03-27'},
 {u'benchmark_returns': 0.1569098156184514,
  u'returns': -0.01790499999999995,
  u'time': u'2015-03-30'},
 {u'benchmark_returns': 0.14644657661010196,
  u'returns': -0.03709899999999999,
  u'time': u'2015-03-31'},
 {u'benchmark_returns': 0.167017337327253,
  u'returns': -0.023598999999999926,
  u'time': u'2015-04-01'},
 {u'benchmark_returns': 0.1672666507249474,
  u'returns': -0.033498999999999945,
  u'time': u'2015-04-02'},
 {u'benchmark_returns': 0.18021679795002687,
  u'returns': -0.03079899999999991,
  u'time': u'2015-04-03'},
 {u'benchmark_returns': 0.20554602039502456,
  u'returns': 0.027700999999999976,
  u'time': u'2015-04-07'},
 {u'benchmark_returns': 0.21566542764605412,
  u'returns': 0.09610099999999999,
  u'time': u'2015-04-08'},
 {u'benchmark_returns': 0.20613859957183744,
  u'returns': 0.10060100000000016,
  u'time': u'2015-04-09'},
 {u'benchmark_returns': 0.2294223767971577,
  u'returns': 0.21040100000000006,
  u'time': u'2015-04-10'},
 {u'benchmark_returns': 0.251115472287585,
  u'returns': 0.22390100000000013,
  u'time': u'2015-04-13'},
 {u'benchmark_returns': 0.25595769878923114,
  u'returns': 0.2059010000000001,
  u'time': u'2015-04-14'},
 {u'benchmark_returns': 0.23963743436421536,
  u'returns': 0.23200100000000012,
  u'time': u'2015-04-15'},
 {u'benchmark_returns': 0.27728432339428455,
  u'returns': 0.25810100000000014,
  u'time': u'2015-04-16'},
 {u'benchmark_returns': 0.3006563932190154,
  u'returns': 0.25270100000000006,
  u'time': u'2015-04-17'},
 {u'benchmark_returns': 0.2796537911342345,
  u'returns': 0.2059010000000001,
  u'time': u'2015-04-20'},
 {u'benchmark_returns': 0.30717306622935414,
  u'returns': 0.2043355,
  u'time': u'2015-04-21'},
 {u'benchmark_returns': 0.3413157012257675,
  u'returns': 0.2043355,
  u'time': u'2015-04-22'},
 {u'benchmark_returns': 0.34162076347629466,
  u'returns': 0.1798953000000001,
  u'time': u'2015-04-23'},
 {u'benchmark_returns': 0.3307961473863834,
  u'returns': 0.1508817,
  u'time': u'2015-04-24'},
 {u'benchmark_returns': 0.36049613649130285,
  u'returns': 0.1508817,
  u'time': u'2015-04-27'},
 {u'benchmark_returns': 0.3418949799148485,
  u'returns': 0.1508817,
  u'time': u'2015-04-28'},
 {u'benchmark_returns': 0.3510822210682556,
  u'returns': 0.1508817,
  u'time': u'2015-04-29'},
 {u'benchmark_returns': 0.34416596744776395,
  u'returns': 0.1508817,
  u'time': u'2015-04-30'},
 {u'benchmark_returns': 0.3548785198538078,
  u'returns': 0.13642979999999993,
  u'time': u'2015-05-04'},
 {u'benchmark_returns': 0.3008547685785883,
  u'returns': 0.12584850000000003,
  u'time': u'2015-05-05'},
 {u'benchmark_returns': 0.2885419128082283,
  u'returns': 0.12584850000000003,
  u'time': u'2015-05-06'},
 {u'benchmark_returns': 0.2649864660462602,
  u'returns': 0.12584850000000003,
  u'time': u'2015-05-07'},
 {u'benchmark_returns': 0.28997864847235433,
  u'returns': 0.12584850000000003,
  u'time': u'2015-05-08'},
 {u'benchmark_returns': 0.32736943236631255,
  u'returns': 0.12584850000000003,
  u'time': u'2015-05-11'},
 {u'benchmark_returns': 0.3434683993146006,
  u'returns': 0.12296339999999994,
  u'time': u'2015-05-12'},
 {u'benchmark_returns': 0.33526596023154154,
  u'returns': 0.11701340000000005,
  u'time': u'2015-05-13'},
 {u'benchmark_returns': 0.3302689386918263,
  u'returns': 0.11786340000000006,
  u'time': u'2015-05-14'},
 {u'benchmark_returns': 0.3066936826928113,
  u'returns': 0.10793240000000015,
  u'time': u'2015-05-15'},
 {u'benchmark_returns': 0.29471475406124736,
  u'returns': 0.10793240000000015,
  u'time': u'2015-05-18'},
 {u'benchmark_returns': 0.3388842588727694,
  u'returns': 0.10793240000000015,
  u'time': u'2015-05-19'},
 {u'benchmark_returns': 0.34559025159145995,
  u'returns': 0.10793240000000015,
  u'time': u'2015-05-20'},
 {u'benchmark_returns': 0.36994344462823014,
  u'returns': 0.10590119999999992,
  u'time': u'2015-05-21'},
 {u'benchmark_returns': 0.4011738387895991,
  u'returns': 0.13905119999999993,
  u'time': u'2015-05-22'},
 {u'benchmark_returns': 0.44310150394557546,
  u'returns': 0.16200119999999996,
  u'time': u'2015-05-25'},
 {u'benchmark_returns': 0.4712371293019648,
  u'returns': 0.1637012,
  u'time': u'2015-05-26'},
 {u'benchmark_returns': 0.46628934786576703,
  u'returns': 0.1535012,
  u'time': u'2015-05-27'},
 {u'benchmark_returns': 0.3679712935856274,
  u'returns': 0.08550119999999994,
  u'time': u'2015-05-28'},
 {u'benchmark_returns': 0.3699018452304308,
  u'returns': 0.08324559999999992,
  u'time': u'2015-05-29'},
 {u'benchmark_returns': 0.43650333007424225,
  u'returns': 0.08324559999999992,
  u'time': u'2015-06-01'},
 {u'benchmark_returns': 0.4607529491001654,
  u'returns': 0.08324559999999992,
  u'time': u'2015-06-02'},
 {u'benchmark_returns': 0.4555799083398304,
  u'returns': 0.08324559999999992,
  u'time': u'2015-06-03'},
 {u'benchmark_returns': 0.46628425406195495,
  u'returns': 0.11695119999999992,
  u'time': u'2015-06-04'},
 {u'benchmark_returns': 0.48018920651271113,
  u'returns': 0.11197119999999994,
  u'time': u'2015-06-05'},
 {u'benchmark_returns': 0.5150531807267444,
  u'returns': 0.18003119999999995,
  u'time': u'2015-06-08'},
 {u'benchmark_returns': 0.5047835062632564,
  u'returns': 0.15845120000000001,
  u'time': u'2015-06-09'},
 {u'benchmark_returns': 0.5024208302617226,
  u'returns': 0.13853119999999985,
  u'time': u'2015-06-10'},
 {u'benchmark_returns': 0.5017071317498207,
  u'returns': 0.1353951,
  u'time': u'2015-06-11'},
 {u'benchmark_returns': 0.5097793958465688,
  u'returns': 0.1353951,
  u'time': u'2015-06-12'},
 {u'benchmark_returns': 0.4775333538028783,
  u'returns': 0.1353951,
  u'time': u'2015-06-15'},
 {u'benchmark_returns': 0.43328913986877793,
  u'returns': 0.1353951,
  u'time': u'2015-06-16'},
 {u'benchmark_returns': 0.45423316320971896,
  u'returns': 0.1353951,
  u'time': u'2015-06-17'},
 {u'benchmark_returns': 0.39529162734297296,
  u'returns': 0.1353951,
  u'time': u'2015-06-18'},
 {u'benchmark_returns': 0.3122351752622248,
  u'returns': 0.1353951,
  u'time': u'2015-06-19'},
 {u'benchmark_returns': 0.35441158783769455,
  u'returns': 0.1353951,
  u'time': u'2015-06-23'},
 {u'benchmark_returns': 0.3810224679196481,
  u'returns': 0.1353951,
  u'time': u'2015-06-24'},
 {u'benchmark_returns': 0.3318927301514982,
  u'returns': 0.1353951,
  u'time': u'2015-06-25'},
 {u'benchmark_returns': 0.2270959234005101,
  u'returns': 0.1353951,
  u'time': u'2015-06-26'},
 {u'benchmark_returns': 0.18616268194430496,
  u'returns': 0.1353951,
  u'time': u'2015-06-29'},
 {u'benchmark_returns': 0.26580968134012317,
  u'returns': 0.1353951,
  u'time': u'2015-06-30'},
 {u'benchmark_returns': 0.20355858794098536,
  u'returns': 0.10049550000000007,
  u'time': u'2015-07-01'},
 {u'benchmark_returns': 0.16251809361562453,
  u'returns': 0.09619280000000008,
  u'time': u'2015-07-02'},
 {u'benchmark_returns': 0.09967215712686817,
  u'returns': 0.09619280000000008,
  u'time': u'2015-07-03'},
 {u'benchmark_returns': 0.13154238964486287,
  u'returns': 0.09619280000000008,
  u'time': u'2015-07-06'},
 {u'benchmark_returns': 0.11158203641786746,
  u'returns': 0.09619280000000008,
  u'time': u'2015-07-07'},
 {u'benchmark_returns': 0.03659982935757222,
  u'returns': 0.045945899999999984,
  u'time': u'2015-07-08'},
 {u'benchmark_returns': 0.10298567650666945,
  u'returns': 0.0436356,
  u'time': u'2015-07-09'},
 {u'benchmark_returns': 0.1621105893106527,
  u'returns': 0.11794490000000013,
  u'time': u'2015-07-10'},
 {u'benchmark_returns': 0.19189689009127808,
  u'returns': 0.08700490000000016,
  u'time': u'2015-07-13'},
 {u'benchmark_returns': 0.16369334735072694,
  u'returns': 0.044234899999999966,
  u'time': u'2015-07-14'},
 {u'benchmark_returns': 0.12254956200361944,
  u'returns': 0.02652880000000013,
  u'time': u'2015-07-15'},
 {u'benchmark_returns': 0.13120817951696595,
  u'returns': 0.02652880000000013,
  u'time': u'2015-07-16'},
 {u'benchmark_returns': 0.17482811949497767,
  u'returns': 0.02652880000000013,
  u'time': u'2015-07-17'},
 {u'benchmark_returns': 0.17740784813672916,
  u'returns': 0.02652880000000013,
  u'time': u'2015-07-20'},
 {u'benchmark_returns': 0.178934291345769,
  u'returns': 0.02652880000000013,
  u'time': u'2015-07-21'},
 {u'benchmark_returns': 0.17643096976119965,
  u'returns': 0.02652880000000013,
  u'time': u'2015-07-22'},
 {u'benchmark_returns': 0.20293148409389028,
  u'returns': 0.02652880000000013,
  u'time': u'2015-07-23'},
 {u'benchmark_returns': 0.18184143837700106,
  u'returns': 0.02652880000000013,
  u'time': u'2015-07-24'},
 {u'benchmark_returns': 0.08065925140893215,
  u'returns': 0.02652880000000013,
  u'time': u'2015-07-27'},
 {u'benchmark_returns': 0.07849778065797786,
  u'returns': 0.02652880000000013,
  u'time': u'2015-07-28'},
 {u'benchmark_returns': 0.11225441852107076,
  u'returns': 0.02652880000000013,
  u'time': u'2015-07-29'},
 {u'benchmark_returns': 0.0797200105837923,
  u'returns': 0.02652880000000013,
  u'time': u'2015-07-30'},
 {u'benchmark_returns': 0.08008421755636075,
  u'returns': 0.02652880000000013,
  u'time': u'2015-07-31'},
 {u'benchmark_returns': 0.08363176892241997,
  u'returns': 0.02652880000000013,
  u'time': u'2015-08-03'},
 {u'benchmark_returns': 0.11728483277466584,
  u'returns': 0.0320433,
  u'time': u'2015-08-04'},
 {u'benchmark_returns': 0.0942905533993359,
  u'returns': 0.010703300000000082,
  u'time': u'2015-08-05'},
 {u'benchmark_returns': 0.08437235139888588,
  u'returns': 0.005853299999999839,
  u'time': u'2015-08-06'},
 {u'benchmark_returns': 0.10562285193585774,
  u'returns': 0.009399399999999947,
  u'time': u'2015-08-07'},
 {u'benchmark_returns': 0.1558307781775785,
  u'returns': 0.009399399999999947,
  u'time': u'2015-08-10'},
 {u'benchmark_returns': 0.15082300305203744,
  u'returns': 0.002446999999999866,
  u'time': u'2015-08-11'},
 {u'benchmark_returns': 0.1365198849366318,
  u'returns': -0.018453000000000053,
  u'time': u'2015-08-12'},
 {u'benchmark_returns': 0.1533116092033715,
  u'returns': -0.025420099999999946,
  u'time': u'2015-08-13'},
 {u'benchmark_returns': 0.15276742116277386,
  u'returns': -0.025420099999999946,
  u'time': u'2015-08-14'},
 {u'benchmark_returns': 0.15399332994689718,
  u'returns': -0.025420099999999946,
  u'time': u'2015-08-17'},
 {u'benchmark_returns': 0.08254990159054021,
  u'returns': -0.025420099999999946,
  u'time': u'2015-08-18'},
 {u'benchmark_returns': 0.09973413173991608,
  u'returns': -0.025420099999999946,
  u'time': u'2015-08-19'},
 {u'benchmark_returns': 0.06445048468958214,
  u'returns': -0.025420099999999946,
  u'time': u'2015-08-20'},
 {u'benchmark_returns': 0.015799564479774153,
  u'returns': -0.025420099999999946,
  u'time': u'2015-08-21'},
 {u'benchmark_returns': -0.07305957911031047,
  u'returns': -0.025420099999999946,
  u'time': u'2015-08-24'},
 {u'benchmark_returns': -0.13888482485097076,
  u'returns': -0.025420099999999946,
  u'time': u'2015-08-25'},
 {u'benchmark_returns': -0.14376214200110082,
  u'returns': -0.025420099999999946,
  u'time': u'2015-08-26'},
 {u'benchmark_returns': -0.0928393852910755,
  u'returns': -0.025420099999999946,
  u'time': u'2015-08-27'},
 {u'benchmark_returns': -0.05416949066206711,
  u'returns': -0.03225279999999997,
  u'time': u'2015-08-28'},
 {u'benchmark_returns': -0.0473070049707035,
  u'returns': -0.01045280000000004,
  u'time': u'2015-08-31'},
 {u'benchmark_returns': -0.048567155436008314,
  u'returns': 0.03423719999999997,
  u'time': u'2015-09-01'},
 {u'benchmark_returns': -0.04750622929757864,
  u'returns': 0.05821720000000008,
  u'time': u'2015-09-02'},
 {u'benchmark_returns': -0.08014817309311328,
  u'returns': -0.026802800000000016,
  u'time': u'2015-09-07'},
 {u'benchmark_returns': -0.056507829600942916,
  u'returns': -0.030246799999999907,
  u'time': u'2015-09-08'},
 {u'benchmark_returns': -0.038033735130691415,
  u'returns': -0.030246799999999907,
  u'time': u'2015-09-09'},
 {u'benchmark_returns': -0.04984683214925967,
  u'returns': -0.030246799999999907,
  u'time': u'2015-09-10'},
 {u'benchmark_returns': -0.05278227809055924,
  u'returns': -0.030246799999999907,
  u'time': u'2015-09-11'},
 {u'benchmark_returns': -0.07147540612473302,
  u'returns': -0.030246799999999907,
  u'time': u'2015-09-14'},
 {u'benchmark_returns': -0.10795270120171319,
  u'returns': -0.030246799999999907,
  u'time': u'2015-09-15'},
 {u'benchmark_returns': -0.06351888457016075,
  u'returns': -0.030246799999999907,
  u'time': u'2015-09-16'},
 {u'benchmark_returns': -0.08396456410481357,
  u'returns': -0.030246799999999907,
  u'time': u'2015-09-17'},
 {u'benchmark_returns': -0.07992517768178153,
  u'returns': -0.030246799999999907,
  u'time': u'2015-09-18'},
 {u'benchmark_returns': -0.06380215665993627,
  u'returns': -0.030246799999999907,
  u'time': u'2015-09-21'},
 {u'benchmark_returns': -0.055090903173864225,
  u'returns': -0.030246799999999907,
  u'time': u'2015-09-22'},
 {u'benchmark_returns': -0.07659864080334955,
  u'returns': -0.0456561000000002,
  u'time': u'2015-09-23'},
 {u'benchmark_returns': -0.07038108727242376,
  u'returns': -0.04257580000000005,
  u'time': u'2015-09-24'},
 {u'benchmark_returns': -0.08539309308501986,
  u'returns': -0.04257580000000005,
  u'time': u'2015-09-25'},
 {u'benchmark_returns': -0.08233652780863143,
  u'returns': -0.04257580000000005,
  u'time': u'2015-09-28'},
 {u'benchmark_returns': -0.1004189653635491,
  u'returns': -0.04257580000000005,
  u'time': u'2015-09-29'},
 {u'benchmark_returns': -0.09360062597189067,
  u'returns': -0.04257580000000005,
  u'time': u'2015-09-30'},
 {u'benchmark_returns': -0.06713152342937512,
  u'returns': -0.04257580000000005,
  u'time': u'2015-10-08'},
 {u'benchmark_returns': -0.05478357701053138,
  u'returns': -0.030982200000000182,
  u'time': u'2015-10-09'},
 {u'benchmark_returns': -0.02434045852723976,
  u'returns': -0.001822199999999996,
  u'time': u'2015-10-12'},
 {u'benchmark_returns': -0.025090379644027938,
  u'returns': -0.010462199999999977,
  u'time': u'2015-10-13'},
 {u'benchmark_returns': -0.036107428322398105,
  u'returns': -0.02342220000000006,
  u'time': u'2015-10-14'},
 {u'benchmark_returns': -0.01326935893064074,
  u'returns': -0.029003,
  u'time': u'2015-10-15'},
 {u'benchmark_returns': 0.00010187607624301265,
  u'returns': -0.029003,
  u'time': u'2015-10-16'},
 {u'benchmark_returns': 0.00013498580102178082,
  u'returns': -0.029003,
  u'time': u'2015-10-19'},
 {u'benchmark_returns': 0.012450954451489249,
  u'returns': -0.029003,
  u'time': u'2015-10-20'},
 {u'benchmark_returns': -0.017106974124891594,
  u'returns': -0.0365724999999999,
  u'time': u'2015-10-21'},
 {u'benchmark_returns': -0.002595293042288449,
  u'returns': -0.035740399999999894,
  u'time': u'2015-10-22'},
 {u'benchmark_returns': 0.010622278882928882,
  u'returns': -0.035740399999999894,
  u'time': u'2015-10-23'},
 {u'benchmark_returns': 0.015721742477088574,
  u'returns': -0.0441094999999998,
  u'time': u'2015-10-26'},
 {u'benchmark_returns': 0.016745597043329896,
  u'returns': -0.0471395,
  u'time': u'2015-10-27'},
 {u'benchmark_returns': -0.0024860592494280187,
  u'returns': -0.06531949999999997,
  u'time': u'2015-10-28'},
 {u'benchmark_returns': -0.00011262966206859737,
  u'returns': -0.06451669999999998,
  u'time': u'2015-10-29'},
 {u'benchmark_returns': 0.00010583792365248534,
  u'returns': -0.06451669999999998,
  u'time': u'2015-10-30'},
 {u'benchmark_returns': -0.01634063964026422,
  u'returns': -0.06451669999999998,
  u'time': u'2015-11-02'},
 {u'benchmark_returns': -0.019303252535228577,
  u'returns': -0.06451669999999998,
  u'time': u'2015-11-03'},
 {u'benchmark_returns': 0.02683670538429217,
  u'returns': -0.06451669999999998,
  u'time': u'2015-11-04'},
 {u'benchmark_returns': 0.04874911742774213,
  u'returns': -0.02853720000000004,
  u'time': u'2015-11-05'},
 {u'benchmark_returns': 0.07348349678312127,
  u'returns': -0.003057199999999982,
  u'time': u'2015-11-06'},
 {u'benchmark_returns': 0.0867786077219237,
  u'returns': 0.04202280000000003,
  u'time': u'2015-11-09'},
 {u'benchmark_returns': 0.08476457429242101,
  u'returns': 0.02634279999999989,
  u'time': u'2015-11-10'},
 {u'benchmark_returns': 0.08488003384549647,
  u'returns': 0.010662799999999972,
  u'time': u'2015-11-11'},
 {u'benchmark_returns': 0.07403532552943726,
  u'returns': -0.0020772000000000013,
  u'time': u'2015-11-12'},
 {u'benchmark_returns': 0.06014565449011733,
  u'returns': -0.01903369999999993,
  u'time': u'2015-11-13'},
 {u'benchmark_returns': 0.06520663156658535,
  u'returns': -0.01903369999999993,
  u'time': u'2015-11-16'},
 {u'benchmark_returns': 0.06358255711781258,
  u'returns': -0.01903369999999993,
  u'time': u'2015-11-17'},
 {u'benchmark_returns': 0.051468642685226884,
  u'returns': -0.01903369999999993,
  u'time': u'2015-11-18'},
 {u'benchmark_returns': 0.06827508238520208,
  u'returns': -0.01903369999999993,
  u'time': u'2015-11-19'},
 {u'benchmark_returns': 0.06810925077220653,
  u'returns': -0.01903369999999993,
  u'time': u'2015-11-20'},
 {u'benchmark_returns': 0.062152896181203676,
  u'returns': -0.01903369999999993,
  u'time': u'2015-11-23'},
 {u'benchmark_returns': 0.062309672142977446,
  u'returns': -0.01903369999999993,
  u'time': u'2015-11-24'},
 {u'benchmark_returns': 0.07015356403548112,
  u'returns': -0.01903369999999993,
  u'time': u'2015-11-25'},
 {u'benchmark_returns': 0.06387743176071581,
  u'returns': -0.01903369999999993,
  u'time': u'2015-11-26'},
 {u'benchmark_returns': 0.006589967187413892,
  u'returns': -0.01903369999999993,
  u'time': u'2015-11-27'},
 {u'benchmark_returns': 0.00925572451577028,
  u'returns': -0.01903369999999993,
  u'time': u'2015-11-30'},
 {u'benchmark_returns': 0.016410820937231563,
  u'returns': -0.01903369999999993,
  u'time': u'2015-12-01'},
 {u'benchmark_returns': 0.053272698202028845,
  u'returns': -0.01903369999999993,
  u'time': u'2015-12-02'},
 {u'benchmark_returns': 0.061010752170880256,
  u'returns': -0.01548689999999997,
  u'time': u'2015-12-03'},
 {u'benchmark_returns': 0.04071845272879315,
  u'returns': -0.041406900000000024,
  u'time': u'2015-12-04'},
 {u'benchmark_returns': 0.04355258857205113,
  u'returns': -0.03852690000000003,
  u'time': u'2015-12-07'},
 {u'benchmark_returns': 0.025275171526768725,
  u'returns': -0.04744240000000011,
  u'time': u'2015-12-08'},
 {u'benchmark_returns': 0.028930824729285654,
  u'returns': -0.04744240000000011,
  u'time': u'2015-12-09'},
 {u'benchmark_returns': 0.02529328282921184,
  u'returns': -0.04744240000000011,
  u'time': u'2015-12-10'},
 {u'benchmark_returns': 0.021041371591573155,
  u'returns': -0.04744240000000011,
  u'time': u'2015-12-11'},
 {u'benchmark_returns': 0.05026367509455376,
  u'returns': -0.04744240000000011,
  u'time': u'2015-12-14'},
 {u'benchmark_returns': 0.04547182065282751,
  u'returns': -0.04744240000000011,
  u'time': u'2015-12-15'},
 {u'benchmark_returns': 0.042939351190888875,
  u'returns': -0.04744240000000011,
  u'time': u'2015-12-16'},
 {u'benchmark_returns': 0.06287536735522625,
  u'returns': -0.04744240000000011,
  u'time': u'2015-12-17'},
 {u'benchmark_returns': 0.06627831129084072,
  u'returns': -0.04744240000000011,
  u'time': u'2015-12-18'},
 {u'benchmark_returns': 0.09402595859020502,
  u'returns': -0.020176799999999884,
  u'time': u'2015-12-21'},
 {u'benchmark_returns': 0.09707318522627117,
  u'returns': -0.02587679999999981,
  u'time': u'2015-12-22'},
 {u'benchmark_returns': 0.0941436820560857,
  u'returns': -0.022076799999999897,
  u'time': u'2015-12-23'},
 {u'benchmark_returns': 0.0836790281022326,
  u'returns': -0.03347679999999975,
  u'time': u'2015-12-24'},
 {u'benchmark_returns': 0.08616904919907009,
  u'returns': -0.031881600000000065,
  u'time': u'2015-12-25'},
 {u'benchmark_returns': 0.05487922732655948,
  u'returns': -0.031881600000000065,
  u'time': u'2015-12-28'},
 {u'benchmark_returns': 0.06456962310096626,
  u'returns': -0.031881600000000065,
  u'time': u'2015-12-29'},
 {u'benchmark_returns': 0.0655034871331932,
  u'returns': -0.031881600000000065,
  u'time': u'2015-12-30'},
 {u'benchmark_returns': 0.05583374956313558,
  u'returns': -0.031881600000000065,
  u'time': u'2015-12-31'},
 {u'benchmark_returns': -0.018292132478517575,
  u'returns': -0.031881600000000065,
  u'time': u'2016-01-04'},
 {u'benchmark_returns': -0.015543176354562593,
  u'returns': -0.031881600000000065,
  u'time': u'2016-01-05'},
 {u'benchmark_returns': 0.001727082481418174,
  u'returns': -0.031881600000000065,
  u'time': u'2016-01-06'},
 {u'benchmark_returns': -0.06772523456259083,
  u'returns': -0.031881600000000065,
  u'time': u'2016-01-07'},
 {u'benchmark_returns': -0.04871430976835922,
  u'returns': -0.031881600000000065,
  u'time': u'2016-01-08'},
 {u'benchmark_returns': -0.09657144555077468,
  u'returns': -0.031881600000000065,
  u'time': u'2016-01-11'},
 {u'benchmark_returns': -0.08998911906907903,
  u'returns': -0.031881600000000065,
  u'time': u'2016-01-12'},
 {u'benchmark_returns': -0.10692063995155232,
  u'returns': -0.031881600000000065,
  u'time': u'2016-01-13'},
 {u'benchmark_returns': -0.08833051995002417,
  u'returns': -0.031881600000000065,
  u'time': u'2016-01-14'},
 {u'benchmark_returns': -0.11743340205251995,
  u'returns': -0.031881600000000065,
  u'time': u'2016-01-15'},
 {u'benchmark_returns': -0.11403784413243323,
  u'returns': -0.031881600000000065,
  u'time': u'2016-01-18'},
 {u'benchmark_returns': -0.08789072658866537,
  u'returns': -0.031881600000000065,
  u'time': u'2016-01-19'},
 {u'benchmark_returns': -0.10168559627925933,
  u'returns': -0.031881600000000065,
  u'time': u'2016-01-20'},
 {u'benchmark_returns': -0.12801283638560657,
  u'returns': -0.031881600000000065,
  u'time': u'2016-01-21'},
 {u'benchmark_returns': -0.11892401884141435,
  u'returns': -0.031881600000000065,
  u'time': u'2016-01-22'},
 {u'benchmark_returns': -0.11455936474606676,
  u'returns': -0.031881600000000065,
  u'time': u'2016-01-25'},
 {u'benchmark_returns': -0.16786814405843165,
  u'returns': -0.031881600000000065,
  u'time': u'2016-01-26'},
 {u'benchmark_returns': -0.17074232285943514,
  u'returns': -0.031881600000000065,
  u'time': u'2016-01-27'},
 {u'benchmark_returns': -0.19241809941690102,
  u'returns': -0.031881600000000065,
  u'time': u'2016-01-28'},
 {u'benchmark_returns': -0.16628858379519507,
  u'returns': -0.031881600000000065,
  u'time': u'2016-01-29'},
 {u'benchmark_returns': -0.17903512036233915,
  u'returns': -0.031881600000000065,
  u'time': u'2016-02-01'},
 {u'benchmark_returns': -0.161974839439059,
  u'returns': -0.031881600000000065,
  u'time': u'2016-02-02'},
 {u'benchmark_returns': -0.1655674143710354,
  u'returns': -0.031881600000000065,
  u'time': u'2016-02-03'},
 {u'benchmark_returns': -0.15534550846774142,
  u'returns': -0.031881600000000065,
  u'time': u'2016-02-04'},
 {u'benchmark_returns': -0.16127990310453189,
  u'returns': -0.031881600000000065,
  u'time': u'2016-02-05'},
 {u'benchmark_returns': -0.16611414931353918,
  u'returns': -0.031881600000000065,
  u'time': u'2016-02-15'},
 {u'benchmark_returns': -0.14055211173541649,
  u'returns': -0.031881600000000065,
  u'time': u'2016-02-16'},
 {u'benchmark_returns': -0.13311385641982,
  u'returns': -0.02281119999999992,
  u'time': u'2016-02-17'},
 {u'benchmark_returns': -0.1358366077530524,
  u'returns': -0.02749120000000005,
  u'time': u'2016-02-18'},
 {u'benchmark_returns': -0.13643470521732848,
  u'returns': -0.03334119999999996,
  u'time': u'2016-02-19'},
 {u'benchmark_returns': -0.11739449105117716,
  u'returns': -0.00877120000000009,
  u'time': u'2016-02-22'},
 {u'benchmark_returns': -0.1257438863742163,
  u'returns': -0.02515119999999993,
  u'time': u'2016-02-23'},
 {u'benchmark_returns': -0.12003254374657757,
  u'returns': -0.03342600000000007,
  u'time': u'2016-02-24'},
 {u'benchmark_returns': -0.17402553410655386,
  u'returns': -0.03342600000000007,
  u'time': u'2016-02-25'},
 {u'benchmark_returns': -0.16573947174424575,
  u'returns': -0.03342600000000007,
  u'time': u'2016-02-26'},
 {u'benchmark_returns': -0.1857083146442614,
  u'returns': -0.03342600000000007,
  u'time': u'2016-02-29'},
 {u'benchmark_returns': -0.17064562548373452,
  u'returns': -0.03342600000000007,
  u'time': u'2016-03-01'},
 {u'benchmark_returns': -0.13650610336742885,
  u'returns': -0.03342600000000007,
  u'time': u'2016-03-02'},
 {u'benchmark_returns': -0.13449993703492513,
  u'returns': -0.03371479999999982,
  u'time': u'2016-03-03'},
 {u'benchmark_returns': -0.12446299280783191,
  u'returns': -0.005874800000000069,
  u'time': u'2016-03-04'},
 {u'benchmark_returns': -0.12136420555762295,
  u'returns': -0.011674799999999985,
  u'time': u'2016-03-07'},
 {u'benchmark_returns': -0.12056249743541125,
  u'returns': -0.017474800000000013,
  u'time': u'2016-03-08'},
 {u'benchmark_returns': -0.13068380071341545,
  u'returns': -0.027914799999999906,
  u'time': u'2016-03-09'},
 {u'benchmark_returns': -0.14731260815489688,
  u'returns': -0.023381499999999944,
  u'time': u'2016-03-10'},
 {u'benchmark_returns': -0.14585841206325934,
  u'returns': -0.023381499999999944,
  u'time': u'2016-03-11'},
 {u'benchmark_returns': -0.1324430307566704,
  u'returns': -0.023381499999999944,
  u'time': u'2016-03-14'},
 {u'benchmark_returns': -0.12987088622281717,
  u'returns': -0.023381499999999944,
  u'time': u'2016-03-15'},
 {u'benchmark_returns': -0.12555439687240444,
  u'returns': -0.016772700000000085,
  u'time': u'2016-03-16'},
 {u'benchmark_returns': -0.11588434801433622,
  u'returns': -0.009872700000000068,
  u'time': u'2016-03-17'},
 {u'benchmark_returns': -0.10236904325629892,
  u'returns': 0.0004773000000000138,
  u'time': u'2016-03-18'},
 {u'benchmark_returns': -0.08044468907280033,
  u'returns': 0.025777299999999892,
  u'time': u'2016-03-21'},
 {u'benchmark_returns': -0.08713650403754691,
  u'returns': 0.0177273,
  u'time': u'2016-03-22'},
 {u'benchmark_returns': -0.0842211220234852,
  u'returns': 0.016577299999999795,
  u'time': u'2016-03-23'},
 {u'benchmark_returns': -0.09957093192555688,
  u'returns': -0.0006727000000000816,
  u'time': u'2016-03-24'},
 {u'benchmark_returns': -0.09505267134636308,
  u'returns': -0.004261399999999971,
  u'time': u'2016-03-25'},
 {u'benchmark_returns': -0.10300143899957681,
  u'returns': -0.004261399999999971,
  u'time': u'2016-03-28'},
 {u'benchmark_returns': -0.11271320045108468,
  u'returns': -0.004261399999999971,
  u'time': u'2016-03-29'},
 {u'benchmark_returns': -0.0898291453304676,
  u'returns': -0.004261399999999971,
  u'time': u'2016-03-30'},
 {u'benchmark_returns': -0.08931619928658441,
  u'returns': -0.011339700000000064,
  u'time': u'2016-03-31'},
 {u'benchmark_returns': -0.08823888807922564,
  u'returns': -0.010209699999999988,
  u'time': u'2016-04-01'},
 {u'benchmark_returns': -0.07618609929238573,
  u'returns': -0.005689700000000131,
  u'time': u'2016-04-05'},
 {u'benchmark_returns': -0.0781551940527011,
  u'returns': -0.004559699999999833,
  u'time': u'2016-04-06'},
 {u'benchmark_returns': -0.0918058524975911,
  u'returns': -0.015859700000000143,
  u'time': u'2016-04-07'},
 {u'benchmark_returns': -0.09847432086153196,
  u'returns': -0.022780399999999923,
  u'time': u'2016-04-08'},
 {u'benchmark_returns': -0.08591812276350175,
  u'returns': -0.022780399999999923,
  u'time': u'2016-04-11'},
 {u'benchmark_returns': -0.0892138138299603,
  u'returns': -0.022780399999999923,
  u'time': u'2016-04-12'},
 {u'benchmark_returns': -0.07706412957504938,
  u'returns': -0.022780399999999923,
  u'time': u'2016-04-13'},
 {u'benchmark_returns': -0.07297522005939938,
  u'returns': -0.027432700000000088,
  u'time': u'2016-04-14'},
 {u'benchmark_returns': -0.07400156492972665,
  u'returns': -0.024162700000000092,
  u'time': u'2016-04-15'},
 {u'benchmark_returns': -0.08638296066027007,
  u'returns': -0.03724270000000007,
  u'time': u'2016-04-18'},
 {u'benchmark_returns': -0.08359557461644362,
  u'returns': -0.03631390000000001,
  u'time': u'2016-04-19'},
 {u'benchmark_returns': -0.099804199841243,
  u'returns': -0.03631390000000001,
  u'time': u'2016-04-20'},
 {u'benchmark_returns': -0.10558371454323434,
  u'returns': -0.03631390000000001,
  u'time': u'2016-04-21'},
 {u'benchmark_returns': -0.10153756468069641,
  u'returns': -0.03631390000000001,
  u'time': u'2016-04-22'},
 {u'benchmark_returns': -0.10517909672708947,
  u'returns': -0.03631390000000001,
  u'time': u'2016-04-25'},
 {u'benchmark_returns': -0.10033222920419216,
  u'returns': -0.03631390000000001,
  u'time': u'2016-04-26'},
 {u'benchmark_returns': -0.10408039154371973,
  u'returns': -0.03631390000000001,
  u'time': u'2016-04-27'},
 {u'benchmark_returns': -0.10559005349908945,
  u'returns': -0.03631390000000001,
  u'time': u'2016-04-28'},
 {u'benchmark_returns': -0.10667554309145777,
  u'returns': -0.03631390000000001,
  u'time': u'2016-04-29'},
 {u'benchmark_returns': -0.09060329031427361,
  u'returns': -0.03631390000000001,
  u'time': u'2016-05-03'},
 {u'benchmark_returns': -0.09175740476355543,
  u'returns': -0.03631390000000001,
  u'time': u'2016-05-04'},
 {u'benchmark_returns': -0.090495697858197,
  u'returns': -0.03631390000000001,
  u'time': u'2016-05-05'},
 {u'benchmark_returns': -0.1141438235506359,
  u'returns': -0.03631390000000001,
  u'time': u'2016-05-06'},
 {u'benchmark_returns': -0.13246425493922098,
  u'returns': -0.03631390000000001,
  u'time': u'2016-05-09'},
 {u'benchmark_returns': -0.13147464205416126,
  u'returns': -0.03631390000000001,
  u'time': u'2016-05-10'},
 {u'benchmark_returns': -0.12759876673349924,
  u'returns': -0.03631390000000001,
  u'time': u'2016-05-11'},
 {u'benchmark_returns': -0.1255248528102939,
  u'returns': -0.03631390000000001,
  u'time': u'2016-05-12'},
 {u'benchmark_returns': -0.1298268814176622,
  u'returns': -0.03631390000000001,
  u'time': u'2016-05-13'},
 {u'benchmark_returns': -0.1240614312739744,
  u'returns': -0.03631390000000001,
  u'time': u'2016-05-16'},
 {u'benchmark_returns': -0.12668858888899892,
  u'returns': -0.03631390000000001,
  u'time': u'2016-05-17'},
 {u'benchmark_returns': -0.13177930811994776,
  u'returns': -0.03631390000000001,
  u'time': u'2016-05-18'},
 {u'benchmark_returns': -0.1333458225856431,
  u'returns': -0.03631390000000001,
  u'time': u'2016-05-19'},
 {u'benchmark_returns': -0.12889777160232674,
  u'returns': -0.03631390000000001,
  u'time': u'2016-05-20'},
 {u'benchmark_returns': -0.12634968114203082,
  u'returns': -0.03631390000000001,
  u'time': u'2016-05-23'},
 {u'benchmark_returns': -0.1330471558887909,
  u'returns': -0.03631390000000001,
  u'time': u'2016-05-24'},
 {u'benchmark_returns': -0.1342724137979826,
  u'returns': -0.03631390000000001,
  u'time': u'2016-05-25'},
 {u'benchmark_returns': -0.13286165653329862,
  u'returns': -0.03631390000000001,
  u'time': u'2016-05-26'},
 {u'benchmark_returns': -0.1333460772758337,
  u'returns': -0.03631390000000001,
  u'time': u'2016-05-27'},
 {u'benchmark_returns': -0.1321546365641727,
  u'returns': -0.03631390000000001,
  u'time': u'2016-05-30'},
 {u'benchmark_returns': -0.10304912266304067,
  u'returns': -0.03631390000000001,
  u'time': u'2016-05-31'},
 {u'benchmark_returns': -0.10559964682960232,
  u'returns': -0.03993160000000007,
  u'time': u'2016-06-01'}]
gt.get_positions()     # 获取所有持仓列表
[{u'amount': 10200,
  u'avg_cost': 10.775686274509804,
  u'closeable_amount': 10200,
  u'price': 10.87,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-01-05'},
 {u'amount': 10200,
  u'avg_cost': 10.775686274509804,
  u'closeable_amount': 10200,
  u'price': 10.7,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-01-06'},
 {u'amount': 10200,
  u'avg_cost': 10.775686274509804,
  u'closeable_amount': 10200,
  u'price': 10.5,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-01-07'},
 {u'amount': 10200,
  u'avg_cost': 10.46,
  u'closeable_amount': 10200,
  u'price': 10.43,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-01-16'},
 {u'amount': 10200,
  u'avg_cost': 10.46,
  u'closeable_amount': 10200,
  u'price': 9.38,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-01-19'},
 {u'amount': 9800,
  u'avg_cost': 9.75,
  u'closeable_amount': 9800,
  u'price': 9.73,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-01-26'},
 {u'amount': 9800,
  u'avg_cost': 9.75,
  u'closeable_amount': 9800,
  u'price': 9.49,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-01-27'},
 {u'amount': 9700,
  u'avg_cost': 9.46,
  u'closeable_amount': 9700,
  u'price': 9.46,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-02-13'},
 {u'amount': 9700,
  u'avg_cost': 9.46,
  u'closeable_amount': 9700,
  u'price': 9.44,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-02-16'},
 {u'amount': 9700,
  u'avg_cost': 9.46,
  u'closeable_amount': 9700,
  u'price': 9.49,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-02-17'},
 {u'amount': 9700,
  u'avg_cost': 9.46,
  u'closeable_amount': 9700,
  u'price': 9.36,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-02-25'},
 {u'amount': 9500,
  u'avg_cost': 9.51,
  u'closeable_amount': 9500,
  u'price': 9.34,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-03-10'},
 {u'amount': 9500,
  u'avg_cost': 9.51,
  u'closeable_amount': 9500,
  u'price': 9.4,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-03-11'},
 {u'amount': 9500,
  u'avg_cost': 9.51,
  u'closeable_amount': 9500,
  u'price': 9.9,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-03-12'},
 {u'amount': 9500,
  u'avg_cost': 9.51,
  u'closeable_amount': 9500,
  u'price': 10.17,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-03-13'},
 {u'amount': 9500,
  u'avg_cost': 9.51,
  u'closeable_amount': 9500,
  u'price': 10.45,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-03-16'},
 {u'amount': 9500,
  u'avg_cost': 9.51,
  u'closeable_amount': 9500,
  u'price': 10.45,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-03-17'},
 {u'amount': 9500,
  u'avg_cost': 9.51,
  u'closeable_amount': 9500,
  u'price': 10.52,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-03-18'},
 {u'amount': 9500,
  u'avg_cost': 9.51,
  u'closeable_amount': 9500,
  u'price': 10.3,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-03-19'},
 {u'amount': 9000,
  u'avg_cost': 10.89,
  u'closeable_amount': 9000,
  u'price': 10.68,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-03-31'},
 {u'amount': 9000,
  u'avg_cost': 10.89,
  u'closeable_amount': 9000,
  u'price': 10.83,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-04-01'},
 {u'amount': 9000,
  u'avg_cost': 10.89,
  u'closeable_amount': 9000,
  u'price': 10.72,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-04-02'},
 {u'amount': 9000,
  u'avg_cost': 10.89,
  u'closeable_amount': 9000,
  u'price': 10.75,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-04-03'},
 {u'amount': 9000,
  u'avg_cost': 10.89,
  u'closeable_amount': 9000,
  u'price': 11.4,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-04-07'},
 {u'amount': 9000,
  u'avg_cost': 10.89,
  u'closeable_amount': 9000,
  u'price': 12.16,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-04-08'},
 {u'amount': 9000,
  u'avg_cost': 10.89,
  u'closeable_amount': 9000,
  u'price': 12.21,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-04-09'},
 {u'amount': 9000,
  u'avg_cost': 10.89,
  u'closeable_amount': 9000,
  u'price': 13.43,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-04-10'},
 {u'amount': 9000,
  u'avg_cost': 10.89,
  u'closeable_amount': 9000,
  u'price': 13.58,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-04-13'},
 {u'amount': 9000,
  u'avg_cost': 10.89,
  u'closeable_amount': 9000,
  u'price': 13.38,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-04-14'},
 {u'amount': 9000,
  u'avg_cost': 10.89,
  u'closeable_amount': 9000,
  u'price': 13.67,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-04-15'},
 {u'amount': 9000,
  u'avg_cost': 10.89,
  u'closeable_amount': 9000,
  u'price': 13.96,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-04-16'},
 {u'amount': 9000,
  u'avg_cost': 10.89,
  u'closeable_amount': 9000,
  u'price': 13.9,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-04-17'},
 {u'amount': 9000,
  u'avg_cost': 10.89,
  u'closeable_amount': 9000,
  u'price': 13.38,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-04-20'},
 {u'amount': 8600,
  u'avg_cost': 13.96,
  u'closeable_amount': 8600,
  u'price': 13.68,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-04-23'},
 {u'amount': 8300,
  u'avg_cost': 13.73,
  u'closeable_amount': 8300,
  u'price': 13.56,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-05-04'},
 {u'amount': 8500,
  u'avg_cost': 13.14,
  u'closeable_amount': 8500,
  u'price': 13.11,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-05-12'},
 {u'amount': 8500,
  u'avg_cost': 13.14,
  u'closeable_amount': 8500,
  u'price': 13.04,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-05-13'},
 {u'amount': 8500,
  u'avg_cost': 13.14,
  u'closeable_amount': 8500,
  u'price': 13.05,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-05-14'},
 {u'amount': 8500,
  u'avg_cost': 12.99,
  u'closeable_amount': 8500,
  u'price': 12.97,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-05-21'},
 {u'amount': 8500,
  u'avg_cost': 12.99,
  u'closeable_amount': 8500,
  u'price': 13.36,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-05-22'},
 {u'amount': 8500,
  u'avg_cost': 12.99,
  u'closeable_amount': 8500,
  u'price': 13.63,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-05-25'},
 {u'amount': 8500,
  u'avg_cost': 12.99,
  u'closeable_amount': 8500,
  u'price': 13.65,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-05-26'},
 {u'amount': 8500,
  u'avg_cost': 12.99,
  u'closeable_amount': 8500,
  u'price': 13.53,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-05-27'},
 {u'amount': 8500,
  u'avg_cost': 12.99,
  u'closeable_amount': 8500,
  u'price': 12.73,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-05-28'},
 {u'amount': 8300,
  u'avg_cost': 13.03,
  u'closeable_amount': 8300,
  u'price': 13.44,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-06-04'},
 {u'amount': 8300,
  u'avg_cost': 13.03,
  u'closeable_amount': 8300,
  u'price': 13.38,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-06-05'},
 {u'amount': 8300,
  u'avg_cost': 13.03,
  u'closeable_amount': 8300,
  u'price': 14.2,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-06-08'},
 {u'amount': 8300,
  u'avg_cost': 13.03,
  u'closeable_amount': 8300,
  u'price': 13.94,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-06-09'},
 {u'amount': 8300,
  u'avg_cost': 13.03,
  u'closeable_amount': 8300,
  u'price': 13.7,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-06-10'},
 {u'amount': 9600,
  u'avg_cost': 11.79,
  u'closeable_amount': 9600,
  u'price': 11.43,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-07-01'},
 {u'amount': 9600,
  u'avg_cost': 11.35,
  u'closeable_amount': 9600,
  u'price': 10.83,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-07-08'},
 {u'amount': 9100,
  u'avg_cost': 11.38,
  u'closeable_amount': 9100,
  u'price': 12.2,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-07-10'},
 {u'amount': 9100,
  u'avg_cost': 11.38,
  u'closeable_amount': 9100,
  u'price': 11.86,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-07-13'},
 {u'amount': 9100,
  u'avg_cost': 11.38,
  u'closeable_amount': 9100,
  u'price': 11.39,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-07-14'},
 {u'amount': 9700,
  u'avg_cost': 10.5,
  u'closeable_amount': 9700,
  u'price': 10.56,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-08-04'},
 {u'amount': 9700,
  u'avg_cost': 10.5,
  u'closeable_amount': 9700,
  u'price': 10.34,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-08-05'},
 {u'amount': 9700,
  u'avg_cost': 10.5,
  u'closeable_amount': 9700,
  u'price': 10.29,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-08-06'},
 {u'amount': 9500,
  u'avg_cost': 10.61,
  u'closeable_amount': 9500,
  u'price': 10.54,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-08-11'},
 {u'amount': 9500,
  u'avg_cost': 10.61,
  u'closeable_amount': 9500,
  u'price': 10.32,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-08-12'},
 {u'amount': 10900,
  u'avg_cost': 8.95,
  u'closeable_amount': 10900,
  u'price': 8.89,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-08-28'},
 {u'amount': 10900,
  u'avg_cost': 8.95,
  u'closeable_amount': 10900,
  u'price': 9.09,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-08-31'},
 {u'amount': 10900,
  u'avg_cost': 8.95,
  u'closeable_amount': 10900,
  u'price': 9.5,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-09-01'},
 {u'amount': 10900,
  u'avg_cost': 8.95,
  u'closeable_amount': 10900,
  u'price': 9.72,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-09-02'},
 {u'amount': 10900,
  u'avg_cost': 8.95,
  u'closeable_amount': 10900,
  u'price': 8.94,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-09-07'},
 {u'amount': 10800,
  u'avg_cost': 8.93,
  u'closeable_amount': 10800,
  u'price': 8.79,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-09-23'},
 {u'amount': 10800,
  u'avg_cost': 8.84,
  u'closeable_amount': 10800,
  u'price': 8.95,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-10-09'},
 {u'amount': 10800,
  u'avg_cost': 8.84,
  u'closeable_amount': 10800,
  u'price': 9.22,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-10-12'},
 {u'amount': 10800,
  u'avg_cost': 8.84,
  u'closeable_amount': 10800,
  u'price': 9.14,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-10-13'},
 {u'amount': 10800,
  u'avg_cost': 8.84,
  u'closeable_amount': 10800,
  u'price': 9.02,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-10-14'},
 {u'amount': 10400,
  u'avg_cost': 9.28,
  u'closeable_amount': 10400,
  u'price': 9.21,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-10-21'},
 {u'amount': 10100,
  u'avg_cost': 9.54,
  u'closeable_amount': 10100,
  u'price': 9.46,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-10-26'},
 {u'amount': 10100,
  u'avg_cost': 9.54,
  u'closeable_amount': 10100,
  u'price': 9.43,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-10-27'},
 {u'amount': 10100,
  u'avg_cost': 9.54,
  u'closeable_amount': 10100,
  u'price': 9.25,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-10-28'},
 {u'amount': 9800,
  u'avg_cost': 9.54,
  u'closeable_amount': 9800,
  u'price': 9.91,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-11-05'},
 {u'amount': 9800,
  u'avg_cost': 9.54,
  u'closeable_amount': 9800,
  u'price': 10.17,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-11-06'},
 {u'amount': 9800,
  u'avg_cost': 9.54,
  u'closeable_amount': 9800,
  u'price': 10.63,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-11-09'},
 {u'amount': 9800,
  u'avg_cost': 9.54,
  u'closeable_amount': 9800,
  u'price': 10.47,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-11-10'},
 {u'amount': 9800,
  u'avg_cost': 9.54,
  u'closeable_amount': 9800,
  u'price': 10.31,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-11-11'},
 {u'amount': 9800,
  u'avg_cost': 9.54,
  u'closeable_amount': 9800,
  u'price': 10.18,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-11-12'},
 {u'amount': 9600,
  u'avg_cost': 10.18,
  u'closeable_amount': 9600,
  u'price': 10.22,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-12-03'},
 {u'amount': 9600,
  u'avg_cost': 10.18,
  u'closeable_amount': 9600,
  u'price': 9.95,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-12-04'},
 {u'amount': 9600,
  u'avg_cost': 10.18,
  u'closeable_amount': 9600,
  u'price': 9.98,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-12-07'},
 {u'amount': 9500,
  u'avg_cost': 9.98,
  u'closeable_amount': 9500,
  u'price': 10.27,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-12-21'},
 {u'amount': 9500,
  u'avg_cost': 9.98,
  u'closeable_amount': 9500,
  u'price': 10.21,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-12-22'},
 {u'amount': 9500,
  u'avg_cost': 9.98,
  u'closeable_amount': 9500,
  u'price': 10.25,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-12-23'},
 {u'amount': 9500,
  u'avg_cost': 9.98,
  u'closeable_amount': 9500,
  u'price': 10.13,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-12-24'},
 {u'amount': 11700,
  u'avg_cost': 8.25,
  u'closeable_amount': 11700,
  u'price': 8.33,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-02-17'},
 {u'amount': 11700,
  u'avg_cost': 8.25,
  u'closeable_amount': 11700,
  u'price': 8.29,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-02-18'},
 {u'amount': 11700,
  u'avg_cost': 8.25,
  u'closeable_amount': 11700,
  u'price': 8.24,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-02-19'},
 {u'amount': 11700,
  u'avg_cost': 8.25,
  u'closeable_amount': 11700,
  u'price': 8.45,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-02-22'},
 {u'amount': 11700,
  u'avg_cost': 8.25,
  u'closeable_amount': 11700,
  u'price': 8.31,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-02-23'},
 {u'amount': 11600,
  u'avg_cost': 8.3,
  u'closeable_amount': 11600,
  u'price': 8.3,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-03-03'},
 {u'amount': 11600,
  u'avg_cost': 8.3,
  u'closeable_amount': 11600,
  u'price': 8.54,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-03-04'},
 {u'amount': 11600,
  u'avg_cost': 8.3,
  u'closeable_amount': 11600,
  u'price': 8.49,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-03-07'},
 {u'amount': 11600,
  u'avg_cost': 8.3,
  u'closeable_amount': 11600,
  u'price': 8.44,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-03-08'},
 {u'amount': 11600,
  u'avg_cost': 8.3,
  u'closeable_amount': 11600,
  u'price': 8.35,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-03-09'},
 {u'amount': 11500,
  u'avg_cost': 8.44,
  u'closeable_amount': 11500,
  u'price': 8.5,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-03-16'},
 {u'amount': 11500,
  u'avg_cost': 8.44,
  u'closeable_amount': 11500,
  u'price': 8.56,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-03-17'},
 {u'amount': 11500,
  u'avg_cost': 8.44,
  u'closeable_amount': 11500,
  u'price': 8.65,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-03-18'},
 {u'amount': 11500,
  u'avg_cost': 8.44,
  u'closeable_amount': 11500,
  u'price': 8.87,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-03-21'},
 {u'amount': 11500,
  u'avg_cost': 8.44,
  u'closeable_amount': 11500,
  u'price': 8.8,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-03-22'},
 {u'amount': 11500,
  u'avg_cost': 8.44,
  u'closeable_amount': 11500,
  u'price': 8.79,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-03-23'},
 {u'amount': 11500,
  u'avg_cost': 8.44,
  u'closeable_amount': 11500,
  u'price': 8.64,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-03-24'},
 {u'amount': 11300,
  u'avg_cost': 8.8,
  u'closeable_amount': 11300,
  u'price': 8.74,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-03-31'},
 {u'amount': 11300,
  u'avg_cost': 8.8,
  u'closeable_amount': 11300,
  u'price': 8.75,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-04-01'},
 {u'amount': 11300,
  u'avg_cost': 8.8,
  u'closeable_amount': 11300,
  u'price': 8.79,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-04-05'},
 {u'amount': 11300,
  u'avg_cost': 8.8,
  u'closeable_amount': 11300,
  u'price': 8.8,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-04-06'},
 {u'amount': 11300,
  u'avg_cost': 8.8,
  u'closeable_amount': 11300,
  u'price': 8.7,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-04-07'},
 {u'amount': 10900,
  u'avg_cost': 8.94,
  u'closeable_amount': 10900,
  u'price': 8.9,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-04-14'},
 {u'amount': 10900,
  u'avg_cost': 8.94,
  u'closeable_amount': 10900,
  u'price': 8.93,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-04-15'},
 {u'amount': 10900,
  u'avg_cost': 8.94,
  u'closeable_amount': 10900,
  u'price': 8.81,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-04-18'},
 {u'amount': 11100,
  u'avg_cost': 8.64,
  u'closeable_amount': 11100,
  u'price': 8.61,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-06-01'}]
gt.get_orders()        # 获取交易列表
[{u'action': u'open',
  u'amount': 9200,
  u'commission': 29.97,
  u'filled': 9200,
  u'price': 10.86,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-01-05 09:30:00'},
 {u'action': u'close',
  u'amount': 10200,
  u'commission': 139.23,
  u'filled': 10200,
  u'price': 10.5,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-01-08 09:30:00'},
 {u'action': u'open',
  u'amount': 10200,
  u'commission': 32.01,
  u'filled': 10200,
  u'price': 10.46,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-01-16 09:30:00'},
 {u'action': u'close',
  u'amount': 10200,
  u'commission': 124.25,
  u'filled': 10200,
  u'price': 9.37,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-01-20 09:30:00'},
 {u'action': u'open',
  u'amount': 9800,
  u'commission': 28.67,
  u'filled': 9800,
  u'price': 9.75,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-01-26 09:30:00'},
 {u'action': u'close',
  u'amount': 9800,
  u'commission': 119.76,
  u'filled': 9800,
  u'price': 9.4,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-01-28 09:30:00'},
 {u'action': u'open',
  u'amount': 9700,
  u'commission': 27.53,
  u'filled': 9700,
  u'price': 9.46,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-02-13 09:30:00'},
 {u'action': u'close',
  u'amount': 9700,
  u'commission': 117.9,
  u'filled': 9700,
  u'price': 9.35,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-02-26 09:30:00'},
 {u'action': u'open',
  u'amount': 9500,
  u'commission': 27.1,
  u'filled': 9500,
  u'price': 9.51,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-03-10 09:30:00'},
 {u'action': u'close',
  u'amount': 9500,
  u'commission': 127.08,
  u'filled': 9500,
  u'price': 10.29,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-03-20 09:30:00'},
 {u'action': u'open',
  u'amount': 9000,
  u'commission': 29.4,
  u'filled': 9000,
  u'price': 10.89,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-03-31 09:30:00'},
 {u'action': u'close',
  u'amount': 9000,
  u'commission': 156.55,
  u'filled': 9000,
  u'price': 13.38,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-04-21 09:30:00'},
 {u'action': u'open',
  u'amount': 8600,
  u'commission': 36.02,
  u'filled': 8600,
  u'price': 13.96,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-04-23 09:30:00'},
 {u'action': u'close',
  u'amount': 8600,
  u'commission': 149.36,
  u'filled': 8600,
  u'price': 13.36,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-04-24 09:30:00'},
 {u'action': u'open',
  u'amount': 8300,
  u'commission': 34.19,
  u'filled': 8300,
  u'price': 13.73,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-05-04 09:30:00'},
 {u'action': u'close',
  u'amount': 8300,
  u'commission': 145.13,
  u'filled': 8300,
  u'price': 13.45,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-05-05 09:30:00'},
 {u'action': u'open',
  u'amount': 8500,
  u'commission': 33.51,
  u'filled': 8500,
  u'price': 13.14,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-05-12 09:30:00'},
 {u'action': u'close',
  u'amount': 8500,
  u'commission': 143.1,
  u'filled': 8500,
  u'price': 12.95,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-05-15 09:30:00'},
 {u'action': u'open',
  u'amount': 8500,
  u'commission': 33.12,
  u'filled': 8500,
  u'price': 12.99,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-05-21 09:30:00'},
 {u'action': u'close',
  u'amount': 8500,
  u'commission': 140.56,
  u'filled': 8500,
  u'price': 12.72,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-05-29 09:30:00'},
 {u'action': u'open',
  u'amount': 8300,
  u'commission': 32.44,
  u'filled': 8300,
  u'price': 13.03,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-06-04 09:30:00'},
 {u'action': u'close',
  u'amount': 8300,
  u'commission': 147.61,
  u'filled': 8300,
  u'price': 13.68,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-06-11 09:30:00'},
 {u'action': u'open',
  u'amount': 9600,
  u'commission': 33.96,
  u'filled': 9600,
  u'price': 11.79,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-07-01 09:30:00'},
 {u'action': u'close',
  u'amount': 9600,
  u'commission': 142.27,
  u'filled': 9600,
  u'price': 11.4,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-07-02 09:30:00'},
 {u'action': u'open',
  u'amount': 9600,
  u'commission': 32.69,
  u'filled': 9600,
  u'price': 11.35,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-07-08 09:30:00'},
 {u'action': u'close',
  u'amount': 9600,
  u'commission': 135.03,
  u'filled': 9600,
  u'price': 10.82,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-07-09 09:30:00'},
 {u'action': u'open',
  u'amount': 9100,
  u'commission': 31.07,
  u'filled': 9100,
  u'price': 11.38,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-07-10 09:30:00'},
 {u'action': u'close',
  u'amount': 9100,
  u'commission': 132.61,
  u'filled': 9100,
  u'price': 11.21,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-07-15 09:30:00'},
 {u'action': u'open',
  u'amount': 9700,
  u'commission': 30.55,
  u'filled': 9700,
  u'price': 10.5,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-08-04 09:30:00'},
 {u'action': u'close',
  u'amount': 9700,
  u'commission': 130.39,
  u'filled': 9700,
  u'price': 10.34,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-08-07 09:30:00'},
 {u'action': u'open',
  u'amount': 9500,
  u'commission': 30.24,
  u'filled': 9500,
  u'price': 10.61,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-08-11 09:30:00'},
 {u'action': u'close',
  u'amount': 9500,
  u'commission': 126.71,
  u'filled': 9500,
  u'price': 10.26,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-08-13 09:30:00'},
 {u'action': u'open',
  u'amount': 10900,
  u'commission': 29.27,
  u'filled': 10900,
  u'price': 8.95,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-08-28 09:30:00'},
 {u'action': u'close',
  u'amount': 10900,
  u'commission': 126.4,
  u'filled': 10900,
  u'price': 8.92,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-09-08 09:30:00'},
 {u'action': u'open',
  u'amount': 10800,
  u'commission': 28.93,
  u'filled': 10800,
  u'price': 8.93,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-09-23 09:30:00'},
 {u'action': u'close',
  u'amount': 10800,
  u'commission': 123.97,
  u'filled': 10800,
  u'price': 8.83,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-09-24 09:30:00'},
 {u'action': u'open',
  u'amount': 10800,
  u'commission': 28.64,
  u'filled': 10800,
  u'price': 8.84,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-10-09 09:30:00'},
 {u'action': u'close',
  u'amount': 10800,
  u'commission': 126.08,
  u'filled': 10800,
  u'price': 8.98,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-10-15 09:30:00'},
 {u'action': u'open',
  u'amount': 10400,
  u'commission': 28.95,
  u'filled': 10400,
  u'price': 9.28,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-10-21 09:30:00'},
 {u'action': u'close',
  u'amount': 10400,
  u'commission': 124.79,
  u'filled': 10400,
  u'price': 9.23,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-10-22 09:30:00'},
 {u'action': u'open',
  u'amount': 10100,
  u'commission': 28.91,
  u'filled': 10100,
  u'price': 9.54,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-10-26 09:30:00'},
 {u'action': u'close',
  u'amount': 10100,
  u'commission': 121.72,
  u'filled': 10100,
  u'price': 9.27,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-10-29 09:30:00'},
 {u'action': u'open',
  u'amount': 9800,
  u'commission': 28.05,
  u'filled': 9800,
  u'price': 9.54,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-11-05 09:30:00'},
 {u'action': u'close',
  u'amount': 9800,
  u'commission': 127.65,
  u'filled': 9800,
  u'price': 10.02,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-11-13 09:30:00'},
 {u'action': u'open',
  u'amount': 9600,
  u'commission': 29.32,
  u'filled': 9600,
  u'price': 10.18,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-12-03 09:30:00'},
 {u'action': u'close',
  u'amount': 9600,
  u'commission': 123.55,
  u'filled': 9600,
  u'price': 9.9,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-12-08 09:30:00'},
 {u'action': u'open',
  u'amount': 9500,
  u'commission': 28.44,
  u'filled': 9500,
  u'price': 9.98,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-12-21 09:30:00'},
 {u'action': u'close',
  u'amount': 9500,
  u'commission': 125.48,
  u'filled': 9500,
  u'price': 10.16,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2015-12-25 09:30:00'},
 {u'action': u'open',
  u'amount': 11700,
  u'commission': 28.96,
  u'filled': 11700,
  u'price': 8.25,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-02-17 09:30:00'},
 {u'action': u'close',
  u'amount': 11700,
  u'commission': 125.48,
  u'filled': 11700,
  u'price': 8.25,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-02-24 09:30:00'},
 {u'action': u'open',
  u'amount': 11600,
  u'commission': 28.88,
  u'filled': 11600,
  u'price': 8.3,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-03-03 09:30:00'},
 {u'action': u'close',
  u'amount': 11600,
  u'commission': 126.67,
  u'filled': 11600,
  u'price': 8.4,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-03-10 09:30:00'},
 {u'action': u'open',
  u'amount': 11500,
  u'commission': 29.12,
  u'filled': 11500,
  u'price': 8.44,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-03-16 09:30:00'},
 {u'action': u'close',
  u'amount': 11500,
  u'commission': 128.87,
  u'filled': 11500,
  u'price': 8.62,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-03-25 09:30:00'},
 {u'action': u'open',
  u'amount': 11300,
  u'commission': 29.83,
  u'filled': 11300,
  u'price': 8.8,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-03-31 09:30:00'},
 {u'action': u'close',
  u'amount': 11300,
  u'commission': 127.07,
  u'filled': 11300,
  u'price': 8.65,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-04-08 09:30:00'},
 {u'action': u'open',
  u'amount': 10900,
  u'commission': 29.23,
  u'filled': 10900,
  u'price': 8.94,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-04-14 09:30:00'},
 {u'action': u'close',
  u'amount': 10900,
  u'commission': 125.12,
  u'filled': 10900,
  u'price': 8.83,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-04-19 09:30:00'},
 {u'action': u'open',
  u'amount': 11100,
  u'commission': 28.77,
  u'filled': 11100,
  u'price': 8.64,
  u'security': u'000001.XSHE',
  u'security_name': u'\u5e73\u5b89\u94f6\u884c',
  u'time': u'2016-06-01 09:30:00'}]
gt.get_records()       # 获取所有record()记录
[{u'stock_price': 10.74, u'time': u'2015-01-05'},
 {u'stock_price': 10.87, u'time': u'2015-01-06'},
 {u'stock_price': 10.7, u'time': u'2015-01-07'},
 {u'stock_price': 10.5, u'time': u'2015-01-08'},
 {u'stock_price': 10.15, u'time': u'2015-01-09'},
 {u'stock_price': 10.23, u'time': u'2015-01-12'},
 {u'stock_price': 10.02, u'time': u'2015-01-13'},
 {u'stock_price': 9.96, u'time': u'2015-01-14'},
 {u'stock_price': 10.05, u'time': u'2015-01-15'},
 {u'stock_price': 10.41, u'time': u'2015-01-16'},
 {u'stock_price': 10.43, u'time': u'2015-01-19'},
 {u'stock_price': 9.38, u'time': u'2015-01-20'},
 {u'stock_price': 9.38, u'time': u'2015-01-21'},
 {u'stock_price': 9.78, u'time': u'2015-01-22'},
 {u'stock_price': 9.7, u'time': u'2015-01-23'},
 {u'stock_price': 9.77, u'time': u'2015-01-26'},
 {u'stock_price': 9.73, u'time': u'2015-01-27'},
 {u'stock_price': 9.49, u'time': u'2015-01-28'},
 {u'stock_price': 9.54, u'time': u'2015-01-29'},
 {u'stock_price': 9.43, u'time': u'2015-01-30'},
 {u'stock_price': 9.45, u'time': u'2015-02-02'},
 {u'stock_price': 9.25, u'time': u'2015-02-03'},
 {u'stock_price': 9.46, u'time': u'2015-02-04'},
 {u'stock_price': 9.3, u'time': u'2015-02-05'},
 {u'stock_price': 9.35, u'time': u'2015-02-06'},
 {u'stock_price': 9.16, u'time': u'2015-02-09'},
 {u'stock_price': 9.17, u'time': u'2015-02-10'},
 {u'stock_price': 9.34, u'time': u'2015-02-11'},
 {u'stock_price': 9.31, u'time': u'2015-02-12'},
 {u'stock_price': 9.4, u'time': u'2015-02-13'},
 {u'stock_price': 9.46, u'time': u'2015-02-16'},
 {u'stock_price': 9.44, u'time': u'2015-02-17'},
 {u'stock_price': 9.49, u'time': u'2015-02-25'},
 {u'stock_price': 9.36, u'time': u'2015-02-26'},
 {u'stock_price': 9.54, u'time': u'2015-02-27'},
 {u'stock_price': 9.49, u'time': u'2015-03-02'},
 {u'stock_price': 9.52, u'time': u'2015-03-03'},
 {u'stock_price': 9.23, u'time': u'2015-03-04'},
 {u'stock_price': 9.2, u'time': u'2015-03-05'},
 {u'stock_price': 9.08, u'time': u'2015-03-06'},
 {u'stock_price': 9.12, u'time': u'2015-03-09'},
 {u'stock_price': 9.6, u'time': u'2015-03-10'},
 {u'stock_price': 9.34, u'time': u'2015-03-11'},
 {u'stock_price': 9.4, u'time': u'2015-03-12'},
 {u'stock_price': 9.9, u'time': u'2015-03-13'},
 {u'stock_price': 10.17, u'time': u'2015-03-16'},
 {u'stock_price': 10.45, u'time': u'2015-03-17'},
 {u'stock_price': 10.45, u'time': u'2015-03-18'},
 {u'stock_price': 10.52, u'time': u'2015-03-19'},
 {u'stock_price': 10.3, u'time': u'2015-03-20'},
 {u'stock_price': 10.39, u'time': u'2015-03-23'},
 {u'stock_price': 10.47, u'time': u'2015-03-24'},
 {u'stock_price': 10.41, u'time': u'2015-03-25'},
 {u'stock_price': 10.11, u'time': u'2015-03-26'},
 {u'stock_price': 10.25, u'time': u'2015-03-27'},
 {u'stock_price': 10.23, u'time': u'2015-03-30'},
 {u'stock_price': 10.62, u'time': u'2015-03-31'},
 {u'stock_price': 10.68, u'time': u'2015-04-01'},
 {u'stock_price': 10.83, u'time': u'2015-04-02'},
 {u'stock_price': 10.72, u'time': u'2015-04-03'},
 {u'stock_price': 10.75, u'time': u'2015-04-07'},
 {u'stock_price': 11.4, u'time': u'2015-04-08'},
 {u'stock_price': 12.16, u'time': u'2015-04-09'},
 {u'stock_price': 12.21, u'time': u'2015-04-10'},
 {u'stock_price': 13.43, u'time': u'2015-04-13'},
 {u'stock_price': 13.58, u'time': u'2015-04-14'},
 {u'stock_price': 13.38, u'time': u'2015-04-15'},
 {u'stock_price': 13.67, u'time': u'2015-04-16'},
 {u'stock_price': 13.96, u'time': u'2015-04-17'},
 {u'stock_price': 13.9, u'time': u'2015-04-20'},
 {u'stock_price': 13.38, u'time': u'2015-04-21'},
 {u'stock_price': 13.6, u'time': u'2015-04-22'},
 {u'stock_price': 13.92, u'time': u'2015-04-23'},
 {u'stock_price': 13.68, u'time': u'2015-04-24'},
 {u'stock_price': 13.25, u'time': u'2015-04-27'},
 {u'stock_price': 13.48, u'time': u'2015-04-28'},
 {u'stock_price': 13.71, u'time': u'2015-04-29'},
 {u'stock_price': 13.67, u'time': u'2015-04-30'},
 {u'stock_price': 13.71, u'time': u'2015-05-04'},
 {u'stock_price': 13.56, u'time': u'2015-05-05'},
 {u'stock_price': 13.02, u'time': u'2015-05-06'},
 {u'stock_price': 12.91, u'time': u'2015-05-07'},
 {u'stock_price': 12.87, u'time': u'2015-05-08'},
 {u'stock_price': 13.01, u'time': u'2015-05-11'},
 {u'stock_price': 13.16, u'time': u'2015-05-12'},
 {u'stock_price': 13.11, u'time': u'2015-05-13'},
 {u'stock_price': 13.04, u'time': u'2015-05-14'},
 {u'stock_price': 13.05, u'time': u'2015-05-15'},
 {u'stock_price': 12.69, u'time': u'2015-05-18'},
 {u'stock_price': 12.46, u'time': u'2015-05-19'},
 {u'stock_price': 12.8, u'time': u'2015-05-20'},
 {u'stock_price': 12.92, u'time': u'2015-05-21'},
 {u'stock_price': 12.97, u'time': u'2015-05-22'},
 {u'stock_price': 13.36, u'time': u'2015-05-25'},
 {u'stock_price': 13.63, u'time': u'2015-05-26'},
 {u'stock_price': 13.65, u'time': u'2015-05-27'},
 {u'stock_price': 13.53, u'time': u'2015-05-28'},
 {u'stock_price': 12.73, u'time': u'2015-05-29'},
 {u'stock_price': 12.58, u'time': u'2015-06-01'},
 {u'stock_price': 13.06, u'time': u'2015-06-02'},
 {u'stock_price': 12.95, u'time': u'2015-06-03'},
 {u'stock_price': 13.0, u'time': u'2015-06-04'},
 {u'stock_price': 13.44, u'time': u'2015-06-05'},
 {u'stock_price': 13.38, u'time': u'2015-06-08'},
 {u'stock_price': 14.2, u'time': u'2015-06-09'},
 {u'stock_price': 13.94, u'time': u'2015-06-10'},
 {u'stock_price': 13.7, u'time': u'2015-06-11'},
 {u'stock_price': 13.53, u'time': u'2015-06-12'},
 {u'stock_price': 13.56, u'time': u'2015-06-15'},
 {u'stock_price': 13.07, u'time': u'2015-06-16'},
 {u'stock_price': 12.84, u'time': u'2015-06-17'},
 {u'stock_price': 12.92, u'time': u'2015-06-18'},
 {u'stock_price': 12.63, u'time': u'2015-06-19'},
 {u'stock_price': 12.01, u'time': u'2015-06-23'},
 {u'stock_price': 12.28, u'time': u'2015-06-24'},
 {u'stock_price': 12.42, u'time': u'2015-06-25'},
 {u'stock_price': 12.21, u'time': u'2015-06-26'},
 {u'stock_price': 11.31, u'time': u'2015-06-29'},
 {u'stock_price': 11.13, u'time': u'2015-06-30'},
 {u'stock_price': 11.94, u'time': u'2015-07-01'},
 {u'stock_price': 11.43, u'time': u'2015-07-02'},
 {u'stock_price': 11.29, u'time': u'2015-07-03'},
 {u'stock_price': 10.73, u'time': u'2015-07-06'},
 {u'stock_price': 11.4, u'time': u'2015-07-07'},
 {u'stock_price': 12.03, u'time': u'2015-07-08'},
 {u'stock_price': 10.83, u'time': u'2015-07-09'},
 {u'stock_price': 11.71, u'time': u'2015-07-10'},
 {u'stock_price': 12.2, u'time': u'2015-07-13'},
 {u'stock_price': 11.86, u'time': u'2015-07-14'},
 {u'stock_price': 11.39, u'time': u'2015-07-15'},
 {u'stock_price': 11.15, u'time': u'2015-07-16'},
 {u'stock_price': 11.17, u'time': u'2015-07-17'},
 {u'stock_price': 11.35, u'time': u'2015-07-20'},
 {u'stock_price': 11.17, u'time': u'2015-07-21'},
 {u'stock_price': 11.14, u'time': u'2015-07-22'},
 {u'stock_price': 11.1, u'time': u'2015-07-23'},
 {u'stock_price': 11.22, u'time': u'2015-07-24'},
 {u'stock_price': 10.99, u'time': u'2015-07-27'},
 {u'stock_price': 10.21, u'time': u'2015-07-28'},
 {u'stock_price': 10.36, u'time': u'2015-07-29'},
 {u'stock_price': 10.35, u'time': u'2015-07-30'},
 {u'stock_price': 10.07, u'time': u'2015-07-31'},
 {u'stock_price': 10.15, u'time': u'2015-08-03'},
 {u'stock_price': 10.53, u'time': u'2015-08-04'},
 {u'stock_price': 10.56, u'time': u'2015-08-05'},
 {u'stock_price': 10.34, u'time': u'2015-08-06'},
 {u'stock_price': 10.29, u'time': u'2015-08-07'},
 {u'stock_price': 10.35, u'time': u'2015-08-10'},
 {u'stock_price': 10.61, u'time': u'2015-08-11'},
 {u'stock_price': 10.54, u'time': u'2015-08-12'},
 {u'stock_price': 10.32, u'time': u'2015-08-13'},
 {u'stock_price': 10.32, u'time': u'2015-08-14'},
 {u'stock_price': 10.38, u'time': u'2015-08-17'},
 {u'stock_price': 10.3, u'time': u'2015-08-18'},
 {u'stock_price': 10.08, u'time': u'2015-08-19'},
 {u'stock_price': 10.04, u'time': u'2015-08-20'},
 {u'stock_price': 9.89, u'time': u'2015-08-21'},
 {u'stock_price': 9.44, u'time': u'2015-08-24'},
 {u'stock_price': 8.5, u'time': u'2015-08-25'},
 {u'stock_price': 7.77, u'time': u'2015-08-26'},
 {u'stock_price': 8.14, u'time': u'2015-08-27'},
 {u'stock_price': 8.87, u'time': u'2015-08-28'},
 {u'stock_price': 8.89, u'time': u'2015-08-31'},
 {u'stock_price': 9.09, u'time': u'2015-09-01'},
 {u'stock_price': 9.5, u'time': u'2015-09-02'},
 {u'stock_price': 9.72, u'time': u'2015-09-07'},
 {u'stock_price': 8.94, u'time': u'2015-09-08'},
 {u'stock_price': 9.03, u'time': u'2015-09-09'},
 {u'stock_price': 9.11, u'time': u'2015-09-10'},
 {u'stock_price': 9.07, u'time': u'2015-09-11'},
 {u'stock_price': 9.0, u'time': u'2015-09-14'},
 {u'stock_price': 8.93, u'time': u'2015-09-15'},
 {u'stock_price': 8.68, u'time': u'2015-09-16'},
 {u'stock_price': 8.95, u'time': u'2015-09-17'},
 {u'stock_price': 8.84, u'time': u'2015-09-18'},
 {u'stock_price': 8.88, u'time': u'2015-09-21'},
 {u'stock_price': 8.88, u'time': u'2015-09-22'},
 {u'stock_price': 9.0, u'time': u'2015-09-23'},
 {u'stock_price': 8.79, u'time': u'2015-09-24'},
 {u'stock_price': 8.79, u'time': u'2015-09-25'},
 {u'stock_price': 8.66, u'time': u'2015-09-28'},
 {u'stock_price': 8.65, u'time': u'2015-09-29'},
 {u'stock_price': 8.52, u'time': u'2015-09-30'},
 {u'stock_price': 8.61, u'time': u'2015-10-08'},
 {u'stock_price': 8.79, u'time': u'2015-10-09'},
 {u'stock_price': 8.95, u'time': u'2015-10-12'},
 {u'stock_price': 9.22, u'time': u'2015-10-13'},
 {u'stock_price': 9.14, u'time': u'2015-10-14'},
 {u'stock_price': 9.02, u'time': u'2015-10-15'},
 {u'stock_price': 9.17, u'time': u'2015-10-16'},
 {u'stock_price': 9.22, u'time': u'2015-10-19'},
 {u'stock_price': 9.25, u'time': u'2015-10-20'},
 {u'stock_price': 9.3, u'time': u'2015-10-21'},
 {u'stock_price': 9.21, u'time': u'2015-10-22'},
 {u'stock_price': 9.3, u'time': u'2015-10-23'},
 {u'stock_price': 9.42, u'time': u'2015-10-26'},
 {u'stock_price': 9.46, u'time': u'2015-10-27'},
 {u'stock_price': 9.43, u'time': u'2015-10-28'},
 {u'stock_price': 9.25, u'time': u'2015-10-29'},
 {u'stock_price': 9.25, u'time': u'2015-10-30'},
 {u'stock_price': 9.33, u'time': u'2015-11-02'},
 {u'stock_price': 9.15, u'time': u'2015-11-03'},
 {u'stock_price': 9.07, u'time': u'2015-11-04'},
 {u'stock_price': 9.6, u'time': u'2015-11-05'},
 {u'stock_price': 9.91, u'time': u'2015-11-06'},
 {u'stock_price': 10.17, u'time': u'2015-11-09'},
 {u'stock_price': 10.63, u'time': u'2015-11-10'},
 {u'stock_price': 10.47, u'time': u'2015-11-11'},
 {u'stock_price': 10.31, u'time': u'2015-11-12'},
 {u'stock_price': 10.18, u'time': u'2015-11-13'},
 {u'stock_price': 10.05, u'time': u'2015-11-16'},
 {u'stock_price': 10.13, u'time': u'2015-11-17'},
 {u'stock_price': 10.26, u'time': u'2015-11-18'},
 {u'stock_price': 10.2, u'time': u'2015-11-19'},
 {u'stock_price': 10.26, u'time': u'2015-11-20'},
 {u'stock_price': 10.31, u'time': u'2015-11-23'},
 {u'stock_price': 10.22, u'time': u'2015-11-24'},
 {u'stock_price': 10.08, u'time': u'2015-11-25'},
 {u'stock_price': 10.12, u'time': u'2015-11-26'},
 {u'stock_price': 10.04, u'time': u'2015-11-27'},
 {u'stock_price': 9.63, u'time': u'2015-11-30'},
 {u'stock_price': 9.64, u'time': u'2015-12-01'},
 {u'stock_price': 9.65, u'time': u'2015-12-02'},
 {u'stock_price': 10.27, u'time': u'2015-12-03'},
 {u'stock_price': 10.22, u'time': u'2015-12-04'},
 {u'stock_price': 9.95, u'time': u'2015-12-07'},
 {u'stock_price': 9.98, u'time': u'2015-12-08'},
 {u'stock_price': 9.82, u'time': u'2015-12-09'},
 {u'stock_price': 9.85, u'time': u'2015-12-10'},
 {u'stock_price': 9.82, u'time': u'2015-12-11'},
 {u'stock_price': 9.71, u'time': u'2015-12-14'},
 {u'stock_price': 9.91, u'time': u'2015-12-15'},
 {u'stock_price': 9.79, u'time': u'2015-12-16'},
 {u'stock_price': 9.76, u'time': u'2015-12-17'},
 {u'stock_price': 9.91, u'time': u'2015-12-18'},
 {u'stock_price': 10.04, u'time': u'2015-12-21'},
 {u'stock_price': 10.27, u'time': u'2015-12-22'},
 {u'stock_price': 10.21, u'time': u'2015-12-23'},
 {u'stock_price': 10.25, u'time': u'2015-12-24'},
 {u'stock_price': 10.13, u'time': u'2015-12-25'},
 {u'stock_price': 10.19, u'time': u'2015-12-28'},
 {u'stock_price': 9.84, u'time': u'2015-12-29'},
 {u'stock_price': 9.93, u'time': u'2015-12-30'},
 {u'stock_price': 9.94, u'time': u'2015-12-31'},
 {u'stock_price': 9.85, u'time': u'2016-01-04'},
 {u'stock_price': 9.3, u'time': u'2016-01-05'},
 {u'stock_price': 9.36, u'time': u'2016-01-06'},
 {u'stock_price': 9.47, u'time': u'2016-01-07'},
 {u'stock_price': 8.98, u'time': u'2016-01-08'},
 {u'stock_price': 9.13, u'time': u'2016-01-11'},
 {u'stock_price': 8.84, u'time': u'2016-01-12'},
 {u'stock_price': 8.88, u'time': u'2016-01-13'},
 {u'stock_price': 8.79, u'time': u'2016-01-14'},
 {u'stock_price': 8.84, u'time': u'2016-01-15'},
 {u'stock_price': 8.59, u'time': u'2016-01-18'},
 {u'stock_price': 8.55, u'time': u'2016-01-19'},
 {u'stock_price': 8.79, u'time': u'2016-01-20'},
 {u'stock_price': 8.65, u'time': u'2016-01-21'},
 {u'stock_price': 8.47, u'time': u'2016-01-22'},
 {u'stock_price': 8.54, u'time': u'2016-01-25'},
 {u'stock_price': 8.52, u'time': u'2016-01-26'},
 {u'stock_price': 8.1, u'time': u'2016-01-27'},
 {u'stock_price': 8.11, u'time': u'2016-01-28'},
 {u'stock_price': 7.96, u'time': u'2016-01-29'},
 {u'stock_price': 8.21, u'time': u'2016-02-01'},
 {u'stock_price': 8.05, u'time': u'2016-02-02'},
 {u'stock_price': 8.17, u'time': u'2016-02-03'},
 {u'stock_price': 8.09, u'time': u'2016-02-04'},
 {u'stock_price': 8.17, u'time': u'2016-02-05'},
 {u'stock_price': 8.15, u'time': u'2016-02-15'},
 {u'stock_price': 8.04, u'time': u'2016-02-16'},
 {u'stock_price': 8.22, u'time': u'2016-02-17'},
 {u'stock_price': 8.33, u'time': u'2016-02-18'},
 {u'stock_price': 8.29, u'time': u'2016-02-19'},
 {u'stock_price': 8.24, u'time': u'2016-02-22'},
 {u'stock_price': 8.45, u'time': u'2016-02-23'},
 {u'stock_price': 8.31, u'time': u'2016-02-24'},
 {u'stock_price': 8.33, u'time': u'2016-02-25'},
 {u'stock_price': 7.94, u'time': u'2016-02-26'},
 {u'stock_price': 8.04, u'time': u'2016-02-29'},
 {u'stock_price': 7.85, u'time': u'2016-03-01'},
 {u'stock_price': 7.96, u'time': u'2016-03-02'},
 {u'stock_price': 8.29, u'time': u'2016-03-03'},
 {u'stock_price': 8.3, u'time': u'2016-03-04'},
 {u'stock_price': 8.54, u'time': u'2016-03-07'},
 {u'stock_price': 8.49, u'time': u'2016-03-08'},
 {u'stock_price': 8.44, u'time': u'2016-03-09'},
 {u'stock_price': 8.35, u'time': u'2016-03-10'},
 {u'stock_price': 8.33, u'time': u'2016-03-11'},
 {u'stock_price': 8.34, u'time': u'2016-03-14'},
 {u'stock_price': 8.42, u'time': u'2016-03-15'},
 {u'stock_price': 8.47, u'time': u'2016-03-16'},
 {u'stock_price': 8.5, u'time': u'2016-03-17'},
 {u'stock_price': 8.56, u'time': u'2016-03-18'},
 {u'stock_price': 8.65, u'time': u'2016-03-21'},
 {u'stock_price': 8.87, u'time': u'2016-03-22'},
 {u'stock_price': 8.8, u'time': u'2016-03-23'},
 {u'stock_price': 8.79, u'time': u'2016-03-24'},
 {u'stock_price': 8.64, u'time': u'2016-03-25'},
 {u'stock_price': 8.7, u'time': u'2016-03-28'},
 {u'stock_price': 8.61, u'time': u'2016-03-29'},
 {u'stock_price': 8.56, u'time': u'2016-03-30'},
 {u'stock_price': 8.79, u'time': u'2016-03-31'},
 {u'stock_price': 8.74, u'time': u'2016-04-01'},
 {u'stock_price': 8.75, u'time': u'2016-04-05'},
 {u'stock_price': 8.79, u'time': u'2016-04-06'},
 {u'stock_price': 8.8, u'time': u'2016-04-07'},
 {u'stock_price': 8.7, u'time': u'2016-04-08'},
 {u'stock_price': 8.68, u'time': u'2016-04-11'},
 {u'stock_price': 8.8, u'time': u'2016-04-12'},
 {u'stock_price': 8.76, u'time': u'2016-04-13'},
 {u'stock_price': 8.88, u'time': u'2016-04-14'},
 {u'stock_price': 8.9, u'time': u'2016-04-15'},
 {u'stock_price': 8.93, u'time': u'2016-04-18'},
 {u'stock_price': 8.81, u'time': u'2016-04-19'},
 {u'stock_price': 8.84, u'time': u'2016-04-20'},
 {u'stock_price': 8.64, u'time': u'2016-04-21'},
 {u'stock_price': 8.63, u'time': u'2016-04-22'},
 {u'stock_price': 8.66, u'time': u'2016-04-25'},
 {u'stock_price': 8.62, u'time': u'2016-04-26'},
 {u'stock_price': 8.7, u'time': u'2016-04-27'},
 {u'stock_price': 8.68, u'time': u'2016-04-28'},
 {u'stock_price': 8.75, u'time': u'2016-04-29'},
 {u'stock_price': 8.68, u'time': u'2016-05-03'},
 {u'stock_price': 8.77, u'time': u'2016-05-04'},
 {u'stock_price': 8.8, u'time': u'2016-05-05'},
 {u'stock_price': 8.8, u'time': u'2016-05-06'},
 {u'stock_price': 8.64, u'time': u'2016-05-09'},
 {u'stock_price': 8.5, u'time': u'2016-05-10'},
 {u'stock_price': 8.44, u'time': u'2016-05-11'},
 {u'stock_price': 8.52, u'time': u'2016-05-12'},
 {u'stock_price': 8.52, u'time': u'2016-05-13'},
 {u'stock_price': 8.5, u'time': u'2016-05-16'},
 {u'stock_price': 8.51, u'time': u'2016-05-17'},
 {u'stock_price': 8.46, u'time': u'2016-05-18'},
 {u'stock_price': 8.46, u'time': u'2016-05-19'},
 {u'stock_price': 8.42, u'time': u'2016-05-20'},
 {u'stock_price': 8.46, u'time': u'2016-05-23'},
 {u'stock_price': 8.44, u'time': u'2016-05-24'},
 {u'stock_price': 8.38, u'time': u'2016-05-25'},
 {u'stock_price': 8.4, u'time': u'2016-05-26'},
 {u'stock_price': 8.39, u'time': u'2016-05-27'},
 {u'stock_price': 8.43, u'time': u'2016-05-30'},
 {u'stock_price': 8.44, u'time': u'2016-05-31'},
 {u'stock_price': 8.66, u'time': u'2016-06-01'}]
gt.get_risk()          # 获取总的风险指标
{u'algorithm_return': -0.03993160000000073,
 u'algorithm_volatility': 0.26412380390523005,
 u'alpha': -0.03924882545523693,
 u'annual_algo_return': -0.029097790469759577,
 u'annual_bm_return': -0.07768720537202145,
 u'benchmark_return': -0.10559964682959888,
 u'benchmark_volatility': 0.3703428719597582,
 u'beta': 0.25362965260469034,
 u'excess_return': -0.09615077808219252,
 u'information': 0.04426724611143751,
 u'max_drawdown': 0.2570703782923631,
 u'max_drawdown_period': [u'2015-04-16', u'2015-10-28'],
 u'max_leverage': 0.0,
 u'period_label': u'2016-06',
 u'sharpe': -0.26161137106200577,
 u'sortino': -0.3579121975894534,
 u'trading_days': 345,
 u'treasury_return': 0.05621917808219178}
    k = gt.get_risk()
k['max_drawdown_period'] = [(u'2015-04-16', u'2015-10-28')]
import pandas as pd 
pd.DataFrame(k)
algorithm_return algorithm_volatility alpha annual_algo_return annual_bm_return benchmark_return benchmark_volatility beta excess_return information max_drawdown max_drawdown_period max_leverage period_label sharpe sortino trading_days treasury_return
0 -0.039932 0.264124 -0.039249 -0.029098 -0.077687 -0.1056 0.370343 0.25363 -0.096151 0.044267 0.25707 (2015-04-16, 2015-10-28) 0 2016-06 -0.261611 -0.357912 345 0.056219
gt.get_period_risks()  # 获取分月计算的风险指标
{'algorithm_return':          one_month  three_month  six_month  twelve_month
 2015-01  -0.078339          NaN        NaN           NaN
 2015-02  -0.013155          NaN        NaN           NaN
 2015-03   0.058672    -0.037099        NaN           NaN
 2015-04   0.195223     0.248704        NaN           NaN
 2015-05  -0.058769     0.190986        NaN           NaN
 2015-06   0.048142     0.179140   0.135395           NaN
 2015-07  -0.095884    -0.108050   0.113781           NaN
 2015-08  -0.036026    -0.086498   0.087968           NaN
 2015-09  -0.032462    -0.156748  -0.005688           NaN
 2015-10  -0.022917    -0.088693  -0.187159           NaN
 2015-11   0.048620    -0.008672  -0.094419           NaN
 2015-12  -0.013097     0.011170  -0.147329     -0.031882
 2016-01   0.000000     0.034886  -0.056901      0.050406
 2016-02  -0.001595    -0.014672  -0.023216      0.062710
 2016-03   0.022850     0.021218   0.032625      0.026752
 2016-04  -0.025261    -0.004578   0.030148     -0.162654
 2016-05   0.000000    -0.002988  -0.017615     -0.110372
 2016-06  -0.003754    -0.028920  -0.008315     -0.154419,
 'algorithm_volatility':          one_month  three_month  six_month  twelve_month
 2015-01   0.551591          NaN        NaN           NaN
 2015-02   0.061606          NaN        NaN           NaN
 2015-03   0.252247     0.360363        NaN           NaN
 2015-04   0.504242     0.342942        NaN           NaN
 2015-05   0.257960     0.360300        NaN           NaN
 2015-06   0.256289     0.362769   0.361047           NaN
 2015-07   0.342802     0.289815   0.318062           NaN
 2015-08   0.137823     0.262110   0.314885           NaN
 2015-09   0.349207     0.290239   0.329422           NaN
 2015-10   0.168346     0.235108   0.264144           NaN
 2015-11   0.250009     0.267131   0.263587           NaN
 2015-12   0.143085     0.191121   0.246877      0.307872
 2016-01   0.000000     0.165536   0.201439      0.265925
 2016-02   0.137720     0.112635   0.203496      0.267121
 2016-03   0.160498     0.121426   0.160014      0.260393
 2016-04   0.071094     0.128748   0.148512      0.214105
 2016-05   0.000000     0.103656   0.107621      0.200957
 2016-06        NaN     0.050013   0.098227      0.194811,
 'alpha':          one_month  three_month  six_month  twelve_month
 2015-01  -0.340114          NaN        NaN           NaN
 2015-02  -0.285462          NaN        NaN           NaN
 2015-03  -0.705164    -0.771542        NaN           NaN
 2015-04   2.222741    -0.120284        NaN           NaN
 2015-05  -0.683038    -0.435415        NaN           NaN
 2015-06   0.761667     0.769600   0.005202           NaN
 2015-07  -0.475122    -0.254308   0.148066           NaN
 2015-08  -0.378048    -0.229071   0.173228           NaN
 2015-09  -0.210559    -0.392439   0.042345           NaN
 2015-10  -1.756624    -0.329792  -0.290167           NaN
 2015-11   0.696051    -0.158699  -0.135661           NaN
 2015-12  -0.356621    -0.268037  -0.241502     -0.077842
 2016-01  -0.040000     0.167151  -0.099187      0.050571
 2016-02  -0.026688    -0.058275  -0.033985      0.073793
 2016-03  -0.488207     0.087901   0.033778      0.037806
 2016-04  -0.242546    -0.120085   0.056010     -0.137978
 2016-05  -0.040000    -0.141177  -0.050841     -0.093103
 2016-06  -0.649478    -0.185857  -0.033635     -0.149710,
 'benchmark_return':          one_month  three_month  six_month  twelve_month
 2015-01  -0.028105          NaN        NaN           NaN
 2015-02   0.040314          NaN        NaN           NaN
 2015-03   0.133888     0.146447        NaN           NaN
 2015-04   0.172463     0.383036        NaN           NaN
 2015-05   0.019146     0.354896        NaN           NaN
 2015-06  -0.075985     0.104116   0.265810           NaN
 2015-07  -0.146725    -0.196465   0.111318           NaN
 2015-08  -0.117946    -0.304554  -0.057743           NaN
 2015-09  -0.048592    -0.283937  -0.209384           NaN
 2015-10   0.103383    -0.074048  -0.255966           NaN
 2015-11   0.009149     0.059371  -0.263264           NaN
 2015-12   0.046151     0.164866  -0.165883      0.055834
 2016-01  -0.210376    -0.166377  -0.228105     -0.142179
 2016-02  -0.023293    -0.193176  -0.145274     -0.194628
 2016-03   0.118375    -0.137474   0.004727     -0.205647
 2016-04  -0.019062     0.071503  -0.106770     -0.335406
 2016-05   0.004059     0.101511  -0.111275     -0.345244
 2016-06  -0.002844    -0.017880  -0.152897     -0.293416,
 'benchmark_volatility':          one_month  three_month  six_month  twelve_month
 2015-01   0.385965          NaN        NaN           NaN
 2015-02   0.231550          NaN        NaN           NaN
 2015-03   0.215239     0.289107        NaN           NaN
 2015-04   0.227623     0.222182        NaN           NaN
 2015-05   0.392263     0.285261        NaN           NaN
 2015-06   0.553131     0.412760   0.357441           NaN
 2015-07   0.605976     0.523553   0.413022           NaN
 2015-08   0.602886     0.579502   0.463818           NaN
 2015-09   0.341508     0.528661   0.476164           NaN
 2015-10   0.254009     0.435778   0.482086           NaN
 2015-11   0.303270     0.303330   0.470614           NaN
 2015-12   0.239572     0.264695   0.423372      0.392687
 2016-01   0.510408     0.369562   0.400915      0.406872
 2016-02   0.340911     0.381768   0.345499      0.410844
 2016-03   0.228227     0.383871   0.329590      0.410629
 2016-04   0.139199     0.241611   0.314981      0.406144
 2016-05   0.186952     0.191895   0.299716      0.393849
 2016-06        NaN     0.161722   0.310476      0.376342,
 'beta':          one_month  three_month  six_month  twelve_month
 2015-01   0.998299          NaN        NaN           NaN
 2015-02   0.053142          NaN        NaN           NaN
 2015-03   0.503765     0.740981        NaN           NaN
 2015-04   0.908467     0.560545        NaN           NaN
 2015-05   0.492564     0.607708        NaN           NaN
 2015-06   0.079165     0.296824   0.433632           NaN
 2015-07   0.267527     0.237490   0.293042           NaN
 2015-08   0.019433     0.132218   0.228646           NaN
 2015-09   0.332594     0.174039   0.226857           NaN
 2015-10   0.444858     0.124459   0.193814           NaN
 2015-11   0.318151     0.337919   0.172912           NaN
 2015-12   0.308802     0.331235   0.207554      0.300930
 2016-01   0.000000     0.116289   0.119401      0.209774
 2016-02   0.109030     0.066582   0.169153      0.208931
 2016-03   0.311315     0.068936   0.152924      0.203582
 2016-04   0.280393     0.202790   0.137841      0.177735
 2016-05   0.000000     0.213803   0.097306      0.151277
 2016-06   0.000000     0.101655   0.071174      0.166119,
 'information':          one_month  three_month  six_month  twelve_month
 2015-01  -1.495108          NaN        NaN           NaN
 2015-02  -3.972598          NaN        NaN           NaN
 2015-03  -3.082445    -2.486074        NaN           NaN
 2015-04   0.701547    -1.229573        NaN           NaN
 2015-05  -3.945548    -1.467470        NaN           NaN
 2015-06   2.432314     0.544099  -0.597592           NaN
 2015-07   0.937668     0.651784  -0.077393           NaN
 2015-08   1.459703     1.621478   0.474841           NaN
 2015-09   0.533801     1.043315   0.816343           NaN
 2015-10  -9.605852    -0.304668   0.214521           NaN
 2015-11   1.428907    -0.930650   0.738407           NaN
 2015-12  -3.164017    -2.435357  -0.038820     -0.303545
 2016-01   5.502363     2.169026   0.865370      0.388355
 2016-02   0.894252     2.087511   0.708246      0.564849
 2016-03  -4.625734     1.721183   0.047084      0.509923
 2016-04  -0.737979    -1.470819   0.817772      0.448668
 2016-05  -0.346719    -2.255747   0.566012      0.656193
 2016-06   0.000000    -0.515542   1.138215      0.400542,
 'max_drawdown':          one_month  three_month  six_month  twelve_month
 2015-01   0.169166          NaN        NaN           NaN
 2015-02   0.015968          NaN        NaN           NaN
 2015-03   0.042095     0.194898        NaN           NaN
 2015-04   0.085223     0.085223        NaN           NaN
 2015-05   0.069138     0.138984        NaN           NaN
 2015-06   0.037826     0.138984   0.194898           NaN
 2015-07   0.095884     0.130083   0.184065           NaN
 2015-08   0.062300     0.179897   0.230787           NaN
 2015-09   0.098159     0.159461   0.241441           NaN
 2015-10   0.063613     0.116740   0.207919           NaN
 2015-11   0.058594     0.116740   0.207919           NaN
 2015-12   0.032458     0.085857   0.176780      0.257070
 2016-01   0.000000     0.085857   0.116740      0.257070
 2016-02   0.024873     0.032458   0.116740      0.257070
 2016-03   0.036184     0.036184   0.085857      0.257070
 2016-04   0.032833     0.061436   0.085857      0.207919
 2016-05   0.000000     0.061436   0.061436      0.207919
 2016-06   0.003754     0.035534   0.064058      0.176780,
 'sharpe':          one_month  three_month  six_month  twelve_month
 2015-01  -1.231537          NaN        NaN           NaN
 2015-02  -3.863970          NaN        NaN           NaN
 2015-03   3.455035    -0.534996        NaN           NaN
 2015-04  14.509434     4.562859        NaN           NaN
 2015-05  -2.213395     2.666836        NaN           NaN
 2015-06   2.771223     2.490390   0.736012           NaN
 2015-07  -2.058534    -1.381017   0.651133           NaN
 2015-08  -2.857995    -1.273788   0.441451           NaN
 2015-09  -1.082495    -1.813080  -0.155587           NaN
 2015-10  -1.953666    -1.573303  -1.461285           NaN
 2015-11   2.878934    -0.287666  -0.844368           NaN
 2015-12  -1.212611     0.034408  -1.267645     -0.235983
 2016-01   0.000000     0.624247  -0.760145      0.043911
 2016-02  -0.469338    -0.894105  -0.437123      0.089959
 2016-03   1.485103     0.436854   0.182304     -0.049185
 2016-04  -4.412679    -0.460251   0.149685     -0.960658
 2016-05   0.000000    -0.497998  -0.701335     -0.756690
 2016-06   0.000000    -4.004414  -0.615471     -1.074621,
 'sortino':          one_month  three_month  six_month  twelve_month
 2015-01  -1.547878          NaN        NaN           NaN
 2015-02  -2.573161          NaN        NaN           NaN
 2015-03   6.793850    -0.509806        NaN           NaN
 2015-04  31.717828     9.242985        NaN           NaN
 2015-05  -1.411676     5.001742        NaN           NaN
 2015-06   5.781571     4.389607   1.004910           NaN
 2015-07  -3.993221    -1.452989   1.124913           NaN
 2015-08  -3.616613    -1.745249   0.777726           NaN
 2015-09  -0.647030    -1.576591  -0.232070           NaN
 2015-10  -3.097906    -1.234436  -1.366953           NaN
 2015-11   4.714085    -0.270438  -0.969428           NaN
 2015-12  -1.477629     0.056091  -1.301615     -0.316775
 2016-01   0.000000     0.912570  -0.624453      0.068803
 2016-02  -0.746075    -1.053971  -0.376419      0.142102
 2016-03   2.739812     0.621290   0.307398     -0.071815
 2016-04  -4.509301    -0.698224   0.228798     -0.921254
 2016-05   0.000000    -0.604989  -0.855342     -0.766371
 2016-06   0.000000    -3.077574  -0.728925     -1.049463}
gt.get_period_risks()['alpha'] # 获取分月计算的风险指标中的alpha
one_month three_month six_month twelve_month
2015-01 -0.340114 NaN NaN NaN
2015-02 -0.285462 NaN NaN NaN
2015-03 -0.705164 -0.771542 NaN NaN
2015-04 2.222741 -0.120284 NaN NaN
2015-05 -0.683038 -0.435415 NaN NaN
2015-06 0.761667 0.769600 0.005202 NaN
2015-07 -0.475122 -0.254308 0.148066 NaN
2015-08 -0.378048 -0.229071 0.173228 NaN
2015-09 -0.210559 -0.392439 0.042345 NaN
2015-10 -1.756624 -0.329792 -0.290167 NaN
2015-11 0.696051 -0.158699 -0.135661 NaN
2015-12 -0.356621 -0.268037 -0.241502 -0.077842
2016-01 -0.040000 0.167151 -0.099187 0.050571
2016-02 -0.026688 -0.058275 -0.033985 0.073793
2016-03 -0.488207 0.087901 0.033778 0.037806
2016-04 -0.242546 -0.120085 0.056010 -0.137978
2016-05 -0.040000 -0.141177 -0.050841 -0.093103
2016-06 -0.649478 -0.185857 -0.033635 -0.149710
 

祝大家使用愉快~~~

全部回复

0/140

量化课程

    移动端课程