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

Notification

Icon
Error

Options
Go to last post Go to first unread
KERMIT  
#1 Posted : Saturday, August 18, 2007 8:33:17 PM(UTC)
KERMIT

Rank: Newbie

Groups: Registered, Registered Users
Joined: 7/9/2007(UTC)
Posts: 4

If I run this formula

ref(Cross(RSI(14),10) and Cross(RSI(14),50),-1)

What it does is it will enter a buy signal when the rsi crosses 10 and 50 on the same candle, the day before of course.

What I would like is to give a buy signal if the day before the rsi crosses 10 and 50 some time within the next 3 candles. eg if day one the rsi crossed 10 and day 2 it crossed 30 but it took till day 3 to finally cross 50 than I get a buy signal. The formula above only gives a buy if it crossed both 10 and 50 the same day. What if it took 3 day to cross both 10 and 50. Any trades that do this I miss out on.

Help would be awsome

Thanks.

wabbit  
#2 Posted : Saturday, August 18, 2007 9:20:06 PM(UTC)
wabbit

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers, Unverified Users
Joined: 10/28/2004(UTC)
Posts: 3,111
Location: Perth, Western Australia

Was thanked: 16 time(s) in 16 post(s)
Hi Kermit.

Welcome to the Forum.

Have a look at the Alert() function and the BarsSince() function. Either of these could be used to solve your coding problem.


Hope this helps.

wabbit [:D]

Users browsing this topic
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.