上一页 1 ··· 16 17 18 19 20 21 22 23 24 ··· 45 下一页
摘要: 原文地址:https://www.backtrader.com/docu/timemgmt/ DateTime Management 日期时间管理 Up until release 1.5.0, backtrader used a direct approach to time management 阅读全文
posted @ 2020-09-30 15:43 就是想学习 阅读(1046) 评论(0) 推荐(0)
摘要: # 描述符 + 元类 爽爆天 from collections import OrderedDict # 描述符的基类,通过类属性来指定参数 class Typed: # 赋值类型给子类继承用 _expected_type = type(None) def __init__(self, name=N 阅读全文
posted @ 2020-09-25 10:53 就是想学习 阅读(289) 评论(0) 推荐(0)
摘要: 原文链接:https://backtrader.com/blog/posts/2016-06-21-livedata-feed/live-data-feed/ Starting with release 1.5.0, backtrader supports Live Data Feeds and L 阅读全文
posted @ 2020-09-24 17:08 就是想学习 阅读(1676) 评论(0) 推荐(0)
摘要: In [6]: super? Init signature: super(self, /, *args, **kwargs) Docstring: super() -> same as super(__class__, <first argument>) super(type) -> unbound 阅读全文
posted @ 2020-09-23 15:38 就是想学习 阅读(181) 评论(0) 推荐(0)
摘要: 子类在创建的时候,就会像父类的__init_subclass__就像一个回调函数, 会收到子类的的值,以及所传递的参数。 注意是子类在创建的时候,与实例化无关。 class A: def __init_subclass__(cls, **kwargs): print('init_subclass:' 阅读全文
posted @ 2020-09-23 11:28 就是想学习 阅读(707) 评论(0) 推荐(0)
摘要: 自己一般在写类的时候,很少用__的私有变量,很多进阶书籍也提示,少用__下划线的私有变量,避免引起不必要的麻烦,可以用_单下划线代替。 首先说明一个核心思想,Python在处理__的变量名的时候,会通过_类名__属性名的方式进行属性的保存。 最重要的是,当你在读取变量的时候,当用__变量名去读取的时 阅读全文
posted @ 2020-09-23 10:47 就是想学习 阅读(216) 评论(0) 推荐(0)
摘要: Sizers Reference FixedSize class backtrader.sizers.FixedSize() This sizer simply returns a fixed size for any operation. Size can be controlled by num 阅读全文
posted @ 2020-09-21 23:50 就是想学习 阅读(1223) 评论(0) 推荐(0)
摘要: Sizers Smart Staking A Strategy offers methods to trade, namely: buy, sell and close. Let’s see the signature of buy: 策略提供了交易的方法,即:买入、卖出和成交。让我们看看buy的签 阅读全文
posted @ 2020-09-21 23:17 就是想学习 阅读(2981) 评论(0) 推荐(0)
摘要: Fillers 填充 The backtrader broker simulation has a default strategy when it comes to using volume for order execution: 当使用成交量来执行订单时,backtrader-broker模拟 阅读全文
posted @ 2020-09-21 15:23 就是想学习 阅读(490) 评论(0) 推荐(0)
摘要: 这个感觉就是只能用来,在当前的开盘前下单,用的当天的开盘价可以参考买入股份,信号的处理,买入的时间,买入的价格,与正常的没有任何区别 Release 1.9.44.116 adds support for Cheat-On-Open. This seems to be a demanded feat 阅读全文
posted @ 2020-09-21 14:27 就是想学习 阅读(966) 评论(0) 推荐(0)
上一页 1 ··· 16 17 18 19 20 21 22 23 24 ··· 45 下一页