''' 基于日K线的大周期采样(标准周K,月K,季K, 年K) 参数: stock : 证券代码 length : 需要返回的K线个数 rule : K线类别, 默认周K('W-FRI') ,另外还有:月K('BM'),季K('Q-DEC'),年K('A-DEC') date : 默认None, 对应使用attribute_history; 否则使用get_price 返回: DataFrame: index:时间序列 长度为length 范例: OHLC('000001.XSHE', 10, rule='W-FRI') OHLC('000001.XSHE', 10, rule='BM') OHLC('000001.XSHE', 10, rule='Q-DEC') OHLC('000001.XSHE', 10, rule='A-DEC') OHLC('000001.XSHE', 10, rule='W-FRI', date='2017-04-14') '''
您需要登录后才能查看源码,点击登录