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

Notification

Icon
Error

Options
Go to last post Go to first unread
Flexi  
#1 Posted : Thursday, December 13, 2007 11:06:21 AM(UTC)
Flexi

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 5/27/2006(UTC)
Posts: 135

There are entry strategies which utilize buying at price beside OHLC. However metastock does not seems to cater to testing these entry methods. Wonder if anyone has a probable solution.

One entry method is to buy at bar high + 1 point.

For example, today bar has a buy setup.
If tommorrow price open below today high, buy at high + 1 point.
If tommorrow price open above today high, buy at open.

Flexi
Using ms8 and tradesim 4

oztrader  
#2 Posted : Thursday, December 13, 2007 6:30:54 PM(UTC)
oztrader

Rank: Advanced Member

Groups: Registered, Registered Users, Unverified Users
Joined: 7/12/2007(UTC)
Posts: 134
Location: Perth Western Australia

Flexi,

Assuming you are writing the code for back testing in TradeSim then try something along these lines.

Entry Trigger:=Ref(BuySetup,-1); {"BuySetup" = the rules and filters that must be satisfied for the system to give a buy signal}

EntryPrice:= If (OPEN<=Ref(HIGH,-1),Ref(HIGH,-1)+0.01,OPEN);

This code is written on the basis that the “BuySetup” happened yesterday and this is the buy instruction for today.

oztrader

Flexi  
#3 Posted : Thursday, December 13, 2007 11:44:26 PM(UTC)
Flexi

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers
Joined: 5/27/2006(UTC)
Posts: 135

Hi oztrader,

Tradesim allow buying at H+1 but the software does not cater to optimisation. Pefer to implement the Ref(H,-1)+1 in MS system tester. MS8 allow OHLC but not variable price entry. Does v9 or v10 allow this? Or a custom code is possible to buy Ref(H,-1)+1?

Tks.

oztrader  
#4 Posted : Friday, December 14, 2007 4:50:04 PM(UTC)
oztrader

Rank: Advanced Member

Groups: Registered, Registered Users, Unverified Users
Joined: 7/12/2007(UTC)
Posts: 134
Location: Perth Western Australia

Hi Flexi,

I had a look at the v9 manual and it would appear to have the same constraints as v8.

Best of luck with the optimising.

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.