1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

FTS Toolkit - Bandwidth Ratio - Indicator showing relative Bollinger Band levels

Discussion in 'Forex Tactical Squad' started by Peter O, Jul 8, 2013.

  1. Peter O

    Peter O Special Consultant to the FPA

    Joined:
    Jan 14, 2013
    Messages:
    3,247
    Likes Received:
    1,397
    Fellow Squad Members,


    Here is a simple custom indicator that calculates price levels on a scale of standard deviation (Bollinger Bands). That is when price pierces Bollinger Band dev = 2.0 the value of this indicator is 2.0 or -2.0 (upper band and lower band respectively).


    Installation and starting:

    Download source code from here:



    This is a custom indicator code so you need to copy it to {MetaTrader4 folder}/experts/indicators folder and then start the trading platform (or close and restart if it had been open). The tool will appear on Navigator panel (open from View menu) among Custom Indicators as FPA=BandwidthRatio so just drag over your chart.

    [​IMG]


    Settings and Parameters:

    You can open Properties window by right clicking indicator line and selecting the first menu item.

    [​IMG]

    On the Inputs tab you will see the only input parameter:

    [​IMG]

    Parameter: Deviation_Period
    Possible values: positive integer

    This is the calculation period in candles of the moving average and standard deviation (Bollinger Bands) by which bandwidth ratio is calculated.



    You can participate:

    Tell me and your Squad Members how you like it.
    Tell me and your Squad Members how could it be better.
    Tell me and your Squad Members if you have any problem while installing or using it.


    Who wants to enter the Laboratory:

    Right click on Navigator panel/Custom Indicators/FPA=BandwidthRatio and select Modify. MetaEditor opens up showing the full source code I've written for you.

    [​IMG]

    On the first screen you can find some hidden parameters like colors and styles (from line "string indicator_name = ..." to "color indicator_level_line_color = ..."). You can change the values after the equal sign (you can use these color names just write them without spaces and be aware of case sensitivity) and even the default setting "20" above them for the input parameter "extern int Deviation_Period = ...".

    [​IMG]

    After modifying the code press F5 or Compile button on the top. If it writes "0 error(s),..." on the bottom, you have your own new version and you can start using it after going back to MT4 terminal.

    [​IMG]

    Looking forward to hearing your feedback,

    Peter
     
    #1 Peter O, Jul 8, 2013
    Last edited: Aug 27, 2013
  2. Peter O

    Peter O Special Consultant to the FPA

    Joined:
    Jan 14, 2013
    Messages:
    3,247
    Likes Received:
    1,397
    I tested all source code links and eventually I replaced all of them because I saw downloading issue in Firefox.

    Now I've tested new links and all worked fine for me in Firefox and Chrome as well.

    Peter
     
  3. goldy_40

    goldy_40 Recruit

    Joined:
    Nov 21, 2013
    Messages:
    4
    Likes Received:
    0
    It's very similar to CCI
     

Share This Page