rsier1m2

This script is designed to function as a visual signaling tool on your trading platform, helping identify specific moments of momentum shifts based on price movement. Rather than just showing you moving lines, it places distinct markers (arrows) on your chart to highlight potential opportunities where the market's strength might be changing direction.

How the Logic Works

The script functions by monitoring a specific technical indicator (the Relative Strength Index, or RSI) across a custom timeframe that you can define (such as 15-minute intervals). It looks for "crossover" events—moments where the indicator moves from one numerical zone into another.

1. Identifying Oversold Conditions (Potential Buy Signals) The script constantly scans the previous data points to see if the indicator has recently climbed above a specific threshold of 30. If it detects that the indicator was below 30 in the previous candle but has now reached or exceeded it, the script places a marker at the bottom of the price bar. This is intended to highlight areas where downward momentum may be exhausting and moving upward.

2. Identifying Overbought Conditions (Potential Sell Signals) Conversely, the script monitors the indicator for a drop from a high threshold of 70. If it detects that the indicator was above 70 in the previous candle but has now fallen back down to or below 70, it places a marker at the top of the price bar. This is intended to highlight areas where upward momentum may be cooling off and moving downward.

Key Features for the User

  • Visual Alerts: Instead of requiring you to watch complex numbers on a separate window, the script puts "arrows" directly on your main price chart.
  • Customizable Timeframes: You can adjust the settings to analyze different periods (e.g., checking 15-minute trends) to suit your specific trading style.
  • Automated Scanning: The tool automatically looks back through a set amount of historical data to ensure you can see past signals clearly on your chart layout.

In summary, this tool acts as an automated "scout," scanning the market's momentum and placing visual markers whenever the price enters zones that typically suggest a shift in trend direction.

Miscellaneous
Implements a curve of type %1
13 Views
0 Downloads
0 Favorites
rsier1m2
//+------------------------------------------------------------------+
//| ADX Crossing.mq4 
//| Amir
//+------------------------------------------------------------------+
#property  copyright "Author - Amir"

#property indicator_chart_window
#property indicator_buffers 2
#property indicator_color1 LightBlue
#property indicator_color2 Red

//---- input parameters
extern int Timeframe_in_Minutes=15;
extern int RSIperiod=14;
extern int CountBars=350;

//---- buffers
double val1[];
double val2[];
double rsib4,rsinow;

//+------------------------------------------------------------------+
//| Custom indicator initialization function                         |
//+------------------------------------------------------------------+
int init()
  {
   string short_name;
//---- indicator line
   IndicatorBuffers(2);
   SetIndexStyle(0,DRAW_ARROW);
   SetIndexArrow(0,108);
   SetIndexStyle(1,DRAW_ARROW);
   SetIndexArrow(1,108);
   SetIndexBuffer(0,val1);
   SetIndexBuffer(1,val2);
//----
   return(0);
  }
//+------------------------------------------------------------------+
//| AltrTrend_Signal_v2_2                                            |
//+------------------------------------------------------------------+
int start()
  {   
  // if (CountBars>=500) CountBars=500;
  // SetIndexDrawBegin(0,500-CountBars);
  // SetIndexDrawBegin(1,500-CountBars);
  int i,shift,counted_bars=IndicatorCounted();


   //---- check for possible errors
  // if(counted_bars<0) return(-1);

   //---- initial zero
  // if(counted_bars<1)
   //  {
    //  for(i=1;i<=CountBars;i++) val1[CountBars-i]=0.0;
    //  for(i=1;i<=CountBars;i++) val2[CountBars-i]=0.0;
    // } 

for ( shift = 250; shift>=0; shift--) 
{ 

	rsib4=iCustom(NULL,0,"#MTF_RSI",Timeframe_in_Minutes,14,0,shift+1) ;
	rsinow=iCustom(NULL,0,"#MTF_RSI",Timeframe_in_Minutes,14,0,shift);
Comment (rsib4," ",rsinow);
	val1[shift]=0;
		val2[shift]=0;
if (rsinow>=30.00 && rsib4<= 30.00)
{
	val1[shift]=Low[shift]-5*Point;
}
if (rsib4>=70.00 && rsinow<=70.00) 
{
	val2[shift]=High[shift]+5*Point;
}


}
   return(0);
  }
//+------------------------------------------------------------------+

Comments