SlideShare una empresa de Scribd logo
1 de 16
Descargar para leer sin conexión
ApplyStop Intro 1/2
AMIBROKER QUANT COURSE
73
When to sell?
1. Sell Signals
• Sell = sellConMKC AND (sellCon1 AND sellCon2 …);
2. Stop Triggers
• ApplyStop( stopTypeLoss, stopModePercent, 15);
3. Better opportunities
• Calculate current positions
• Calculate opportunities, and then compare to current positions
• Force sell signals, and then enter a better opportunity
Note: use CBI to perform 3.
74
Facts about Stop Triggers
•Stops can help or hurt your results
•Change of degree in stop could result favorably or unfavorably
•Limitation in AmiBroker
•Backtesting VS Execution
•Keep it manageable and executable; otherwise, don’t use it
75
Basic ApplyStop in AmiBroker
76
ApplyStop( Type, Mode, Amount);
• stopTypeLoss
• stopTypeProfit
• stopTypeNBar
• stopTypeTrailing
• stopModePoint
• stopModePercent
• stopModeBars
• stopModeRisk
• Number: 15
• Point
• Percent
• Bars
• Array: 3ATR(14)
77
40 days
100
100
120
Profit from High = 120 – 100 = 20, then 10% profit = 2
118
100
120
High at 120, 10% = 12
High at 110, 10% = 11
108
99
-10%
100
90
10%
100
110
ApplyStop(stopTypeLoss,
stopModePercent, 10);
ApplyStop(stopTypeProfit,
stopModePercent, 10);
ApplyStop(stopTypeNBar,
stopModeBars, 40);
ApplyStop(stopTypeTrailing,
stopModePercent, 10);
ApplyStop(stopTypeTrailing,
stopModeRisk, 10);
EASY ?
Not so fast !
78
More Details of ApplyStop in AmiBroker
79
• Trade Price: SellPrice = Open or Close
• ExitAtStop: 0, 1, or 2
• Volatility: True or False
• ReEntryDelay: especially in Sideways and many false signals
• ValidFrom & ValidTo: especially in stopModeRisk
• ActivateStopsImmediately: On or Off
Note: please study https://www.amibroker.com/guide/afl/applystop.html
ApplyStop(Type, Mode, Amount, ExitAtStop, Volatility, ReEntryDelay, ValidFrom, ValidTo);
WARNING
Can Code, but Not Execute = Useless
Can Execute, but Not Understand = Risky
80
ApplyStop Intro 2/2
AMIBROKER QUANT COURSE
81
Facts about ApplyStop in AmiBroker
•Compatibility between stopType and stopMode matters
• stopTypeNBar not compatible with stopModePercent
•Compatibility between stopMode and stopAmount matters
• stopModePercent not compatible with stopAmount 3ATR()
•Only one stopMode per one stopType is used
1. ApplyStop(stopTypeTrailing, stopModePercent, 15); //over ruled by next line
2. ApplyStop(stopTypeTrailing, stopModeRisk, 15);
•Keep it manageable and executable; otherwise, don’t use it
82
stopType… and stopMode… in AmiBroker
83
stopType…
stopMode…
Measured FromPoint Percent NBars Risk
Loss Entry price
Profit Entry price
NBar Entry bar
Trailing (1) (1) (2)
(1) % from High
(2) % from High - Entry
ApplyStop( Type, Mode, Amount, ExitAtStop, Volatility, ReentryDelay, ValidFrom, ValidTo);
stopMode… and stopAmount given: ATR(14) = 5
•ApplyStop(stopTypeLoss, stopModePoint, 10); //Entry: 125 -> then: 115
•ApplyStop(stopTypeLoss, stopModePercent, 10); //125->112.5
•ApplyStop(stopTypeLoss, stopModePercent, 2*ATR(14)); //Run, but non-sense
•ApplyStop(stopTypeLoss, stopModePoint, 2*ATR(14)); //125->115
•ApplyStop(stopTypeProfit, stopModePoint, 10); //Entry: 125 -> then: 135
•ApplyStop(stopTypeProfit, stopModePercent, 10); //125->137.5
•ApplyStop(stopTypeProfit, stopModePercent, 2*ATR(14));
•ApplyStop(stopTypeProfit, stopModePoint, 2*ATR(14)); //125->135
84
stopMode… and stopAmount given: ATR(14) = 5
•ApplyStop( stopTypeNBar, stopModeBars, 40); // Bar 0 until Bar 40
•ApplyStop( stopTypeNBar, stopModePercent, 40); //Run, but non-sense
•ApplyStop( stopTypeNBar, stopModePoint, 40); //Run, but non-sense
•ApplyStop( stopTypeTrailing, stopModePoint, 25); //100->125->100
•ApplyStop( stopTypeTrailing, stopModePoint, 5*ATR(14)); //100->125->100
•ApplyStop( stopTypeTrailing, stopModePercent, 25); //100->125->93.75
•ApplyStop( stopTypeTrailing, stopModeRisk, 25); //100->125->118.75
85
stopTypeTrailing with stopModeRisk
•ApplyStop( stopTypeTrailing, stopModeRisk, 25); //100->104->103 ???
•ApplyStop( stopTypeTrailing, stopModeRisk, 25, … , … , …, 20); // ValidFrom
86
ApplyStop( Type, Mode, Amount, ExitAtStop, Volatility, ReentryDelay, ValidFrom, ValidTo);
Conclusion for Basic ApplyStop in AmiBroker
•Not executable or not understand it, Don’t use it !
•Keep it simple and straightforward
•Prefer the followings:
• ApplyStop(stopTypeLoss, stopModePercent, 10); // 5 to 15%;
• ApplyStop(stopTypeProfit, stopModePercent, 20); // 15 to 35%;
• ApplyStop(stopTypeTrailing, stopModePercent, 25); // 20 to 30%;
• ApplyStop(stopTypeNBar, stopModeBars, 40); // Depends on strategy
•Keep stop co-ordinate and logical
•Read: https://www.amibroker.com/guide/afl/applystop.html
87
WARNING (AGAIN)
Can Code, but Not Execute = Useless
Can Execute, but Not Understand = Risky
88
Note: please study https://www.amibroker.com/guide/afl/applystop.html

