Home
AN3 - Trade Pyramidding
Contents
1. L L L I 1 x ml ulu TE E zi 1 Copyright 2000 2007 by Compuvision Australia Pty Ltd All Rights Reserved Page 20 http www compuvision com au Results of a simulation vvith Trade Pyramiding Enabled AN 3 Testing Trade Pyramid Strategies using TradeSim With trade pyramiding enabled you can see from the trade log shown below that several trade pyramids have formed Also note that on the equity chart below how a common exit point on each pyramid is displayed as a sequence of exit points on the chart even though the exit point are on the same date This allows you to view all exit points even if they exit at the same point In c Cm Cn 03 p c3 Trade Symbol 1 BHF Zz BHF 3 BHF 3 BHF Es BHF 1 BHF 4 BHF 4 BHF 5 BHF E EHF E EHF 5 EHF T EHF 8 EHF 3 BHF 3 EHF 8 EHF T EHF 10 BHF 1l EHF T EHF 10 BHF 12 EHF 13 EHF 14 EHF 14 BHF 13 BHF 12 EHF 15 15 16 EHF 16 BHF 17 EHF 18 EHF 13 EHF 13 EHF 18 BHF 17 20 21 2 24 25 EHF 25 EHF 2d EHF EHF 22 EHF 2 EHF 20 EHF 26 2S EHF 28 EHF Er EHF 26 EHF 29 EHF 29 EHF 30 EHF al BHF al BHF 30 BHF ac BHF ac BHF Status Enter Enter Enter Exit Exit Exit Enter Exit Enter Enter Exit Exit Enter Enter Enter Exit Exit Exit Enter Enter Exit E
2. Total Number of trades in database 32 Earliest Entry Date 04 09 00 Latest Entry Date 08 07 02 In the following table below we have tabulated the trades in the pyramid from trade 20 to 25 The last column represents the increase in price of the underlying trade which exceeds the minimum of 3 in all cases Note that the incremental profit gain for each underlying trade in the pyramid is not representative of the total trade profit of the pyramid as this will ultimately depend on the final exit point of the pyramid Trade Entry Date Closing Price Increase in Price 20 5 Nov 2001 8 87 21 12 Nov 2001 9 16 3 27 9 82 7 21 22 14 Nov 2001 23 15 Nov 2001 10 39 5 80 24 2 Jan 2002 10 72 3 18 25 7 Jan 2002 11 24 4 86 Copyright 2000 2007 by Compuvision Australia Pty Ltd All Rights Reserved http www compuvision com au Page 15 AN 3 Testing Trade Pyramid Strategies using TradeSim Testing Trade Pyramid Strategies using TradeSim Now that we have generated a suitable trade database file using Metastock and the TradeSim plugin we will want to simulate it using TradeSim Before you do this you need to familiarize yourself with the options available in TradeSim that allow you to accomplish this When TradeSim has the ability to take a trade all level O trades are taken according to the conventional rules which normally apply to any trade in the trade database irrespective of whether or not trade pyramiding 1s
3. 10 00 of the Maximum Traded Volume Round Lot Size to L Accept partial trades if inadequate capital Accept partial trades if inadequate capital Transaction Cos Fixed Cost Fired Cost per Contract Fractional Cost Mon Trade Pyramid Rule Use Level Zero trades only 10 x Transaction Cos Fired Cost Fired Cost per Contract Fractional Cost Trade Pyramiding Rule Z Favour Trade Pyramids w Limit maximum trade level ta 2 w Limit maximum trade count to Page 19 AN 3 Testing Trade Pyramid Strategies using TradeSim Results of a simulation with Trade Pyramiding Disabled The Trade Log and Equity Chart is shown below for the Pyram d Trade Example 3 Note that only level 0 trades have been taken as all other levels are ignored when the Use Level Zero trades only option 15 enabled In 4 Trade Symbol Status Pos Trans Date Level Days Initial Sto Price Actual Price Slippage 1 EHF Enter Long 04 03 00 5 9553 5 9553 40 0000 1 1 Exit Long 01 11 00 58 s 91514 13 1514 b 4 BHF Enter Long 06 11 00 9 2942 2942 40 0000 d 4 BHF Exit Long 01 12 00 eb s 13 3533 13 3533 40 0000 4 5 EHF Enter Long 04 12 00 43 2974 3 2074 40 0000 5 5 BHF Exit Long 01 02 01 53 s 13 2475 13 2475 b B T BHP Ent
4. C Process short trades only Exit Order Typ Default Order Limit Order Market Order C Worst Case Entry Order Default Order Limit Order Market Order C Worst Case Position Size Rule Minimum Trade Size o Vulume Filter fe gnore volume Information Reject trade if Position Size is greater than fi 00 102 of the Masimum Traded Volume Limit position size to a mazimum of 10 00 of the Masimum Traded Volume Round Lot Size to L 1 Trade Preferences with Pyramiding Enabled B Trade Parameters Trade Parameters Preferences Trading Instrument Commodities Breakeven Trade Process separately Include with winning trades Include with losing trades Trade Position Type Process all trade positions Process long trades only Process short trades only Exit Order Typ Default Order Limit Order Market Order C Worst Case Entry Order Typ Default Order C Limit Order Market Order C Worst Case Copyright 2000 2007 by Compuvision Australia Pty Ltd All Rights Reserved http www compuvision com au Position Size Rule Minimum Trade Size 500 00 Vulume Filter gnore volume Information Reject trade if Position Size is greater than L 00 002 of the Maximum Traded Volume Limit position size to a mazimum of
5. Long Long Long Long Long Long Long Long Long BHP BHP BHP BHP BHP BHP BHP BHP BHP BHP 05 11 01 12 11 01 19 11 01 26 11 01 03 12 01 10 12 01 17 12 01 24 12 01 31 12 01 07 01 02 44 uu 02 01 02 02 01 02 02 01 02 02 01 02 02 01 02 02 01 02 02 01 02 02 01 02 02 1 02 02 01 02 02 m 23 02 1 TE o 8700 ib B00 2 m 1 10 1600 Am D 5 ams 1 5 11 11 11 11 11 11 11 11 11 11 11 r Long 4 02 02 z5 0 000 WT pu 11 r Long BHF 11 02 02 01 03 02 1 13 18 0 0000 11 8050 111 1 12 Long BHP 18 02 02 01 03 02 5 11 0 0000 11 7100 11 1 23 Long 25 02 02 01 03 02 3 4 0 0000 411 5600 03 11 1 4 k 3 trades selected From a total of 93 trades Total Number of trades in database 93 Earliest Entry Date 04 09 00 Latest Entry Date 29 07 02 The trade pyramid is analogous to a high rise building with each trade in the building corresponding to a floor level Level 0 is analogous to the ground floor of the building whilst the highest level trade is analogous to the highest floor of the building It should be noted that just like single isolated level 0 trades not all trades in a pyramid will be taken as this will depend on the total available trading capital at the time of the entry trigger date This is analogous to an elevator in the building which skips some floors and stops at others However just like an elevato
6. Days 48 59 25 bz 59 11 efi 11 25 h 56 20 24 56 47 56 24 Initial Sra Frice 5 3553 T3457 3 5405 3151 3 51 3 1514 3 2342 3 3633 43 2974 61 2 3 3475 3 3475 3 2318 3 7082 10 2034 110 1138 110 1138 110 1138 10 2375 10 8219 10 5314 10 5314 410 4761 10 2345 11 3303 10 8359 10 8359 10 8359 410 8020 410 0420 10 0400 3 7 900 9 8390 3 2400 3 5640 9 3500 8 3500 9 3500 9 8700 4 31600 43 8200 10 3300 410 200 11 2400 11 3000 11 3000 11 3000 11 3000 11 3000 11 3000 11 5600 11 3200 12 3900 11 6100 11 6100 11 6100 411 300 410 5500 4111200 411 4600 410 5800 410 5800 410 4800 43 3400 Copyright 2000 2007 by Compuvision Australia Pty Ltd All Rights Reserved http www compuvision com au Actual Price 2 3053 3 5403 3151 3151 3151 3 2342 3 2693 43 2874 6 2 3 34 5 3 34 5 3 2318 43 7082 10 2034 10 1198 10 1198 10 1198 10 2975 10 5213 10 5314 10 5314 410 4761 10 5345 1 3303 10 5359 10 5359 10 5359 10 8020 10 0420 10 0400 5 7900 8 8390 3 2400 5640 8 9500 8 9500 9 9500 42 5700 3 1600 3 3200 10 3900 10 7200 11 2400 11 3000 11 3000 11 3000 11 3000 11 3000 11 3000 11 5600 11 3200 12 3900 11 6100 11 6100 411 6100 411 7300 410 5500 4111200 411 4600 10 5800 1
7. EntryPrice The Profit threshold detection is made by comparing the entry price specified by the EntryPrice array to the previous re entry price of the pyramid trade Note that the base pyramid or level O trade always enters at the price specified by the EntryPrice array and new pyramid trades enter at the price specified by the EntryPrice array DailyRange The Profit threshold detection is made by comparing the daily price range to the previous re entry price and if the profit threshold 1s exceeded the trade is re entered exactly at the profit threshold point thus eliminating any slippage Note that the base pyramid or level trade always enters at the price specified by the EntryPrice array and any new pyramid trades enter at the price specified by the ProfitThreshold unless it 1s outside the daily range in which case it will automatically be constrained Using the RecordTrades function to generate pyramid trades The following examples use the RecordTrades function to generate a trade database which contains pyramid trades Firstly we shall employ the first technique of trade re entry which is based on the EntryTrigger criteria Secondly we shall employ the second technique of re entering a trade based on the underlying pending trade s profit gain Pyramid Trades based on Entry Triggers only In this instance we shall force entry and re entry into a trade on the Monday of each week and exit the trade on the first day of e
8. make quick comparisons in performance without having to regenerate a trade database provided that the maximum level limited in the database exceeds the desired maximum level Note that this limit does not take into account missed trades within a pyramid so if you need to limit the actual number of trades taken in a pyramid then you should use the Limit maximum trade count option below As an example limiting the maximum trade level to 10 will not allow trades with pyramid levels greater than 10 to be taken even though the pyramid trade sequence might consist of only five trades 1e 0 1 4 8 10 Q Limit maximum trade count to When this option is checked this parameter limits the maximum possible number of trades within a trade pyramid This count also includes the first entry level 0 trade in the pyramid During a trade pyramid the pyramid count is incremented every time another trade 1s added to the pyramid If the Copyright 2000 2007 by Compuvision Australia Pty Ltd All Rights Reserved Page 17 http www compuvision com au AN 3 Testing Trade Pyramid Strategies using TradeSim count exceeds the maximum pyramid count the trade is not taken As an example limiting the trade count to 4 will not allow more than four trades in the pyramid Running a Simulation We shall now run a trade simulation using TradeSim and the trade database generated from the Pyramid Trade Example 3 If you don t know how to do this step then it is sugg
9. that can be taken can increase dramatically as the number of securities in the portfolio increases so it is necessary to use the Monte Carlo analysis available in the Enterprise Edition of TradeSim in order to thoroughly analyse these types of trading systems Copyright 2000 2007 by Compuvision Australia Pty Ltd All Rights Reserved Page 22 http www compuvision com au AN 3 Testing Trade Pyramid Strategies using TradeSim Reference Literature This list of references is by no means exhaustive but represents material which is either recommended or for general reading 1 Compuvision Australia TradeSim User Manual 2 Equis Metastock for Windows 95 98 amp NT This is the user manual that comes with Metastock Version 7 0 and is a prerequisite for using TradeSim 3 Daryl Guppy Better Trading Wrightbooks 4 Robert P Rotella The Elements of Successful Trading New York Institute of Finance Additional Reading 5 Nauzer J Balsara A Guide To Pyramiding V 10 10 436 438 Technical Analysis of Stocks and Commodities published by Technical Analysis Inc 6 Fred Gehm Does Pyramiding make sense V 4 1 24 25 Technical Analysis of Stocks and Commodities published by Technical Analysis Inc 7 Jack K Hutson Serving a trading apprenticeship The Wyckoff method of trading stocks part 13 V 5 9 294 296 Technical Analysis of Stocks and Commodities published by Technical Analysis Inc Copyright 2000 2007 by Compuvision Aus
10. the Favour Trade Pyramiding option is enabled then the X YZ trade will be taken because it is the second trade in a pyramid whereas the ABC trade is considered to be an isolated trade even though it may be part of a pyramid trade in the future Note Even though a trade pyramid may comprise of X number of trades it does not mean that all of the trades in the pyramid will be taken even if Favour Trade Pyramiding is enabled This 1s because the rules which TradeSim uses to evaluate whether or not a trade can be taken also apply to pyramid trades TradeSim never takes a trade which could not be taken in real life Q Start Pyramid at any Level up to EW This option allows you to start a pyramid at levels greater than the base level When this option is disabled the base trade level 0 must be taken first before any other levels are taken However it is quite possible that the base trade maybe missed due to pending trades so that all of the subsequent pyramid trades will be ignored In this case you don t get another bite at the cherry Allowing the trade pyramid to start at higher levels allows the pyramid to still be built albeit not from the base level trade O Limit maximum trade level to When this option is checked this parameter limits the maximum possible level of a trade within a pyramid during a simulation Although the maximum level can be controlled at the time the trade database is generated this option allows one to
11. 0 5800 10 4800 43 3400 Slippage 40 0000 40 0000 40 0000 40 0000 40 0000 40 0000 40 0000 40 0000 40 0000 0 0000 0 0000 0 0000 0 0000 40 0000 40 0000 40 0000 0 0000 0 0000 0 0000 40 0000 40 0000 40 0000 40 0000 40 0000 40 0000 40 0000 40 0000 0 0000 40 0000 40 0000 40 0000 40 0000 40 0000 40 0000 40 0000 40 0000 40 0000 40 0000 40 0000 40 0000 40 0000 0 0000 0 0000 40 0000 0 0000 40 0000 40 0000 40 0000 40 0000 0 0000 40 0000 40 0000 40 0000 40 0000 0 0000 40 0000 40 0000 40 0000 40 0000 40 0000 40 0000 40 0000 40 0000 40 0000 Page 21 AN 3 Testing Trade Pyramid Strategies using TradeSim L 1 1 L 41 1 L 1 1 miz zu una aaa 1 1 a L Trade Pyramiding using a Portfolio The previous examples were fairly simple since they only used one security If you disable trade pyramiding and allow TradeSim to take all trades irrespective of its level by disabling the Use Level Zero trades only then you get pretty much the same results as you did by enabling trade pyramiding The reason why this is so is because we are only using one security so there isn t enough variety of available trades that can be taken so the two results end up being similar The real power of trade pyramiding comes when you use a portfolio of securities rather than the one security as in the previous example However be warned that the number of permutations and combinations of trades
12. AN 3 Testing Trade Pyramid Strategies using TradeSim Tradesim Advanced Trading Simulator and Back Tester Application Note 3 Testing Trade Pyramid Strategies using TradeSim TradeSim Version 5 x x and above TradeSim Standard Professional and Enterprise Editions TradeSim Metastock Plugin Version 7 x x and above Metastock Version 7 and above LN NN Last Update 3 April 2007 Copyright 2000 2007 by Compuvision Australia Pty Ltd All Rights Reserved Page 1 http www compuvision com au AN 3 Testing Trade Pyramid Strategies using TradeSim Contents LONENU i 2 DISCLAIMER 3 COPYRIGHT AND LICENSING AGREEMENT 4 Trademark cT 5 INTRODUCTION fa HN 6 Generating a trade database containing pyramid 5 6 Enable TradePyrami dini b n 7 ul 797 2727277 7 7 DisablelradePyram d n yu Ra apa aaa ap ee ayka 8 SetPyramidProtit I hliresholdDetectOfn ce preter te Ebert teta nee i a iii 8 Using the RecordTrades function to generate pyramid trades 8 Pyramid Trades based on Entry Triggers only 8 Pyramid Trades based on Dollar Profit Gain 1 11 Pyramid Trades ba
13. Pty Ltd All Rights Reserved http www compuvision com au Page 11 AN 3 Testing Trade Pyramid Strategies using TradeSim dummy ExtFml TradeSim Initialize dummy ExtFml TradeSim EnableTradePyramiding DollarProfit 0 12 100 dummy ExtFml TradeSim SetReturnInfoType AllTriggers ExtFml TradeSim RecordTrades Pyramid Trade example 2 Trade Data Filename LONG Trade Position Type EntryTrigger Entry Trigger EntryPrice Entry Price InitialStop Optional Initial Stop ExitTrigger Exit Trigger ExitPrice Exit Price START Start Symbol m TradeSim Pyramid Trade Example 2 mix 2 0 Initial Trade Entry in the Pyramid starts here at Level 0 All trades 1 5 in the pyramid 1 23 455 7 exit at this 1 0 point 0 5 0 5 0 0 0 0 N BHP BILLITON LIMITED EE Entry Entry Final Trade Entry in the Pyramid at Level 7 t T t ven Entry 12 0 T T Taj 11 5 Entry Entry 11 0 Entry d at 1 E 106 Entry sol 10 5 Exit 10 5 10 0 4 10 0 8 5 8 5 4 0 9 0 j5 22 2 111 pma Movember December 2002 February Example of a single Pyramid Created with Metastock by Equis 2003 Copyright 2000 2007 by Compuvision Australia Pty Ltd All Rights Reserved Page 12 http www compuvision com au AN 3 Testing Trade Pyramid Strategies using TradeSim TradeSimi amp Pyramid Trade example 2 Trade Database z R x EZ File
14. Tools Window Help m x cC El ENliEmEE Ba 0 de cm Start Simulation 21 Long BHP 18 05 01 01 06 01 3 10 14 0 0000 11 0640 10 23 Long BHP 21 05 01 01 06 01 4 q 11 40 0000 11 3303 10 23 Long BHP 04 06 01 01 08 01 41 58 40 0000 10 8020 10 1 24 Long BHP 06 08 01 01 10 01 40 56 40 0000 410 0400 9 25 Long BHP 08 10 01 01 11 01 0 12 24 40 0000 8 8390 26 Long BHP 11 10 01 01 11 01 1 15 21 40 0000 43 2400 27 Long BHP 12 10 01 01 11 01 2 14 20 0 0000 3 5640 28 Long BHP 05 11 01 01 02 02 0 BB 0 0000 8 8700 Long IHF 12 11 01 01 02 02 1 als B 0 0000 43 1600 Long BHP 14 11 01 01 02 02 2 53 79 0 0000 33 8200 3 Long BHP 15 11 01 01 02 02 3 52 niz 0 0000 0 3900 32 Long BHP 02 01 02 01 02 02 E 20 0 00010 410 200 aa Long 01 01 02 01 02 02 si E 28 0000 410 9100 Long BHP 07 01 02 01 z 26 0 0001 2135 Long BHP 24 01 02 1 02020 7 5 68 4600000 415100 471 36 Long BHP 04 02 02 01 03 0 12 25 40 0000 411 5600 11 1 37 Long BHP 05 02 02 01 03 02 1 17 24 40 0000 11 6950 11 1 38 Long BHP 06 02 02 01 03 02 2 15 23 40 0000 11 8500 11 1 39 Long BHP 13 02 02 01 03 02 3 11 16 40 0000 12 1500 11 1 40 Long BHP 14 02 02 01 03 02 4 10 15 40 0000 12 3900 11 1 41 Long BHP 04 03 02 01 05 02 0 37 58 40 0000 11 7300 r 4 k 47 trades selected From a total of 47 trades Total Number of trades in database 47 Earliest Entry Date 04 09 00 Latest Entry Date 08 07 02 In the following table b
15. ach month The following code can be used to create and indicator which can be Copyright 2000 2007 by Compuvision Australia Pty Ltd All Rights Reserved Page 8 http www compuvision com au AN 3 Testing Trade Pyramid Strategies using TradeSim overlayed directly on a chart Once this indicator 1s applied to a chart it will take a snapshot of all of the trades corresponding to the Entry and Exit triggers and then write the information out to a trade database EntryTrigger DayOfWeek 71 Initial Entry Trigger EntryPrice CLOSE InitialStop 0 ExitTrigger DayOfMonth 1 Final Exit Trigger ExitPrice CLOSE dummy ExtFml TradeSim Initialize dummy ExtFml TradeSim EnableTradePyramiding TRIGGER 0 100 dummy ExtFml TradeSim SetReturnInfoType AllTriggers ExtFml TradeSim RecordTrades Pyram d Trade example 1 Trade Data Filename LONG Trade Position Type EntryTrigger Entry Trigger EntryPrice Entry Price InitialStop Optional Initial Stop ExitTrigger Exit Trigger ExitPrice Exit Price START Start Symbol The following chart shows the above indicator and an expert which corresponds to the entry and exit triggers overlayed on a chart The top graph shows a plot of the indicator Normally the RecordTrades function returns the trade tally which if plotted should display a staircase pattern which increments by 1 at each valid exit point Because
16. an 0 are ignored This mode of operation can be overridden using the Use All Levels option Non Trade Pyramid Rule z Use Level Zero trades only Q Use Level Zero trades only When this option is checked enabled only level 0 trades are considered during a trade simulation When this option is unchecked disabled all level trades are considered during a trade simulation however the simulator does not look at constructing trade pyramids Copyright 2000 2007 by Compuvision Australia Pty Ltd All Rights Reserved Page 16 http www compuvision com au AN 3 Testing Trade Pyramid Strategies using TradeSim Trade Preferences Trade Pyramiding Enabled When the Pyram d Trades option is checked enabled on the Trade Parameters page the trade pyramiding mode is enabled during a trade simulation rade FPuram d na Rules Z Favour Trade Pyramids z Start Pyramid at any Level up to v Limit maximum Pyramid Level ta v Limit maximum Pyramid Count to Ei Favour Trade Pyramiding When this option is checked enabled TradeSim favours trades which form part of a trade pyramid rather than single isolated trades For example if a level 0 XYZ trade 1s pending and TradeSim has the choice of taking an ABC level 0 trade which appears in the trade database manager before a level 1 XYZ trade then normally TradeSim would take the ABC trade before the XYZ trade However if
17. cordTrades function to re enter a trade once an existing trade s is are pending This mode of operation where trades are piggy backed onto existing trades of the same security 1s known as trade pyram d ng The EnableTradePyramiding function allows additional trades to be taken whilst an existing trade s is are pending In additional to this there are rules which control the way that additional trades can pyramid existing trades based on your own entry trigger criteria a profit threshold criteria All trades in the pyramid will all exit at the same date although stopped out trades may exit prematurely but are still considered to be part of the pyramid In additional to this each trade in the pyramid 1s assigned a level the first trade with the earliest entry date being assigned a level of O and subsequent trades assigned 1 2 3 etc As the pyramid grows the trade with the most recent entry date 1s assigned the highest level The maximum number of levels allowable in the pyramid is determined by the MAXIMUM PYRAMID DEPTH parameter which can be any positive whole number value including zero No additional pyramid levels will be created once the Maximum Pyramid Depth is exceeded irrespective of the entry conditions The TRIGGER TYPE parameter determines the criteria for which trades can be pyramid on to existing trades o Trigger When the Trigger Type parameter is set to Trigger then additional trades ar
18. de when the percent profit threshold 15 exceeded or the EntryTrigger is asserted at the same time Q Example Copyright 2000 2007 by Compuvision Australia Pty Ltd All Rights Reserved Page 7 http www compuvision com au AN 3 Testing Trade Pyramid Strategies using TradeSim The following example sets up the conditions which allow a trade pyramid to be built based on a minimum profit threshold of 396 gain per level and a maximum pyramid depth of 20 levels ExtFml TradeSim EnableTradePyramiding PercentProfit 3 20 DisableTradePyramiding ExtFml TradeSim DisableTradePyramiding Disables the trade pyramiding mechanism switched on using the EnableTradePyramiding function Also calling the Initialize function has the same effect SetPyramidProfitThresholdDetection ExtFml TradeSim SetPyramidProfitThresholdDetection PROFIT THRESHOLD TYPE This function is used to determine the way that the profit threshold detection is measured when any profit threshold trigger type is used to re enter a pyramid trade The PROFIT THRESHOLD TYPE can have one of the following three values o ExitPrice The Profit threshold detection is made by comparing the exit price specified by the ExitPrice array to the previous re entry price of the pyramid trade Note that the base pyramid or level O trade always enters at the price specified by the EntryPrice array and new pyramid trades enter at the price specified by the ExitPrice array
19. e pyramid to existing trades based on the EntryTrigger array passed to the RecordTrades function o DollarProfit When the Trigger Type parameter is set to DollarProfit then additional trades are pyramid to existing trades based on whether or not the currently highest level trade exceeds a certain dollar profit threshold with respect to the previous entry point This allows a trade pyramid to be built up by taking advantage of a rising and profitable trend Note that the profit parameter is specified in dollars and not cents o DollarProfitAndTrigger Re enters a trade when the dollar profit threshold is exceeded and the EntryTrigger is asserted at the same time o DollarProfitOrTrigger Re enters a trade when the dollar profit threshold is exceeded or the EntryTrigger is asserted at the same time o PercentProfit When the Trigger Type parameter is set to PercentProfit then additional trades are pyramid to existing trades based on whether or not the currently highest level trade exceeds a certain percent profit threshold with respect to the entry price of the previous pyramid entry point This allows a trade pyramid to be built up by taking advantage of a rising and profitable trend Note that the Percent Profit parameter is expressed as a percentile o PercentProfitAndTrigger Re enters a trade when the percent profit threshold 1s exceeded and the EntryTrigger is asserted at the same time o PercentProfitOrTrigger Re enters a tra
20. elow we have tabulated the trades in the pyramid from trade 22 to 28 The last column represents the dollar increase in price of the underlying trade which exceeds the minimum of 12 cents in all cases Note that the incremental profit gain for each underlying trade in the pyramid 1s not representative of the total trade profit of the pyramid as this will ultimately depend on the final exit point of the pyramid Trade Entry Date Closing Price Increase in Price 28 5 Nov 2001 8 87 29 12 Nov 2001 9 16 0 29 3 3 2 2 Jan 2002 10 72 0 33 3 4 Jan 2002 10 91 0 19 34 7 Jan 2002 11 24 0 33 35 24 Jan 2002 11 51 0 27 Pyramid Trades based on Percent Profit Gain only In this case we shall force the initial entry into a trade starting on the each Monday and re enter additional trades every time the profit gain of the underlying trade exceeds 3 In this way we add additional positions during a rising trend and refrain from adding positions during a declining trend Note that there 1s no guarantee that this strategy will result in an overall profitable set of trades as this will ultimately depend on the final exit point of each pyramid which in this case 1s the first day of the month Once again this method reinforces the importance of the exit strategy The following code can be used to create an indicator which can be overlayed directly on a chart Once this indicator 1s applied to a chart it will take a snapshot of all of the trade
21. enabled and the level 0 forms part of a trade pyramid The reason why this 1s because it never known in advance whether or not a trade will form a trade pyramid or whether the first trade will exit before any other trades can be added to the pyramid This is part of TradeSim s realistic approach to Trade Simulation Consider the following example where two level 0 trades hereafter known as ABC and XYZ trades are available to be taken by TradeSim It is known that trade ABC is a single isolated trade whereas trade XYZ forms the base of a trade pyramid with an additional five more pyramid trades If trade pyramiding 1s enabled and TradeSim has enough capital to take either but not both trades then trade ABC will be taken and trade XYZ will be rejected even though trade XYZ forms a trade pyramid Setting up TradeSim Trade Parameters Position Size Mode f Equal Dollar Units Equal Percent Dollar Units C Fired Dollar Risk Fixed Percent Risk 5 Trades Furamid Profits O Pyramid Trades When a simulation is run in TradeSim pyramid trades level greater than 0 are normally ignored However when the Pyramid Trades option is checked then pyramid trades are included in the simulation Trade Preferences Trade Pyramiding Disabled When the Pyramid Trades option is unchecked disabled on the Trade Parameters page no trade pyramiding is constructed during a trade simulation and trades with a level greater th
22. er In no event shall Compuvision Australia or its suppliers be liable for any damage either direct or indirect including without limitation damages for loss of business profits business interruption loss or business information or other losses arising out of the use of or inability to use the software The results obtained from using this software are not indicative of and have no bearing on any results which may be attained in actual trading Results of past performance are no guarantee of future performance It should not be assumed that you would experience results comparable to that reflected by the results from this software No assurance is given that you will not incur substantial losses nor shall Compuvision Australia Pty Ltd be held liable if losses are incurred Compuvision Australia Pty Ltd is not a licensed investment advisor and so the information and results obtained by using this software 1s for educational purposes and of the nature of a general comment and neither purports nor intends to be specific trading advice The information obtained from using this software should not be considered as an offer or enticement to buy sell or trade and is given without regard to any particular person s investment objectives financial situation and particular needs This software is not designed to replace your Licensed Financial Consultant or your Stockbroker You should seek appropriate advice from your broker or licensed investment advis
23. er Long 05 02 01 gt 13 2318 13 2318 40 0000 T BHF Exit Long 01 03 07 24 s 10 1134 10 113 b 9 10 Enter Long 05 03 01 10 2975 10 2375 40 0000 3 10 BHP Exit Long 01 05 07 Ti s 10 5314 10 5314 b 10 12 EHF Enter Long 07 05 01 10 4781 10 4751 40 0000 1i 12 Exit Long 01 06 01 25 10 85355 10 5355 b t 12 15 EHF Enter Long 04 06 01 10 8020 10 5020 40 0000 13 15 EHF Exit Long 01 08 07 58 10 04 20 10 0420 40 0000 4 16 BHF Enter Long 06 03 01 410 0400 10 0400 b t 15 16 BHF Exit Long 01 10 01 hb 5 7300 5 7300 b 16 T EHF Enter Long 08 10 01 5 5330 9 8390 40 0000 T T EHF Exit Long 01 11 01 24 5 3500 45 5500 b 18 20 EHF Enter Long 05 11 01 5 5700 45 5700 40 0000 13 20 Exit Long 01 02 02 Gir 11 2000 411 2000 b eu 26 EHF Enter Long 04 02 02 11 5600 411 5600 40 0000 2 26 EHF Exit Long 01 03 02 eh 11 6100 411 6100 b ez 29 BHF Enter Long 04 03 02 i11 7300 1 7300 40 0000 23 29 BHF Exit Long 01 05 02 ha 10 5500 10 4500 40 0000 24 30 EHF Enter Long 06 05 02 11 1200 411 1200 40 0000 eh 30 BHF Exit Long 01 07 02 hb 10 5200 10 5200 b eB 32 EHF Enter Long 08 07 02 10 4200 10 4200 40 0000 er 3e EHF Exit Long 01 08 02 24 5 3400 5 3400 b R i 1 r I r
24. ested that you read the TradeSim User Manual 1 First we will run a simulation without trade pyramiding enabled and then compare it to a simulation run with trade pyramiding enabled The following trade parameters and preferences will be used Trade Parameters and Preferences ET Trade Parameters b n xi Trade Parameters Preferences Position Size Mode Equal Dollar Units Equal Percent Dollar Units C Fired Dollar Risk Fired Percent Risk Pyramid Trades Pyramid Profits Simulation Trade Parameter Initial Trading Capital Maximum Oper Positions 50000 00 fi 00 Limit L 00 00 Transaction Cost 0 00 Capital per Trade 5000 00 Portfolio Simulation Portfolio Simulation Ignore Dates Basket test Monte Calo Analysis Simulation Option f Use Original Ordering C Random Walk Copyright 2000 2007 by Compuvision Australia Pty Ltd All Rights Reserved Page 18 http www compuvision com au AN 3 Testing Trade Pyramid Strategies using TradeSim 1 Trade Preferences with Pyramiding Disabled Ef Trade Parameters E l R x Trade Parameters Preferences Trading Instrument Stocks Commodities Breakeven Trade Process separately C Include with winning trades Include with losing trades Trade Position Type Process all trade positions Process long trades only
25. ity The theory of trade pyramiding is fairly straightforward Typically you initially enter a position in an upwardly trending security and then add additional positions based on a certain criteria as the trend grows In this way you take advantage of a rising trend But this is not the only criterion for pyramiding trades and TradeSim gives you the flexibility to allow you to experiment with many other strategies including your own custom re entry strategies TradeSim allows you to construct a trade pyramid by re entering the same security any number of times until a valid exit trigger 1s found in which case all of the trades in the pyramid are closed The criteria that allow a trade to be re entered can be based on your own entry criteria or it can be based on a profit gain from the underlying pending trade Either way you have full control over the way a trade 1s re entered Also you can control the maximum number of times a trade can be re entered so that the pyramid size can be limited Once a trade database has been built and loaded into TradeSim you then have further control over the trade pyramid process TradeSim can be setup to completely ignore the pyramid trades default operation or it can be made to favour trade pyramids as opposed to isolated trades which were not part of any pyramid You also have the same control over position size as you did previously with independent trades You can compare a trade pyramid strategy with its non trade
26. n the trade database manager The group of trades highlighted in the trade database manager from trade 58 to 69 correspond to the entry triggers ranging from 5 Nov 2001 to 21 Jan 2002 All of these triggers exit at the same point in time 1e 1 Feb 2002 If Trade Pyramiding were disabled when the trade database exploration was run the entry triggers from 12 Nov 2001 to 21 Jan 2002 would not have been written to the trade database Also note that in the trade database manager each trade is assigned a level with level 0 corresponding to the earliest trade and the highest level is assigned to the last trade in the pyramid Copyright 2000 2007 by Compuvision Australia Pty Ltd All Rights Reserved http www compuvision com au Page 10 TradeSimi amp Pyramid Trade example 1 Trade Database AN 3 Testing Trade Pyramid Strategies using TradeSim E File Tools Window Help cs mu RN mx EmHmNl u E 6 s d 2 star Simulation R x xi LT Pos Symbol EntyDate Et Date Level Bars Days Initial Stop 53 Long 01 10 01 01 10 01 B 0 0000 7900 5 564 Long BHP 08 10 01 01 11 01 18 24 0 0000 5 8390 5 55 Long BHP 15 10 01 01 11 01 1 13 17 40 0000 3 4460 t5 als Long BHP 22 10 01 01 11 01 R 10 0 0000 43 0000 5 57 Long BHP 29 10 01 01 11 01 3 3 0000 13 3520 5 68 HE BO b2 53 5 5h 55 Tis Long Long Long
27. on The Vendor reserves the right to revoke your license if you violate any or all of the terms of this license agreement without prior notice Trademarks 1 TradeSim is a registered trademark of Compuvision Australia Pty Ltd 2 MetastockQ is a registered trademark of Equis International 3 Microsoft Windows is a registered trademark of Microsoft Corporation 4 Microsoft Excel is a registered trademark of Microsoft Corporation 5 Word for Windows is a registered trademark of Microsoft Corporation 6 TradeStation is a registered trademark of Omega Research Corporation Copyright 2000 2007 by Compuvision Australia Pty Ltd All Rights Reserved Page 5 http www compuvision com au AN 3 Testing Trade Pyramid Strategies using TradeSim Introduction Much has been written about trade pyramiding trading strategies 3 4 It is not the purpose of this document to debate the merits of such systems but rather to show how you can use Metastock and TradeSim to comprehensively test such systems Previously it was difficult to use TradeSim to test trade pyramiding strategies because the RecordTrades function would not allow you to re enter a trade once an existing trade was pending This meant that although it was possible for trades from other securities to overlap each other in time and be traded concurrently in TradeSim there was no way of specifically controlling the mechanism that would allow you to pyramid a position from the same secur
28. or before taking any action Copyright 2000 2007 by Compuvision Australia Pty Ltd All Rights Reserved Page 3 http www compuvision com au AN 3 Testing Trade Pyramid Strategies using TradeSim Copyright and Licensing Agreement TradeSim is Copyright 2000 2003 by Compuvision Australia Pty Ltd TradeSim is a trademark of Compuvision Australia Pty Ltd IMPORTANT READ CAREFULLY This license statement and limited warranty constitutes a legal agreement License Agreement between you Licensee either as an individual or a single entity and Compuvision Australia Pty Ltd Vendor for the software product TradeSim Software of which Compuvision Australia Pty Ltd is the copyright holder BY INSTALLING COPYING OR OTHERWISE USING THE SOFTWARE YOU AGREE TO BE BOUND BY ALL OF THE TERMS AND CONDITIONS OF THE LICENSE AGREEMENT Upon your acceptance of the terms and conditions of the License Agreement Compuvision Australia Pty Ltd grants you the right to use the Software in the manner provided below If you do not accept the terms and conditions of the License Agreement you are to promptly delete each and any copy of the Software from your computer s This license agreement only applies to the software product TradeSim and not to any other product even if that product is similar to TradeSim and has a similar name The Vendor reserves the right to license the same Software to other individuals or entities under a differen
29. pyramid counterpart simply by checking and un checking a checkbox As well as testing a trade pyramid strategy in 1solation for a single security you can also use TradeSim s true portfolio trading engine to test it by mixing it with independent and pyramid trades from other securities The basket tester in TradeSim also allows you test securities in isolation and rank and compare the performance of each security No other system tester to date offers such flexibility Generating a trade database containing pyramid trades As a perquisite for reading and understanding the material presented in this document you should already be very familiar with using TradeSim and the concept of generating a trade database If you are not familiar with TradeSim then it suggested that you read the TradeSim User Manual 1 Before you can test your trade pyramid strategies you need to know how to generate a trade database which contains pyramid trades The TradeSim dll Metastock plugin facilitates this by including two new functions called EnableTradePyramiding and DisableTradePyramiding We will now discuss these two functions in detail Copyright 2000 2007 by Compuvision Australia Pty Ltd All Rights Reserved Page 6 http www compuvision com au AN 3 Testing Trade Pyramid Strategies using TradeSim Enable TradePyramiding ExtFml TradeSim EnableTradePyramiding TRIGGER TYPE PROFIT THRESHOLD MAXIMUM PYRAMID DEPTH This function is used to allow the Re
30. r it must always start at the ground floor ie level 0 before it can reach higher levels When the Pyramid Trades option is enabled and if TradeSim cannot take a level O trade then no other trades in the pyramid will be taken unless the Favour Pyramid Trades option is disabled Pyramid Trades based on Dollar Profit Gain only In this case we shall force the initial entry into a trade starting on the each Monday and re enter additional trades every time the dollar profit gain of the underlying trade exceeds 12 cents In this way we add additional positions during a rising trend and refrain from adding positions during a declining trend Note that there is no guarantee that this strategy will result in an overall profitable set of trades as this will ultimately depend on the final exit point of each pyramid which in this case is the first day of the month Once again this method reinforces the importance of the exit strategy The following code can be used to create an indicator which can be overlayed directly on a chart Once this indicator 1s applied to a chart it will take a snapshot of all of the trades corresponding to the Entry and Exit triggers and then write the information out to a trade database EntryTrigger DayOfWeek 1 Initial Entry Trigger EntryPrice CLOSE InitialStop 0 ExitTrigger DayOfMonth 1 Final Exit Trigger ExitPrice CLOSE Copyright 2000 2007 by Compuvision Australia
31. r version the Licensee already has In the latter case the Licensee will no longer be entitled to technical support until the Licensee has upgraded to the latest version The Vendor reserves the right to charge an upgrade fee in the case of major new enhancements or additions to the Software This major new version will then start a new version line which will use version numbers Copyright 2000 2007 by Compuvision Australia Pty Ltd All Rights Reserved Page 4 http www compuvision com au AN 3 Testing Trade Pyramid Strategies using TradeSim clearly distinguishable from the old version line The Licensee has no obligation to upgrade to the new version line You must not attempt to reverse compile modify translate or disassemble the Software in whole or in part You must not run the Software under a debugger or similar tool allowing you to inspect the inner workings of the Software The Software remains the exclusive property of the Vendor Any Licensee which fully complies with the terms in this license agreement may use it according to the terms of this license agreement You must not give copies of the Software or your license key to other persons or entities If you have received a download password or an URL with an embedded password for downloading the Software you must keep this password secret You must also take reasonable steps to prevent any third party from copying the software from one of your machines without your permissi
32. s corresponding to the Entry and Exit triggers and then write the information out to a trade database Copyright 2000 2007 by Compuvision Australia Pty Ltd All Rights Reserved Page 13 http www compuvision com au AN 3 Testing Trade Pyramid Strategies using TradeSim EntryTrigger DayOfWeek 71 Initial Entry Trigger EntryPrice CLOSE InitialStop 0 ExitTrigger DayOfMonth 1 Final Exit Trigger ExitPrice CLOSE dummy ExtFm1l TradeSim Initialize dummy ExtFml TradeSim EnableTradePyramiding PercentProfit 3 100 dummy ExtFml TradeSim SetReturnInfoType AllTriggers ExtFml TradeSim RecordTrades Pyramid Trade example 3 Trade Data Filename LONG Trade Position Type EntryTrigger Entry Trigger EntryPrice Entry Price InitialStop Optional Initial Stop J ExitTrigger Exit Trigger ExitPrice Exit Price START Start Symbol m TradeSim Pyramid Trade Example 2 mi xi 2 0 2 0 Initial Trade Entry in the Pyramid starts here at Level 0 1 5 All trades in the 10 23 pyramid exit at this point 0 5 0 0 0 0 m GHP BILLITON LIMITED mixi Entry Entry 12 5 Entry 4 Et 12 5 12 0 Tu a f 12 0 11 5 15 Uu 415 11 0 11 0 10 5 Es 10 5 10 0 Entry m7 A 10 0 8 5 8 5 4 0 4 0 j5 22 191 112 ps 26 js ho fr 24 131 fpa 121 129114 111 pma Movember December 2002 February Example of a single Pyramid Created with Metastock by Equis 2003 Copyrigh
33. sed on Percent Profit Gain only 13 Testing Trade Pyramid Strategies using TradeSim eee eee e eere eee ee eene 16 DOCOMO up Trades iMi 16 Trade mn et nla 16 ui 16 Trade Preferences Trade Pyramiding 1 4 16 Q Use Level Zero trades only 8 8888888888888888888888 8888838 3333333333333333 16 Trade Preferences Trade Pyramiding 1 4 17 Oh Favour Trade Pyramiding 17 Start Pyramid at any Level up to a essen Ly Limit maximum trade level to sse nennen eene eene eene nennen 17 ul Limit maximum trade count 17 Kunninz a SUNT AIO ss daaa 18 Trade Parameters ira rm lad 18 Q Trade Preferences with Pyramiding Disabled sess 19 Q Trade Preferences with Pyramiding 1 4 19 Results of a simulation with Trade Pyramiding 15 1 20 Results of a simulation with Trade Pyramiding 1 4 21 Trade Pyram ding using Portfolio yadda m d y adad 22 IR PRE RENCE LITERATI RE UDUR 23 oullunulLuncea nan l 23 Copyright 2000 2007 by Compuvision Australia Pty Ltd All Rights Reserved Page 2 http www compuvision com au AN 3 Testing Trade Pyramid Strategies using TradeSim Disclaim
34. t 2000 2007 by Compuvision Australia Pty Ltd All Rights Reserved Page 14 http www compuvision com au Trade Simig Pyramid Trade example 3 Trade Database AN 3 Testing Trade Pyramid Strategies using TradeSim E File Tools Window Help R x 16 xi c ulBniemikunsoHaA silaii Start Simulation Ta Long BHP 07 05 01 01 06 01 T3 20 0 0000 10 4781 10 1 13 Long BHP 17 05 01 01 06 01 11 15 0 0000 10 8345 10 1 14 Long BHP 21 05 01 01 06 01 Z 11 0 0000 11 5303 10 1 15 Long BHF 04 06 01 01 08 01 4 55 0 0000 10 5020 101 16 Long BHP 06 06 01 01 10 01 40 AB 0 0000 10 04 a 17 Long BHP 08 10 01 01 11 01 18 24 0 0000 6 0390 i3 18 Long BHP 11 10 01 01 11 01 1 15 21 0 0000 3 2400 i3 13 Long BHP 12 10 01 01 11 01 20 0 0000 3 5640 i3 2 Long 05 11 01 01 02 02 0 0000 5 8700 111 2 Long 12 11 01 01 02 02 1 0 0000 3 1600 111 22 Long 14 11 01 01 02 02 2 0 0000 43 8200 311 22 Long 15 11 01 01 02 02 amp 0 0000 KU 11 2 Long 02 01 02 4 a 0 0000 410 7200 11 2b Long BHP 04 02 02 01 03 02 18 z5 0 0000 411 5600 1111 27 Long BHP 12 02 02 01 03 02 1 lz 17 40 0000 411 9200 11 1 26 Long BHP 14 02 02 01 03 02 2 10 15 40 0000 12 3900 111 1 zd Long BHP 04 03 02 01 05 02 y Qu 0 0000 11 7300 10 30 Long BHP 06 05 02 01 07 02 38 56 0 0000 11 1200 10 31 Long BHP 15 05 02 01 07 02 1 31 47 40 0000 11 4600 10 Long BHP 08 07 02 01 08 02 15 24 0 0000 10 4800 4
35. t license agreement After accepting this license agreement the Licensee is permitted to use the Software under the terms of this agreement Under this license agreement the Software can only be used by those persons or entities that have purchased a license key Payment information 18 available at http www compuvision com au PurchaseOnline htm The Software is provided as is In no event shall Compuvision Australia Pty Ltd be liable for any consequential special incidental or indirect damages of any kind arising out of the delivery performance or use of this Software to the maximum extent permitted by applicable law While the Software has been developed with great care it is not possible to warrant that the Software is error free The Software is not designed nor intended to be used in any activity that may cause personal injury death or any other severe damage or loss When errors are found in the Software the Vendor will release a new version of the Software that may no longer contains those errors a reasonable amount of time after the Vendor is given an accurate description of those errors Which amount of time is reasonable will depend on the complexity and severity of the errors The Vendor will mention the release at http www compuvision com au at the Vendor s option directly contact the Licensee to announce the new release The Licensee can then at their option upgrade to the latest version or to continue to use the olde
36. tralia Pty Ltd All Rights Reserved Page 23 http www compuvision com au
37. we have set the return information type to AllTriggers the indicator returns the actual entry and exit trigger points that were recorded to the trade database A value of 1 returned indicates a valid entry trigger whilst a value of 2 indicates a valid exit trigger A value of 3 indicates the combination of a valid entry and exit trigger which occurs on the same day These entry and exit triggers match up with the expert entry and exit points in the chart below it Copyright 2000 2007 by Compuvision Australia Pty Ltd All Rights Reserved Page 9 http www compuvision com au AN 3 Testing Trade Pyramid Strategies using TradeSim TradeSim Pyramid Trade Example 1 2 0 1 5 1 0 0 5 0 0 Initial Trade Entry in the Pyramid starts here at Level 0 1 2 3 4 5 t 8 8 10 11 L BHP BILLITON LIMITED 12 5 12 0 11 5 11 0 10 5 10 0 9 5 9 0 Final Trade Entry in the Pyramid at Level 11 Movember December 2002 Example of a single Pyramid Created with Metastock by Equis 2003 AlI trades in the pyramid exit at this point D 5 D n E x Entry Entry Entry n E 12 5 Tf 12 0 tomy 11 5 11 0 10 5 10 0 9 5 4 0 50 122 fag set hr 124 s 114 21 129 114 1 hes February If you load up the corresponding trade database file in TradeSim you can view all of the trades in the trade database manager The following screenshot displays some of the trades i
38. xit Enter Enter Enter Exit Exit Exit Enter Exit Enter Exit Enter Enter Enter Exit Exit Exit Enter Enter Enter Enter Enter Enter Exit Exit Exit Exit Exit Exit Enter Enter Enter Exit Exit Exit Enter Exit Enter Enter Exit Exit Enter Exit Fuz Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Lang Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Long Trans Date 04 09 00 08 09 00 14 03 00 01 11 00 01 11 00 01 11 00 06 11 00 01 12 00 04 12 00 11 12 00 01 02 01 01 02 01 08 02 01 23 02 01 27 02 01 01 03 01 01 03 01 01 03 01 06 03 01 20 04 01 01 05 01 01 05 01 07 05 01 Tr 5 01 21 05 01 01 06 01 01 06 01 01 06 01 04 06 01 01 03 01 06 03 01 01 10 01 03 10 01 11 10 01 12 10 01 01 11 01 01 11 01 01 11 01 05 11 01 12 11 01 14 11 01 15 11 01 02 01 02 07 01 02 01 02 02 01 02 02 01 02 02 01 02 02 01 02 02 01 02 02 04 02 02 12 02 02 14 02 02 01 03 02 01 03 02 01 03 02 04 03 02 01 05 02 06 05 02 16 05 02 01 07 02 01 07 02 08 07 02 01 08 02 Level coe oc a Boe O ho ee ee oe Ka ee cae eae ee eo ee ea eae ee he oe eo e oe
Download Pdf Manuals
Related Search
Related Contents
VCC-4790P VCC-4795P Garanzia - Chaker Jeux Copyright © All rights reserved.
Failed to retrieve file