Discussions
»
Special Interest Groups
»
Basic Coding Techniques
»
Bars since value of an indicator greater than current value
Rank: Newbie
Groups: Registered, Registered Users Joined: 1/30/2010(UTC) Posts: 1
|
I'm having a problem trying to develop an exploration trying to find how many bars ago the value of an indicator was greater than the current value - tried using the 'P' variable, peakbars, hhv etc but just not getting it. Any suggestions??
Thanks in advance
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users Joined: 11/7/2005(UTC) Posts: 602
|
Could you use a1:=Cross() to create a signal from last occurrence of indicator being greater than then use BarsSince(a1=1) to get the # periods from that signal?
|
|
|
|
Users browsing this topic |
Guest (Hidden)
|
Discussions
»
Special Interest Groups
»
Basic Coding Techniques
»
Bars since value of an indicator greater than current value
Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.