Más contenido relacionado

La actualidad más candente

Fibonacci Trading for DW Traders
Fibonacci Trading for DW TradersFibonacci Trading for DW Traders
Fibonacci Trading for DW TradersPragasit Thitaram
 
Section 2 - Chapter 9 Part II - Short Tem Pattern - Bar Chart Reversal Patterns
Section 2 - Chapter 9 Part II - Short Tem Pattern  - Bar Chart Reversal PatternsSection 2 - Chapter 9 Part II - Short Tem Pattern  - Bar Chart Reversal Patterns
Section 2 - Chapter 9 Part II - Short Tem Pattern - Bar Chart Reversal PatternsProfessional Training Academy
 
MASTERING THE INTRADAY.pdf
MASTERING THE INTRADAY.pdfMASTERING THE INTRADAY.pdf
MASTERING THE INTRADAY.pdfSmash Fintech
 
Amibroker afl coding 28th atma bengaluru meet
Amibroker afl coding   28th atma bengaluru meetAmibroker afl coding   28th atma bengaluru meet
Amibroker afl coding 28th atma bengaluru meetMarketcalls
 
Top 10 Tips For Stock Trading In India |Stock Market Tips
Top 10 Tips For Stock Trading In India |Stock Market TipsTop 10 Tips For Stock Trading In India |Stock Market Tips
Top 10 Tips For Stock Trading In India |Stock Market TipsDhanashri Academy
 
How Day Traders Do 200 Trades a Day and Strategies They Use
How Day Traders Do 200 Trades a Day and Strategies They UseHow Day Traders Do 200 Trades a Day and Strategies They Use
How Day Traders Do 200 Trades a Day and Strategies They UseAlpesh Patel
 
LC's Forex Trading System
LC's Forex Trading SystemLC's Forex Trading System
LC's Forex Trading Systemlcchong76
 
Top 8 Forex Trading Strategies That Pro Traders Use
Top 8 Forex Trading Strategies That Pro Traders UseTop 8 Forex Trading Strategies That Pro Traders Use
Top 8 Forex Trading Strategies That Pro Traders UseSyrous Pejman
 
FOREX SCALPING STRATEGY
FOREX SCALPING STRATEGYFOREX SCALPING STRATEGY
FOREX SCALPING STRATEGYOptionsTekkers
 
Support and resistance trading
Support and resistance tradingSupport and resistance trading
Support and resistance tradingmgeek007
 
Simple scalping secret strategy
Simple scalping secret strategySimple scalping secret strategy
Simple scalping secret strategyHeri Valiant
 
How to Become a Professional Trader
How to Become a Professional TraderHow to Become a Professional Trader
How to Become a Professional Trader My Trading Skills
 
Simple trading strategy for beginners
Simple trading strategy for beginnersSimple trading strategy for beginners
Simple trading strategy for beginnerspipsumo traderfx
 
Risk Management: Maximising Long-Term Growth Presentation
Risk Management: Maximising Long-Term Growth PresentationRisk Management: Maximising Long-Term Growth Presentation
Risk Management: Maximising Long-Term Growth PresentationQuantInsti
 
Option_SELLING_Webinar_0321.pdf
Option_SELLING_Webinar_0321.pdfOption_SELLING_Webinar_0321.pdf
Option_SELLING_Webinar_0321.pdfajaypalwe1
 
Instruction Set Architecture
Instruction  Set ArchitectureInstruction  Set Architecture
Instruction Set ArchitectureHaris456
 
