Topic: Gap Indicator

Gap indicator measures the gap between current open price and previous bar close price.
If the gap is greater than a Minimum Gap, the indicator rises a signal.

There are two logical rules.
- "Positive Gap" - rises buy signal if the gap is positive and sell signal if the gap is negative.
- "Negative Gap" - rises sell signal if the gap is positive and buy signal if the gap is negative.

Formula:

// Positive Gap logic
if (Open[bar] > Close[bar - 1] + minGap) 
    longSignals[bar] = 1;
if (Open[bar] < Close[bar - 1] - minGap) 
    shortSignals[bar] = 1;

// Negative Gap logic
if (Open[bar] < Close[bar - 1] - minGap) 
    longSignals[bar] = 1;
if (Open[bar] > Close[bar - 1] + minGap) 
    shortSignals[bar] = 1;

Screenshot:
http://i.imgur.com/LXSgi.png

Possible use:
http://i.imgur.com/toyvq.png

Indicator is attached below:

Post's attachments

Gap.cs 4.33 kb, 101 downloads since 2012-04-16 

You don't have the permssions to download the attachments of this post.

Re: Gap Indicator

This would be a useful indicator to check the data with . Since the markets are 24 hours then any gap more than a few pips might be indicative of an error in the data, except over the weekends.