2
Follow
0
Followers
请教一下这个问题,谢谢大家
我做了一个循环多空的策略。
我发现每次做多的if Duo,每次都能循环运行,直到重新让Kong等于True,Duo等于False,
但是 if Duo是正常的
if Kong只运行了一次, 意思是, 只循环了一次! 没有再次循环,也没有重新分配
if Kong只运行了一次, 意思是, 只循环了一次! 没有再次循环,也没有重新分配
if Kong只运行了一次, 意思是, 只循环了一次! 没有再次循环,也没有重新分配
具体的代码,大概如下:用的是python
def main:
随机true false 赋值给 Duo 或者 Kong
while True:
if Duo:
条件未满足,开始多次循环 ......
满足条件后,结束循环 if Duo,重新分配,Duo = false Kong = True
if Kong:
条件未满足,开始多次循环......
满足条件后,结束循环 if Kong,重新分配,Duo = True Kong = false
Related Recommendations
How to Specify Different Versions of Data for the Rented Strategy by Its Rental Code MetadataAdvanced Tutorial for FMZ Quant platform Strategy WritingElementary Tutorial for FMZ Quant platform Strategy WritingGet Started with FMZ Quant PlatformSECURITY BUGI keep getting error: Exchange_GetAccount: Invalid ContractTypeWe have an incredibly profitable market making algorithm for sideways markets on Bitmex - but need expert to help eliminate wait times during downward volatility in the marketError with deribitLimitations of the backtesting engineHow to install ta-lib on linux docker?
Comment
All comments (1)
- 1