01.The Ultimate Forex Trading Course (For Beginners).pdf
01.The Ultimate Forex Trading Course (For Beginners).pdf01.The Ultimate Forex Trading Course (For Beginners).pdf
01.The Ultimate Forex Trading Course (For Beginners).pdfSwahiliEpic
 
SMC structure.pdf
SMC structure.pdfSMC structure.pdf
SMC structure.pdfTan Ngoc
 

La actualidad más candente (20)

Fibonacci Trading for DW Traders
Fibonacci Trading for DW TradersFibonacci Trading for DW Traders
Fibonacci Trading for DW Traders
 
Section 2 - Chapter 9 Part II - Short Tem Pattern - Bar Chart Reversal Patterns
Section 2 - Chapter 9 Part II - Short Tem Pattern  - Bar Chart Reversal PatternsSection 2 - Chapter 9 Part II - Short Tem Pattern  - Bar Chart Reversal Patterns
Section 2 - Chapter 9 Part II - Short Tem Pattern - Bar Chart Reversal Patterns
 
MASTERING THE INTRADAY.pdf
MASTERING THE INTRADAY.pdfMASTERING THE INTRADAY.pdf
MASTERING THE INTRADAY.pdf
 
Algorithmic Trading
Algorithmic TradingAlgorithmic Trading
Algorithmic Trading
 
Amibroker afl coding 28th atma bengaluru meet
Amibroker afl coding   28th atma bengaluru meetAmibroker afl coding   28th atma bengaluru meet
Amibroker afl coding 28th atma bengaluru meet
 
Top 10 Tips For Stock Trading In India |Stock Market Tips
Top 10 Tips For Stock Trading In India |Stock Market TipsTop 10 Tips For Stock Trading In India |Stock Market Tips
Top 10 Tips For Stock Trading In India |Stock Market Tips
 
How Day Traders Do 200 Trades a Day and Strategies They Use
How Day Traders Do 200 Trades a Day and Strategies They UseHow Day Traders Do 200 Trades a Day and Strategies They Use
How Day Traders Do 200 Trades a Day and Strategies They Use
 
LC's Forex Trading System
LC's Forex Trading SystemLC's Forex Trading System
LC's Forex Trading System
 
Top 8 Forex Trading Strategies That Pro Traders Use
Top 8 Forex Trading Strategies That Pro Traders UseTop 8 Forex Trading Strategies That Pro Traders Use
Top 8 Forex Trading Strategies That Pro Traders Use
 
FOREX SCALPING STRATEGY
FOREX SCALPING STRATEGYFOREX SCALPING STRATEGY
FOREX SCALPING STRATEGY
 
Quantitative Trading
Quantitative TradingQuantitative Trading
Quantitative Trading
 
Support and resistance trading
Support and resistance tradingSupport and resistance trading
Support and resistance trading
 
Simple scalping secret strategy
Simple scalping secret strategySimple scalping secret strategy
Simple scalping secret strategy
 
How to Become a Professional Trader
How to Become a Professional TraderHow to Become a Professional Trader
How to Become a Professional Trader
 
Simple trading strategy for beginners
Simple trading strategy for beginnersSimple trading strategy for beginners
Simple trading strategy for beginners
 
Risk Management: Maximising Long-Term Growth Presentation
Risk Management: Maximising Long-Term Growth PresentationRisk Management: Maximising Long-Term Growth Presentation
Risk Management: Maximising Long-Term Growth Presentation
 
Option_SELLING_Webinar_0321.pdf
Option_SELLING_Webinar_0321.pdfOption_SELLING_Webinar_0321.pdf
Option_SELLING_Webinar_0321.pdf
 
Instruction Set Architecture
Instruction  Set ArchitectureInstruction  Set Architecture
Instruction Set Architecture
 
01.The Ultimate Forex Trading Course (For Beginners).pdf
01.The Ultimate Forex Trading Course (For Beginners).pdf01.The Ultimate Forex Trading Course (For Beginners).pdf
01.The Ultimate Forex Trading Course (For Beginners).pdf
 
SMC structure.pdf
SMC structure.pdfSMC structure.pdf
SMC structure.pdf
 

Destacado

AmiBroker Buy sell target & stop loss trading signals software for equity, co...
AmiBroker Buy sell target & stop loss trading signals software for equity, co...AmiBroker Buy sell target & stop loss trading signals software for equity, co...
AmiBroker Buy sell target & stop loss trading signals software for equity, co...Vishnu Kumar
 
AmiBroker AFL to DLL Conversion
AmiBroker  AFL to DLL ConversionAmiBroker  AFL to DLL Conversion
AmiBroker AFL to DLL Conversionafl2dll
 
Coimbatore amibroker workshop 2014
Coimbatore amibroker workshop 2014Coimbatore amibroker workshop 2014
Coimbatore amibroker workshop 2014Marketcalls
 
