Rajandran R Telecom Engineer turned Full-time Derivative Trader. Mostly Trading Nifty, Banknifty, USDINR and High Liquid Stock Derivatives. Trading the Markets Since 2006 onwards. Using Market Profile and Orderflow for more than a decade. Designed and published 100+ open source trading systems on various trading tools. Strongly believe that market understanding and robust trading frameworks are the key to the trading success. Writing about Markets, Trading System Design, Market Sentiment, Trading Softwares & Trading Nuances since 2007 onwards. Author of Marketcalls.in)

Moving Average and Percentage Band AFL code

33 sec read

From Sudhin Bhathija,
Hi Rajandran, I want an afl which plots the following.

Say you have a 200sma, now the afl must also plot a line which is +25% and -25% of the sma, user must be able to modify this percentage or sma, could you write one thanks, I am yet to decide the sma and % hence the flexibility is needed.
Thanks,
Sudhin

The Following AFL code user has the provision for varying the Moving Average, Perentage and the type of Moving Average( SMA, EMA, DEMA, WMA, TEMA) and the color of the moving average. to change the properties right click on the chart and select properties
[wp_ad_camp_5]

 
Properties of Moving Average and Perentage Band AFL code

Changing the properties of Moving Average and Percentage Band

Switching Between Moving Average

Sudhin Bhathija is requesting this simple AFL code since long time back. Anyways got it done today 🙂

Download Moving Average and Percentage Band AFL code

Rajandran R Telecom Engineer turned Full-time Derivative Trader. Mostly Trading Nifty, Banknifty, USDINR and High Liquid Stock Derivatives. Trading the Markets Since 2006 onwards. Using Market Profile and Orderflow for more than a decade. Designed and published 100+ open source trading systems on various trading tools. Strongly believe that market understanding and robust trading frameworks are the key to the trading success. Writing about Markets, Trading System Design, Market Sentiment, Trading Softwares & Trading Nuances since 2007 onwards. Author of Marketcalls.in)

[Live Coding Webinar] Build Your First Trading Bridge for…

In this course, you will be learning to build your own trading bridge using Python. This 60-minute session is perfect for traders, Python enthusiasts,...
Rajandran R
1 min read

[Webinar] Understanding and Mitigating Curve Fitting in System Trading

"Understanding and Mitigating Curve Fitting in System Trading"! This dynamic session aims to equip novice to intermediate traders, quantitative analysts, and financial engineers with...
Rajandran R
1 min read

P-Signal Strategy Long Only Strategy – Amibroker AFL Code

This tutorial provides an overview of the P-Signal reversal strategy, a quantitative trading strategy that utilizes statistical parameters and error functions to generate probabilistic...
Rajandran R
2 min read

10 Replies to “Moving Average and Percentage Band AFL code”

  1. Thanks Rajendra, one more if you can I want one afl for [yesterday high – today low] OR [TODAY HIGH – YESTERDAY LOW], I have one for todayhigh – todaylow. See if you can put it up if time is an issue no problem, thanks once again, I appreciate your effort, may God bless you.

  2. Assume u have the following data
    day HI LO
    DAY1 100 90
    DAY2 105 83
    Now i want day1 hi-day2 low =100-83=17 or [ABSOLUTE IF VALUE IS NEGATIVE ]
    or
    day1low – day2high = 90-105= -15(MINUS 15) OR ABSOLUTE IF NEGATIVE.
    C if u can write the alf for either or I could manage with the above afl.
    Thanks

  3. Hats Off Rajandran !!!
    You may call it Simple AFL but its worth a LOT.Actually I was also looking for such a nice formula to use it for DAY trading for small gains.Thanks a LOT to you as well as Sudhin for putting up this request to a GENIUS like you.

    Amirishali

  4. Hi Rajendan
    I visited your site many times pe chance but neve took it seriously. Only today I could undersatand your good site.Thanks a lot. I want to say a few request words (i) To develop AFL like shown at this site http://www.forexpros.com/commodities/gold-technical four all time fames by increasing more indicators. You can see such combination of all indiacators in the trial software of vogaz which can be downloaded from vogaz site. (ii) To stat serial tutorial how to handle amibroker specially how to input the AFL and how to attach a sheet or remove a sheet.
    If you could provide it will be great sevice to novice people like me.
    Thanks again
    Vijay Kumar Haryana

  5. good mg Rajandran sir sir i have instal rtdf stock live data but its give message asoftware is expire give me totriol of instalation
    thanks in advavce

  6. Hi Rajandran, I want an afl which plots the following.
    we have a 8ema(green),AND 20 ema(red) now watch it cross overs ,
    1. when green goes up by crossing red we want buy signal
    2. when green goes down by crossing red we want sell signal if possible just make its afl

    sincerly
    reena

  7. hello frinds i am new in amibroker but i have programing background in c#.net can any one say me the way to create autotrading system in amibroker to send nest and now without subscribing api

Leave a Reply

Get Notifications, Alerts on Market Updates, Trading Tools, Automation & More