Working towards CME membership
Price Activity indicator (not Price Action) 7 replies
Need Price Action crosses MA Indicator 3 replies
price action indicator (PAIN) ie pin bar detector 6 replies
Price Action Indicator 2 replies
DislikedDoes anybody know if there is an indicator based on this principle. Looks quite interestingggg
http://www.forexrealm.com/technical-...indicator.htmlIgnored
// See http://www.forexrealm.com/technical-analysis/technical-indicators/price-action-indicator.html
#property indicator_separate_window
#property indicator_buffers 1
#property indicator_color1 Lime
double dPainBuffer[];
int init() {
IndicatorShortName("PAIN");
SetIndexBuffer(0,dPainBuffer);
SetIndexLabel(0,"PAIN");
return(0);
}
int start() {
int iBarsToCalc = Bars - IndicatorCounted();
if (iBarsToCalc < Bars) iBarsToCalc++;
for (int i=iBarsToCalc-1;i>=0;i--)
dPainBuffer[i] = ( (Close[i]-Open[i])+(Close[i]-High[i])+(Close[i]-Low[i]) ) / 2;
return(0);
}
DislikedHere, knock yourself out.
PHP Code// See http://www.forexrealm.com/technical-analysis/technical-indicators/price-action-indicator.html
#property indicator_separate_window
#property indicator_buffers 1
#property indicator_color1 Lime
double dPainBuffer[];
int init() {
IndicatorShortName("PAIN");
SetIndexBuffer(0,dPainBuffer);
SetIndexLabel(0,"PAIN");
return(0);
}
int start() {
int iBarsToCalc = Bars - IndicatorCounted();
if (iBarsToCalc < Bars) iBarsToCalc++;
for (int i=iBarsToCalc-1;i>=0;i--)
dPainBuffer[i] = ( (Close[i]-Open[i])+(Close[i]-High[i])+(Close[i]-Low[i]) ) / 2;
return(0);
}
Ignored
Dislikedjust wondering if anybody (cough tesla cough ) could just add a little code on putting on the period input, that would be sweet. Humble requestIgnored
DislikedAre you talking about taking moving averages of the close/open/low/high prices and calculating the PAIN value on that?Ignored
// See http://www.forexrealm.com/technical-analysis/technical-indicators/price-action-indicator.html
#property indicator_separate_window
#property indicator_buffers 1
#property indicator_color1 Lime
extern int MoveAvgPeriod = 1;
extern int MoveAvgMethod = MODE_SMA;
double dPainBuffer[];
int init() {
IndicatorShortName("PAIN");
SetIndexBuffer(0,dPainBuffer);
SetIndexLabel(0,"PAIN");
return(0);
}
int start() {
int iBarsToCalc = Bars - IndicatorCounted();
if (iBarsToCalc < Bars) iBarsToCalc++;
for (int i=iBarsToCalc-1;i>=0;i--) {
double dCloseMA = iMA(NULL,0,MoveAvgPeriod,0,MoveAvgMethod,PRICE_CLOSE,i);
double dOpenMA = iMA(NULL,0,MoveAvgPeriod,0,MoveAvgMethod,PRICE_OPEN, i);
double dHigheMA = iMA(NULL,0,MoveAvgPeriod,0,MoveAvgMethod,PRICE_HIGH, i);
double dLowMA = iMA(NULL,0,MoveAvgPeriod,0,MoveAvgMethod,PRICE_LOW, i);
dPainBuffer[i] = ( (dCloseMA-dOpenMA)+(dCloseMA-dHigheMA)+(dCloseMA-dLowMA) ) / 2;
}
return(0);
}