A Guide to Trading System Analysis : แนะนำแนวทางการอ่านผล Backtest เพื่อวิเคร...
A Guide to Trading System Analysis : แนะนำแนวทางการอ่านผล Backtest เพื่อวิเคร...A Guide to Trading System Analysis : แนะนำแนวทางการอ่านผล Backtest เพื่อวิเคร...
A Guide to Trading System Analysis : แนะนำแนวทางการอ่านผล Backtest เพื่อวิเคร...siamquant
 
Install and configure your amibroker software
Install and configure your amibroker softwareInstall and configure your amibroker software
Install and configure your amibroker softwarealexander N. N. Gilles
 
TradeZilla - Trading system Design
TradeZilla - Trading system DesignTradeZilla - Trading system Design
TradeZilla - Trading system DesignMarketcalls
 
Trading System Design
Trading System DesignTrading System Design
Trading System DesignMarketcalls
 
Selection Rotation Charts / Stats / Trades
Selection Rotation Charts / Stats / TradesSelection Rotation Charts / Stats / Trades
Selection Rotation Charts / Stats / TradesJason Unger
 
4s2 圖形拼砌與分割 教案(第4-5節)
4s2 圖形拼砌與分割 教案(第4-5節)4s2 圖形拼砌與分割 教案(第4-5節)
4s2 圖形拼砌與分割 教案(第4-5節)Ching Funpp Wong
 
Improving Your Trading Plan
Improving Your Trading PlanImproving Your Trading Plan
Improving Your Trading PlanBenjamin Cheeks
 
Limiti del modello Black-Scholes-Merton e vantaggi del metodo Monte Carlo: an...
Limiti del modello Black-Scholes-Merton e vantaggi del metodo Monte Carlo: an...Limiti del modello Black-Scholes-Merton e vantaggi del metodo Monte Carlo: an...
Limiti del modello Black-Scholes-Merton e vantaggi del metodo Monte Carlo: an...Matteo Evangelisti
 
Introduzione al metodo monte carlo
Introduzione al metodo monte carloIntroduzione al metodo monte carlo
Introduzione al metodo monte carloGiovanni Della Lunga
 
Plan your trade,trade your plan
Plan your trade,trade your planPlan your trade,trade your plan
Plan your trade,trade your planandy6898
 
18.如何用兩台totolink路由器設定wds
18.如何用兩台totolink路由器設定wds18.如何用兩台totolink路由器設定wds
18.如何用兩台totolink路由器設定wds臺灣塔米歐
 
Risk management - Avvocato del diavolo
Risk management - Avvocato del diavoloRisk management - Avvocato del diavolo
Risk management - Avvocato del diavoloManager.it
 
Transition to a_hedge fund_-_wsi
Transition to a_hedge fund_-_wsiTransition to a_hedge fund_-_wsi
Transition to a_hedge fund_-_wsikevinWSI
 
12 afl strategies
12 afl strategies12 afl strategies
12 afl strategiesaealey
 

Destacado (20)

AmiBroker Buy sell target & stop loss trading signals software for equity, co...
AmiBroker Buy sell target & stop loss trading signals software for equity, co...AmiBroker Buy sell target & stop loss trading signals software for equity, co...
AmiBroker Buy sell target & stop loss trading signals software for equity, co...
 
AmiBroker AFL to DLL Conversion
AmiBroker  AFL to DLL ConversionAmiBroker  AFL to DLL Conversion
AmiBroker AFL to DLL Conversion
 
Coimbatore amibroker workshop 2014
Coimbatore amibroker workshop 2014Coimbatore amibroker workshop 2014
Coimbatore amibroker workshop 2014
 
A Guide to Trading System Analysis : แนะนำแนวทางการอ่านผล Backtest เพื่อวิเคร...
A Guide to Trading System Analysis : แนะนำแนวทางการอ่านผล Backtest เพื่อวิเคร...A Guide to Trading System Analysis : แนะนำแนวทางการอ่านผล Backtest เพื่อวิเคร...
A Guide to Trading System Analysis : แนะนำแนวทางการอ่านผล Backtest เพื่อวิเคร...
 
Install and configure your amibroker software
Install and configure your amibroker softwareInstall and configure your amibroker software
Install and configure your amibroker software
 
TradeZilla - Trading system Design
TradeZilla - Trading system DesignTradeZilla - Trading system Design
TradeZilla - Trading system Design
 
Trading System Design
Trading System DesignTrading System Design
Trading System Design
 
Selection Rotation Charts / Stats / Trades
Selection Rotation Charts / Stats / TradesSelection Rotation Charts / Stats / Trades
Selection Rotation Charts / Stats / Trades
 
Stock trader types
Stock trader typesStock trader types
Stock trader types
 
4s2 圖形拼砌與分割 教案(第4-5節)
4s2 圖形拼砌與分割 教案(第4-5節)4s2 圖形拼砌與分割 教案(第4-5節)
4s2 圖形拼砌與分割 教案(第4-5節)
 
