For code/output blocks: Use ``` (aka backtick or grave accent) in a single line before and after the block. See: http://commonmark.org/help/
custom sizer class
-
I am going to apply money management by coding custom sizer.How can I get first set cash in middle of back-testing?and also a variable defined in the outer function from inside of the sizer class?
-
-
From inside sizer class: self.broker.get_cash()
-
You can call your custom function as you want like any other python function and make it return values as you wish.
-
-
@kausality said in custom sizer class:
- You can call your custom function as you want like any other python function and make it return values as you wish.
So, because ...
@siavash said in custom sizer class:
and also a variable defined in the outer function from inside of the sizer class?
... this is impossible.