logo
Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Options
Go to last post Go to first unread
rasj  
#1 Posted : Friday, June 1, 2012 1:24:15 PM(UTC)
rasj

Rank: Member

Groups: Registered, Registered Users, Subscribers
Joined: 4/17/2008(UTC)
Posts: 21
Location: Houston, TX

Thanks: 2 times
Can somebody help me with a formula that can measure the volume on day one of a candlestick signal? I would like to test if volume on day one or day two of a Bullish engulfing pattern has any influence on the results of my EngulfingBull() statement but I don't know how to write it. If volume on day one of a Bullish Engulfing pattern (a bearish day) is > than 110% of 21-days moving average then EngulfingBull() else 0. How do I define volume on day one in my if() statement? Thx,
henry1224  
#2 Posted : Saturday, June 2, 2012 7:25:00 AM(UTC)
henry1224

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 10/29/2004(UTC)
Posts: 1,394
Location: Glastonbury, CT

Was thanked: 2 time(s) in 2 post(s)
Try using a valuewhen() function

valuewhen(1,EngulfingBull(),V)
rasj  
#3 Posted : Monday, June 4, 2012 10:44:47 AM(UTC)
rasj

Rank: Member

Groups: Registered, Registered Users, Subscribers
Joined: 4/17/2008(UTC)
Posts: 21
Location: Houston, TX

Thanks: 2 times
I have tried that but it doesn't solve my problem re measuring volume on day one of the EngulfingBull pattern. ValueWhen returns a value regardsless of which day the occurence happens just as long as it happens. And if I add Ref() to the sentence it will take the day before day one so that doesn't work either. ValueWhen(1, Ref(EngulfingBull(),-1),V)
MS Support  
#4 Posted : Monday, August 20, 2012 11:12:10 AM(UTC)
MS Support

Rank: Advanced Member

Groups: Moderators, Registered, Registered Users, Subscribers
Joined: 10/8/2010(UTC)
Posts: 1,960

Thanks: 92 times
Was thanked: 155 time(s) in 150 post(s)
Instead of putting the EngulfingBull() function inside the Ref(), put the volume there. You are looking back to the most recent occurance of the Engulfing Bull pattern and want the volume from one bar before the pattern was TRUE:

Valuewhen(1, EngulfingBull(), Ref(V,-1))

If you are on the bar where the Engulfing Bull pattern is occuring, you can leave out the Valuewhen() function and just put the Ref() of the volume
Users browsing this topic
Guest (Hidden)
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.