Improving Your Trading Plan
Improving Your Trading PlanImproving Your Trading Plan
Improving Your Trading Plan
 
Limiti del modello Black-Scholes-Merton e vantaggi del metodo Monte Carlo: an...
Limiti del modello Black-Scholes-Merton e vantaggi del metodo Monte Carlo: an...Limiti del modello Black-Scholes-Merton e vantaggi del metodo Monte Carlo: an...
Limiti del modello Black-Scholes-Merton e vantaggi del metodo Monte Carlo: an...
 
Introduzione al metodo monte carlo
Introduzione al metodo monte carloIntroduzione al metodo monte carlo
Introduzione al metodo monte carlo
 
Plan your trade,trade your plan
Plan your trade,trade your planPlan your trade,trade your plan
Plan your trade,trade your plan
 
18.如何用兩台totolink路由器設定wds
18.如何用兩台totolink路由器設定wds18.如何用兩台totolink路由器設定wds
18.如何用兩台totolink路由器設定wds
 
Risk management - Avvocato del diavolo
Risk management - Avvocato del diavoloRisk management - Avvocato del diavolo
Risk management - Avvocato del diavolo
 
Trading system designer
Trading system designerTrading system designer
Trading system designer
 
Td sequential2
Td sequential2Td sequential2
Td sequential2
 
Transition to a_hedge fund_-_wsi
Transition to a_hedge fund_-_wsiTransition to a_hedge fund_-_wsi
Transition to a_hedge fund_-_wsi
 
12 afl strategies
12 afl strategies12 afl strategies
12 afl strategies
 

Similar a AmiBroker ApplyStop Introduction

Verilog Lecture3 hust 2014
Verilog Lecture3 hust 2014Verilog Lecture3 hust 2014
Verilog Lecture3 hust 2014Béo Tú
 
Equity Option Trading : Derivatives Market Practices
Equity Option Trading : Derivatives Market PracticesEquity Option Trading : Derivatives Market Practices
Equity Option Trading : Derivatives Market PracticesJames Prichard
 
Developing Maintenance Strategies Using RCM Aided by Reliability Engineering ...
Developing Maintenance Strategies Using RCM Aided by Reliability Engineering ...Developing Maintenance Strategies Using RCM Aided by Reliability Engineering ...
Developing Maintenance Strategies Using RCM Aided by Reliability Engineering ...Gilbert Hamambi
 
Fractal Trading Strategies for Bloomberg Professional
Fractal Trading Strategies for Bloomberg ProfessionalFractal Trading Strategies for Bloomberg Professional
Fractal Trading Strategies for Bloomberg Professionalbzinchenko
 
TMMi: should you care? Step-Auto Conference 2013, Bangalore
TMMi: should you care? Step-Auto Conference 2013, BangaloreTMMi: should you care? Step-Auto Conference 2013, Bangalore
TMMi: should you care? Step-Auto Conference 2013, BangaloreSYSQA BV
 
Mdp plus 2.1
Mdp plus 2.1Mdp plus 2.1
Mdp plus 2.1boedax
 
__MESA presentation,Profitable Adaptive Trading Systems.ppt
__MESA presentation,Profitable Adaptive Trading Systems.ppt__MESA presentation,Profitable Adaptive Trading Systems.ppt
__MESA presentation,Profitable Adaptive Trading Systems.pptssuser48f316
 
Control Statement.ppt
Control Statement.pptControl Statement.ppt
Control Statement.pptsanjay
 

Similar a AmiBroker ApplyStop Introduction (11)

Verilog Lecture3 hust 2014
Verilog Lecture3 hust 2014Verilog Lecture3 hust 2014
Verilog Lecture3 hust 2014
 
Equity Option Trading : Derivatives Market Practices
Equity Option Trading : Derivatives Market PracticesEquity Option Trading : Derivatives Market Practices
Equity Option Trading : Derivatives Market Practices
 
Developing Maintenance Strategies Using RCM Aided by Reliability Engineering ...
Developing Maintenance Strategies Using RCM Aided by Reliability Engineering ...Developing Maintenance Strategies Using RCM Aided by Reliability Engineering ...
Developing Maintenance Strategies Using RCM Aided by Reliability Engineering ...
 
Fractal Trading Strategies for Bloomberg Professional
Fractal Trading Strategies for Bloomberg ProfessionalFractal Trading Strategies for Bloomberg Professional
Fractal Trading Strategies for Bloomberg Professional
 
Lesson 5
Lesson 5Lesson 5
Lesson 5
 
TMMi: should you care? Step-Auto Conference 2013, Bangalore
TMMi: should you care? Step-Auto Conference 2013, BangaloreTMMi: should you care? Step-Auto Conference 2013, Bangalore
TMMi: should you care? Step-Auto Conference 2013, Bangalore
 
