ricksieminski 5 posts msg #135656 - Ignore ricksieminski |
4/28/2017 10:10:54 AM
It's called DMI Stochastic Extreme. Can anyone help with conversion to work here?
Thanks,
--Rick
input length = 10;
input highLowLength = 3;
input sumLength = 3;
input over_bought = 90;
input over_sold = 10;
def osc = DMI_Oscillator(length, "average type" = AverageType.WILDERS);
def hh = Highest(osc, highLowLength);
def ll = Lowest(osc, highLowLength);
plot Stoch = Sum(osc - ll, sumLength) / (Sum(hh - ll, sumLength)) * 100;
plot OverBought = over_bought;
plot OverSold = over_sold;
plot Up = if Stoch crosses above over_sold then over_sold + 5 else Double.NaN;
plot Down = if Stoch crosses below over_bought then over_bought - 5 else Double.NaN;
Stoch.SetDefaultColor(GetColor(1));
OverBought.SetDefaultColor(Color.GRAY);
OverSold.SetDefaultColor(Color.GRAY);
Up.SetDefaultColor(Color.UPTICK);
Up.SetPaintingStrategy(PaintingStrategy.ARROW_UP);
Up.HideBubble();
Down.SetDefaultColor(Color.DOWNTICK);
Down.SetPaintingStrategy(PaintingStrategy.ARROW_DOWN);
Down.HideBubble();
|
dwojahn 5 posts msg #144098 - Ignore dwojahn |
7/15/2018 2:14:55 PM
I just noticed that the timing of these events/arrows may be an interesting substitute for DMI Stoch Ext. I call them my Hull Moving average arrows
/* Hull Green Section */
set{fast1,cwma(close,7)}
set{fast2,2 * fast1}
set{fast3,cwma(close,14)}
set{valfast,fast2 - fast3}
set{fastavg,cwma(valfast,4)}
and close crossed above fastavg /* hull green arrow signal */
/* Hull Red Section */
set{fast1,cwma(close,7)}
set{fast2,2 * fast1}
set{fast3,cwma(close,14)}
set{valfast,fast2 - fast3}
set{fastavg,cwma(valfast,4)}
and close crossed below fastavg /* hull red arrow signal */
|