以文本方式查看主题

-  金字塔客服中心 - 专业程序化交易软件提供商  (http://weistock.com/bbs/index.asp)
--  公式模型编写问题提交  (http://weistock.com/bbs/list.asp?boardid=4)
----  如何返回开仓那根K线的位置  (http://weistock.com/bbs/dispbbs.asp?boardid=4&id=48880)

--  作者:lcgs005
--  发布时间:2013/2/25 14:48:57
--  如何返回开仓那根K线的位置

是否可以用

tholding<>0 and TENTERBARS( 0)=0

来确认当根K线就是开仓K线?


--  作者:jinzhe
--  发布时间:2013/2/25 15:01:41
--  
tholding<>ref(tholding,1)
--  作者:lcgs005
--  发布时间:2013/2/25 15:18:52
--  
以下是引用jinzhe在2013-2-25 15:01:41的发言:
tholding<>ref(tholding,1)

这样的方式不行吧?

tholding返回的是常数,当前tholding不为0时,tholding 与ref(tholding,1)返回的是同一个数值