Mdp plus 2.1
Mdp plus 2.1Mdp plus 2.1
Mdp plus 2.1
 
__MESA presentation,Profitable Adaptive Trading Systems.ppt
__MESA presentation,Profitable Adaptive Trading Systems.ppt__MESA presentation,Profitable Adaptive Trading Systems.ppt
__MESA presentation,Profitable Adaptive Trading Systems.ppt
 
Control Statement.ppt
Control Statement.pptControl Statement.ppt
Control Statement.ppt
 
StereoTraderMT_Reference-ttp.pdf
StereoTraderMT_Reference-ttp.pdfStereoTraderMT_Reference-ttp.pdf
StereoTraderMT_Reference-ttp.pdf
 
StereoTraderMT_Reference-ttp-low.pdf
StereoTraderMT_Reference-ttp-low.pdfStereoTraderMT_Reference-ttp-low.pdf
StereoTraderMT_Reference-ttp-low.pdf
 

Último

Student Profile Sample - We help schools to connect the data they have, with ...
Student Profile Sample - We help schools to connect the data they have, with ...Student Profile Sample - We help schools to connect the data they have, with ...
Student Profile Sample - We help schools to connect the data they have, with ...Seán Kennedy
 
AUDIENCE THEORY -CULTIVATION THEORY - GERBNER.pptx
AUDIENCE THEORY -CULTIVATION THEORY -  GERBNER.pptxAUDIENCE THEORY -CULTIVATION THEORY -  GERBNER.pptx
AUDIENCE THEORY -CULTIVATION THEORY - GERBNER.pptxiammrhaywood
 
Music 9 - 4th quarter - Vocal Music of the Romantic Period.pptx
Music 9 - 4th quarter - Vocal Music of the Romantic Period.pptxMusic 9 - 4th quarter - Vocal Music of the Romantic Period.pptx
Music 9 - 4th quarter - Vocal Music of the Romantic Period.pptxleah joy valeriano
 
Activity 2-unit 2-update 2024. English translation
Activity 2-unit 2-update 2024. English translationActivity 2-unit 2-update 2024. English translation
Activity 2-unit 2-update 2024. English translationRosabel UA
 
Choosing the Right CBSE School A Comprehensive Guide for Parents
Choosing the Right CBSE School A Comprehensive Guide for ParentsChoosing the Right CBSE School A Comprehensive Guide for Parents
Choosing the Right CBSE School A Comprehensive Guide for Parentsnavabharathschool99
 
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATIONTHEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATIONHumphrey A Beña
 
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdfGrade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdfJemuel Francisco
 
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdf
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdfVirtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdf
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdfErwinPantujan2
 
ROLES IN A STAGE PRODUCTION in arts.pptx
ROLES IN A STAGE PRODUCTION in arts.pptxROLES IN A STAGE PRODUCTION in arts.pptx
ROLES IN A STAGE PRODUCTION in arts.pptxVanesaIglesias10
 
Integumentary System SMP B. Pharm Sem I.ppt
Integumentary System SMP B. Pharm Sem I.pptIntegumentary System SMP B. Pharm Sem I.ppt
Integumentary System SMP B. Pharm Sem I.pptshraddhaparab530
 
Full Stack Web Development Course for Beginners
Full Stack Web Development Course  for BeginnersFull Stack Web Development Course  for Beginners
Full Stack Web Development Course for BeginnersSabitha Banu
 
Transaction Management in Database Management System
Transaction Management in Database Management SystemTransaction Management in Database Management System
Transaction Management in Database Management SystemChristalin Nelson
 
How to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERPHow to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERPCeline George
 
ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...
ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...
ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...JojoEDelaCruz
 
Earth Day Presentation wow hello nice great
Earth Day Presentation wow hello nice greatEarth Day Presentation wow hello nice great
Earth Day Presentation wow hello nice greatYousafMalik24
 
Concurrency Control in Database Management system
Concurrency Control in Database Management systemConcurrency Control in Database Management system
Concurrency Control in Database Management systemChristalin Nelson
 
Keynote by Prof. Wurzer at Nordex about IP-design
Keynote by Prof. Wurzer at Nordex about IP-designKeynote by Prof. Wurzer at Nordex about IP-design
Keynote by Prof. Wurzer at Nordex about IP-designMIPLM
 

Último (20)

Student Profile Sample - We help schools to connect the data they have, with ...
Student Profile Sample - We help schools to connect the data they have, with ...Student Profile Sample - We help schools to connect the data they have, with ...
Student Profile Sample - We help schools to connect the data they have, with ...
 
AUDIENCE THEORY -CULTIVATION THEORY - GERBNER.pptx
AUDIENCE THEORY -CULTIVATION THEORY -  GERBNER.pptxAUDIENCE THEORY -CULTIVATION THEORY -  GERBNER.pptx
AUDIENCE THEORY -CULTIVATION THEORY - GERBNER.pptx
 
