以文本方式查看主题

-  金字塔客服中心 - 专业程序化交易软件提供商  (http://weistock.com/bbs/index.asp)
--  公式模型编写问题提交  (http://weistock.com/bbs/list.asp?boardid=4)
----  关于止损  (http://weistock.com/bbs/dispbbs.asp?boardid=4&id=30887)

--  作者:yekaicong
--  发布时间:2012/11/25 16:12:24
--  关于止损
编写股指期货日K线的模型,止损想要价格达到后立刻执行,不想的等K线走完,如何编写?例如止损设在30个点,也就是单笔亏损不能超过9000元
--  作者:jinzhe
--  发布时间:2012/11/26 9:12:46
--  

1秒轮询

 

if c-enterprice>=30*mindiff then sellshort();

if enterprice-c>=30*mindiff then sell();