Picking a current price.

Discussion in 'Strategy Building' started by trader963, Sep 24, 2002.

  1. When I do a back test it fills me at the high of the current bar. If I wanted to buy when the stock breaks the previous days high how would I put that in the formula?

    For example, if i say if ........ then buy this bar,

    how can I set it up to buy at the previous days high?
  2. I'm presuming you are writing in TradeStation EasyLanguage.

    I am also presuming that this is an intraday trade that you wish to buy at yesterday's high for the day.

    The problem is difficult only in that there is a time frame switch. The code High[1] refers to one bar ago. If you were using daily data this would not be a problem. But as above I'm presuming you want to buy sometime today at yesterday's high.

    I don't have my book in front of me, but I think you should be able to refer to yesterday's high of the day using HighD[1].
  3. Inandlong,

    Hows our line in the sand system doing. We'd be up 5% already wouldn't we?