Music 9 - 4th quarter - Vocal Music of the Romantic Period.pptx
Music 9 - 4th quarter - Vocal Music of the Romantic Period.pptxMusic 9 - 4th quarter - Vocal Music of the Romantic Period.pptx
Music 9 - 4th quarter - Vocal Music of the Romantic Period.pptx
 
Activity 2-unit 2-update 2024. English translation
Activity 2-unit 2-update 2024. English translationActivity 2-unit 2-update 2024. English translation
Activity 2-unit 2-update 2024. English translation
 
Choosing the Right CBSE School A Comprehensive Guide for Parents
Choosing the Right CBSE School A Comprehensive Guide for ParentsChoosing the Right CBSE School A Comprehensive Guide for Parents
Choosing the Right CBSE School A Comprehensive Guide for Parents
 
FINALS_OF_LEFT_ON_C'N_EL_DORADO_2024.pptx
FINALS_OF_LEFT_ON_C'N_EL_DORADO_2024.pptxFINALS_OF_LEFT_ON_C'N_EL_DORADO_2024.pptx
FINALS_OF_LEFT_ON_C'N_EL_DORADO_2024.pptx
 
YOUVE GOT EMAIL_FINALS_EL_DORADO_2024.pptx
YOUVE GOT EMAIL_FINALS_EL_DORADO_2024.pptxYOUVE GOT EMAIL_FINALS_EL_DORADO_2024.pptx
YOUVE GOT EMAIL_FINALS_EL_DORADO_2024.pptx
 
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATIONTHEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
 
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdfGrade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
 
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdf
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdfVirtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdf
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdf
 
ROLES IN A STAGE PRODUCTION in arts.pptx
ROLES IN A STAGE PRODUCTION in arts.pptxROLES IN A STAGE PRODUCTION in arts.pptx
ROLES IN A STAGE PRODUCTION in arts.pptx
 
YOUVE_GOT_EMAIL_PRELIMS_EL_DORADO_2024.pptx
YOUVE_GOT_EMAIL_PRELIMS_EL_DORADO_2024.pptxYOUVE_GOT_EMAIL_PRELIMS_EL_DORADO_2024.pptx
YOUVE_GOT_EMAIL_PRELIMS_EL_DORADO_2024.pptx
 
Integumentary System SMP B. Pharm Sem I.ppt
Integumentary System SMP B. Pharm Sem I.pptIntegumentary System SMP B. Pharm Sem I.ppt
Integumentary System SMP B. Pharm Sem I.ppt
 
Full Stack Web Development Course for Beginners
Full Stack Web Development Course  for BeginnersFull Stack Web Development Course  for Beginners
Full Stack Web Development Course for Beginners
 
Transaction Management in Database Management System
Transaction Management in Database Management SystemTransaction Management in Database Management System
Transaction Management in Database Management System
 
How to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERPHow to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERP
 
ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...
ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...
ENG 5 Q4 WEEk 1 DAY 1 Restate sentences heard in one’s own words. Use appropr...
 
Earth Day Presentation wow hello nice great
Earth Day Presentation wow hello nice greatEarth Day Presentation wow hello nice great
Earth Day Presentation wow hello nice great
 
Concurrency Control in Database Management system
Concurrency Control in Database Management systemConcurrency Control in Database Management system
Concurrency Control in Database Management system
 
Keynote by Prof. Wurzer at Nordex about IP-design
Keynote by Prof. Wurzer at Nordex about IP-designKeynote by Prof. Wurzer at Nordex about IP-design
Keynote by Prof. Wurzer at Nordex about IP-design
 

