Welcome Guest, please sign in to participate in a discussion. Search | Active Topics |

Real Code Rate this Topic:
Previous Topic · Next Topic Watch this topic · Print this topic ·
slick8622
Posted : Saturday, April 18, 2009 6:06:21 PM
Gold Customer Gold Customer

Joined: 1/30/2007
Posts: 3

Help with real code please.

 

1.  The stock should be down at least two days in a row. (lower High)

 

2.  We need a wide-range bar (>= $1.00) on the current day.

 

3.  The open of the current day must be in the top 20% of the day's price range.

 

4. The close must be in the bottom 20% of the day's price range.

 

5. The next day the stock (gaps) up by at least $0.50 to $1.00 above the previous day's closing price.  then pass

 

 

 

Do any calculation take place in a layout after you close it.

 

Thanks

Dennis Sias     Slick8622      

Bruce_L
Posted : Monday, April 20, 2009 10:39:16 AM


Worden Trainer

Joined: 10/7/2004
Posts: 65,138
I'm pretty sure no calculations can take place on a Layout that is not open as I cannot imagine how such calculations could occur.

Assuming the only criteria for your "wide-range bar" is the range must be at least a dollar, you may wish to try the following RealCode Rule:

If Price.High(1) < Price.High(2) AndAlso _
    Price.High(2) < Price.High(3) AndAlso _
    Price.High(1) - Price.Low(1) >= 1 AndAlso _
    Price.High(1) - Price.Open(1) <= .2 * (Price.High(1) - Price.Low(1)) AndAlso _
    Price.Last(1) - Price.Low(1) <= .2 * (Price.High(1) - Price.Low(1)) AndAlso _
    Price.High(1) > Price.Last(1) AndAlso _
    Price.Open >= Price.Last(1) + .5 Then Pass

-Bruce
Personal Criteria Formulas
TC2000 Support Articles
Users browsing this topic
Guest-1

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.