EasyLanguage

Discussions about the testing and simulation of mechanical trading systems using historical data and other methods. Trading Blox Customers should post Trading Blox specific questions in the Customer Support forum.
Post Reply
LeviF
Roundtable Knight
Roundtable Knight
Posts: 1436
Joined: Mon Dec 22, 2003 12:24 pm
Location: Des Moines, IA
Contact:

EasyLanguage

Post by LeviF »

Does this:

Code: Select all

Buy at next bar Open of next bar + BuyTrig Stop
Translate to this:

Code: Select all

broker.enterlongonstop(instrument.tradedayopen + buytrig)
Eventhorizon
Roundtable Knight
Roundtable Knight
Posts: 229
Joined: Thu Jul 08, 2010 2:36 pm
Location: Boulder, CO
Contact:

Post by Eventhorizon »

Seems to ... you can verify by putting the following into Script: Entry Orders:

Code: Select all

IF instrument.symbol = "YourSymbol" THEN
 PRINT "tradeDayOpen", instrument.tradeDayOpen, "today's open", instrument.open
ENDIF
Put a de-bugging break on the print statement. You should see tomorrow's open being returned along with today's open. I believe the idea is that tradeDayOpen allows you to "peek" into the future so you don;t have to re-set the stop price after the open.
Post Reply