AmiBroker ApplyStop Introduction

  • 2. When to sell? 1. Sell Signals • Sell = sellConMKC AND (sellCon1 AND sellCon2 …); 2. Stop Triggers • ApplyStop( stopTypeLoss, stopModePercent, 15); 3. Better opportunities • Calculate current positions • Calculate opportunities, and then compare to current positions • Force sell signals, and then enter a better opportunity Note: use CBI to perform 3. 74
  • 3. Facts about Stop Triggers •Stops can help or hurt your results •Change of degree in stop could result favorably or unfavorably •Limitation in AmiBroker •Backtesting VS Execution •Keep it manageable and executable; otherwise, don’t use it 75
  • 4. Basic ApplyStop in AmiBroker 76 ApplyStop( Type, Mode, Amount); • stopTypeLoss • stopTypeProfit • stopTypeNBar • stopTypeTrailing • stopModePoint • stopModePercent • stopModeBars • stopModeRisk • Number: 15 • Point • Percent • Bars • Array: 3ATR(14)
  • 5. 77 40 days 100 100 120 Profit from High = 120 – 100 = 20, then 10% profit = 2 118 100 120 High at 120, 10% = 12 High at 110, 10% = 11 108 99 -10% 100 90 10% 100 110 ApplyStop(stopTypeLoss, stopModePercent, 10); ApplyStop(stopTypeProfit, stopModePercent, 10); ApplyStop(stopTypeNBar, stopModeBars, 40); ApplyStop(stopTypeTrailing, stopModePercent, 10); ApplyStop(stopTypeTrailing, stopModeRisk, 10);
  • 6. EASY ? Not so fast ! 78
  • 7. More Details of ApplyStop in AmiBroker 79 • Trade Price: SellPrice = Open or Close • ExitAtStop: 0, 1, or 2 • Volatility: True or False • ReEntryDelay: especially in Sideways and many false signals • ValidFrom & ValidTo: especially in stopModeRisk • ActivateStopsImmediately: On or Off Note: please study https://www.amibroker.com/guide/afl/applystop.html ApplyStop(Type, Mode, Amount, ExitAtStop, Volatility, ReEntryDelay, ValidFrom, ValidTo);
  • 8. WARNING Can Code, but Not Execute = Useless Can Execute, but Not Understand = Risky 80
  • 10. Facts about ApplyStop in AmiBroker •Compatibility between stopType and stopMode matters • stopTypeNBar not compatible with stopModePercent •Compatibility between stopMode and stopAmount matters • stopModePercent not compatible with stopAmount 3ATR() •Only one stopMode per one stopType is used 1. ApplyStop(stopTypeTrailing, stopModePercent, 15); //over ruled by next line 2. ApplyStop(stopTypeTrailing, stopModeRisk, 15); •Keep it manageable and executable; otherwise, don’t use it 82
  • 11. stopType… and stopMode… in AmiBroker 83 stopType… stopMode… Measured FromPoint Percent NBars Risk Loss Entry price Profit Entry price NBar Entry bar Trailing (1) (1) (2) (1) % from High (2) % from High - Entry ApplyStop( Type, Mode, Amount, ExitAtStop, Volatility, ReentryDelay, ValidFrom, ValidTo);
  • 12. stopMode… and stopAmount given: ATR(14) = 5 •ApplyStop(stopTypeLoss, stopModePoint, 10); //Entry: 125 -> then: 115 •ApplyStop(stopTypeLoss, stopModePercent, 10); //125->112.5 •ApplyStop(stopTypeLoss, stopModePercent, 2*ATR(14)); //Run, but non-sense •ApplyStop(stopTypeLoss, stopModePoint, 2*ATR(14)); //125->115 •ApplyStop(stopTypeProfit, stopModePoint, 10); //Entry: 125 -> then: 135 •ApplyStop(stopTypeProfit, stopModePercent, 10); //125->137.5 •ApplyStop(stopTypeProfit, stopModePercent, 2*ATR(14)); •ApplyStop(stopTypeProfit, stopModePoint, 2*ATR(14)); //125->135 84
  • 13. stopMode… and stopAmount given: ATR(14) = 5 •ApplyStop( stopTypeNBar, stopModeBars, 40); // Bar 0 until Bar 40 •ApplyStop( stopTypeNBar, stopModePercent, 40); //Run, but non-sense •ApplyStop( stopTypeNBar, stopModePoint, 40); //Run, but non-sense •ApplyStop( stopTypeTrailing, stopModePoint, 25); //100->125->100 •ApplyStop( stopTypeTrailing, stopModePoint, 5*ATR(14)); //100->125->100 •ApplyStop( stopTypeTrailing, stopModePercent, 25); //100->125->93.75 •ApplyStop( stopTypeTrailing, stopModeRisk, 25); //100->125->118.75 85
  • 14. stopTypeTrailing with stopModeRisk •ApplyStop( stopTypeTrailing, stopModeRisk, 25); //100->104->103 ??? •ApplyStop( stopTypeTrailing, stopModeRisk, 25, … , … , …, 20); // ValidFrom 86 ApplyStop( Type, Mode, Amount, ExitAtStop, Volatility, ReentryDelay, ValidFrom, ValidTo);
  • 15. Conclusion for Basic ApplyStop in AmiBroker •Not executable or not understand it, Don’t use it ! •Keep it simple and straightforward •Prefer the followings: • ApplyStop(stopTypeLoss, stopModePercent, 10); // 5 to 15%; • ApplyStop(stopTypeProfit, stopModePercent, 20); // 15 to 35%; • ApplyStop(stopTypeTrailing, stopModePercent, 25); // 20 to 30%; • ApplyStop(stopTypeNBar, stopModeBars, 40); // Depends on strategy •Keep stop co-ordinate and logical •Read: https://www.amibroker.com/guide/afl/applystop.html 87
  • 16. WARNING (AGAIN) Can Code, but Not Execute = Useless Can Execute, but Not Understand = Risky 88 Note: please study https://www.amibroker.com/guide/afl/applystop.html