- Joined
- 14 April 2007
- Posts
- 317
- Reactions
- 0
(i) do you manually carry out Daily/Weekly searches (based on the criteria of your system requirements) using your charting software to arrive at a list of trading candidates?
Additionally, with regard to position sizing and money management, can I ask how these two elements are calculated & controlled?
I can't see why the choice of the Position Size Model in TradeSim would exclude open profit.
Hi Chorlton,
I run a daily scan (using MetaStock) on the systems that i'm currently trading.
Those securities that pass the system criteria can then be printed out in a report which includes the details I require and are thus coded into the MetaStock Explorer.
For ease of placing buy/sell orders and contingent orders the reports include the the following information:-
a) Limit Buy or Limit Sell Price,
b) Number of Shares (based on a combination of % Risk and Max. Position Size),
c) Risk per Share (Contingent order re Fixed Stop),
d) Profit Stop for intra-day exit (Physical or Contingent order),
e) Volatility (For ranking if required) and
f) Turnover.
Can I ask how you include the above in a Metastock report, as I would like to explore the idea of doing something similar.
Originally posted by Chorlton
Chorlton,
I thought the easiest way to cover this was to look at an example system.
The example system I have used is based on tech/a's TechTrader but with some changes to the
entry and fixed stop rules so that they are more difficult to calculate mentally.
Revised T/T Example System (code not checked for back-testing):
EntryRule:=
CLOSE+0.25*ATR(5);
EntryTrigger:=
BarsSince(Cross(H,Ref(HHV(H,10),-1)))=0 AND
HHVBars(H,70)=0 AND C>O AND C<10.00 ANDH>Mov(C,40,E) AND Mov(V*C,21,S)>200000 AND
Ref(H,1)=EntryRule;
EntryPrice:=
If(OPEN=Ref(EntryRule,-1),OPEN,Ref(EntryRule,-1));
InitialStop:=
EntryPrice-6*Ref(ATR(10),-1);
ProfitStop:=
Ref(Mov(L,180,E),-1);
ExitTrigger:=
LOW<Ref(Mov(L,180,E),-1); {Intra-day exit}
ExitPrice:=
Ref(ProfitStop,-1)-0.01;
OtherDetails:
Original Capital = $100,000
Fixed % Risk = 2% of Original Capital = $2,000
Max. Position Size = 10% of Original Capital = $10,000
MetaStock Explorer
Name:TTC
ColumnA
Col. Name:M/M Buy {Description depends on your LONG or SHORT EntryRule}
Code:
CLOSE+0.25*ATR(5); {Minimum/Maximum BUY price}
ColumnB
Col. Name:# Shares {Based on a combination of % Risk and Max. Position Size}
Code:
ER:=CLOSE+0.25*ATR(5); {EntryRule}
DR:=6*ATR(10); {$ Risk}
PRV:=2000; {% Risk Value}
MPS:=14500; {Maximum Position Size}
No.Shares:=If((PRV/DR)*ER>MPS,MPS/ER,PRV/DR);
No.Shares;
ColumnC
Col. Name:Fixed-S {Fixed-S or $ Risk depending on the system}
Code:
CLOSE-6*ATR(10);
ColumnD
Col. Namerofit-S
Code:
Mov(L,180,E);
ColumnE
Col. Name:Vol-Rank
Code:
(ATR(30)/CLOSE)*100;
ColumnF
Col. Name:Turnover
Code:
Mov(V*C,21,S);
Filter
Code:
BarsSince(Cross(H,Ref(HHV(H,10),-1)))=0 AND
HHVBars(H,70)=0 AND C>O AND C<10.00 ANDH>Mov(C,40,E) AND Mov(V*C,21,S)>200000;
As far as I can see I haven't missed anything!!
ColumnA - (Entry Price)
The example entry price is todays CLOSE plus 1/4 of todays value of the 5 day Average True Range indicator (CLOSE+0.25*ATR(5)).
There is, of course, a possability that one is unable to take a position in this trade if the high of tomorrow does not reach the entry price.
If the system EntryRule was the OPEN of tomorrow you obviously couldn't code that in for todays scan.
Chorlton,
Before attempting your request I will make a comment on Fixed % Risk and Position Size.
When back-testing a system I never allow for the pyramiding of profits.
The sole reason for this decision being that I may eventually trade this system as a means of earning an income and therefore would not be able to re-invest the profits.
ColumnA - (Entry Price)
The example entry price is todays CLOSE plus 1/4 of todays value of the 5 day Average True Range indicator (CLOSE+0.25*ATR(5)).
There is, of course, a possability that one is unable to take a position in this trade if the high of tomorrow does not reach the entry price.
If the system EntryRule was the OPEN of tomorrow you obviously couldn't code that in for todays scan.
ColumnB - (Position Size)
Given your comments I will take it that you understand the code and the expectant results and I also acknowledge that weird has commented on an alternative approach to the one I have mentioned.
My comments at the beginning of this post may also give you a clue as to why I coded the example this way.
ColumnC - (Fixed or Initial Stop)
The Entry Price (CLOSE+0.25*ATR(5)) as detailed for ColumnA less 6 times todays value of the 10 day Average True Range indicator (-6*ATR(10)).
By now you will have worked out that I made a mistake in post # 11 and the code for ColumnC should read (CLOSE+0.25*ATR(5))-6*ATR(10) .
If the system specifies an exact Entry Price then the Fixed Stop can be calculated on the scan day, however, if the EntryRule was the OPEN of tomorrow then we would only use ColumnC to calculate the $Risk figure which is to be deducted from the OPEN of tomorrow (i.e. 6 times todays value of the 10 day Average True Range indicator) to arrive at the Fixed Stop.
ColumnD - (Profit Stop - Trailing Stop)
The profit stop in this example has been coded as an intra-day exit and is based on the value of an Exponential Moving Average (EMA) of the LOW over the last 180 days (Mov(L,180,E)).
The exit will be triggered if todays price falls below yesterdays value of Mov(L,180,E).
ColumnE - (Volatility Ranking - see Adaptive Analysis by Nick Radge)
If your system produced, for example, 4 possible trades for tomorrow, however, you only have enough free capital to enter one trade you could choose the share with the highest volatility ranking.
The volatility is calculated using todays value of the 30 day Average True Range indicator divided by the CLOSE of today. This result is multiplied by 100 to obtain a percentage result ((ATR(30)/CLOSE)*100).
ColumnF - (Turnover)
Even though there is a turnover filter in the EntryTrigger I find it helpful to know the turnover value for each position. If the turnover value is very close to my filter value I may do a quick check to see that the volume of shares traded in the last week has not jumped extraordinarily high.
The turnover value is calculated using a 21 day Simple Moving Average of the CLOSE muliplied by the VOLUME for each day (Mov(V*C,21,S)).
Hopefully this covers all the details you requested.
We use cookies and similar technologies for the following purposes:
Do you accept cookies and these technologies?
We use cookies and similar technologies for the following purposes:
Do you accept cookies and these technologies?