I like Blau's Ergodic Candlestick as an indicator, but every time, before
I can be sure exactly which way it's pointing, I have to right click on it
and reload. Below is the formula; please tell me how to modify it so that
it automatically stays current.
Thanks.
/************************************************** *****************
Blau's Ergonomic Candlestick Oscillator; Provided By : TS Support, LLC for
eSignal. (c) Copyright 2002
************************************************** ******************/
function preMain()
{
setStudyTitle("ECO-11");
setCursorLabelName("BlauECO 10",0);
setDefaultBarFgColor(Color.lime,0);
setDefaultBarFgColor(Color.RGB(180,155,180),1);
setPlotType(PLOTTYPE_HISTOGRAM,1);
addBand(0, PS_DASH, 2, Color.maroon);
// Force the scale to be 0->100
// setStudyMin(-.30);
// setStudyMax(.30);
}
var EMA_1 = 0;
var EMA1_1 = 0;
var vEMA_1 = 0;
var vEMA1_1 = 0;
var vEco1 = 0;
var vHisto = 0;
function main(r,s)
{
if (r == null)
r = 11;
if(s == null)
s = 4;
var K = 2 / (r + 1);
var K1 = 2 / (s + 1);
EMA = K * (close() - open()) + (1 - K) * EMA_1;
EMA1 = K1 * EMA + (1 - K1) * EMA1_1;
vEMA = K * (high() - low()) + (1 - K) * vEMA_1;
vEMA1 = K1 * vEMA + (1 - K1) * vEMA1_1;
if (getBarState() == BARSTATE_NEWBAR){
EMA_1 = EMA;
EMA1_1 = EMA1;
vEMA_1 = vEMA;
vEMA1_1 = vEMA1;
}
vEco1 = EMA1 / vEMA1;
vHisto = EMA1 / vEMA1;
if(vEMA1 != 0)
return new Array (vEco1,vHisto);
else
return;
}
I can be sure exactly which way it's pointing, I have to right click on it
and reload. Below is the formula; please tell me how to modify it so that
it automatically stays current.
Thanks.
/************************************************** *****************
Blau's Ergonomic Candlestick Oscillator; Provided By : TS Support, LLC for
eSignal. (c) Copyright 2002
************************************************** ******************/
function preMain()
{
setStudyTitle("ECO-11");
setCursorLabelName("BlauECO 10",0);
setDefaultBarFgColor(Color.lime,0);
setDefaultBarFgColor(Color.RGB(180,155,180),1);
setPlotType(PLOTTYPE_HISTOGRAM,1);
addBand(0, PS_DASH, 2, Color.maroon);
// Force the scale to be 0->100
// setStudyMin(-.30);
// setStudyMax(.30);
}
var EMA_1 = 0;
var EMA1_1 = 0;
var vEMA_1 = 0;
var vEMA1_1 = 0;
var vEco1 = 0;
var vHisto = 0;
function main(r,s)
{
if (r == null)
r = 11;
if(s == null)
s = 4;
var K = 2 / (r + 1);
var K1 = 2 / (s + 1);
EMA = K * (close() - open()) + (1 - K) * EMA_1;
EMA1 = K1 * EMA + (1 - K1) * EMA1_1;
vEMA = K * (high() - low()) + (1 - K) * vEMA_1;
vEMA1 = K1 * vEMA + (1 - K1) * vEMA1_1;
if (getBarState() == BARSTATE_NEWBAR){
EMA_1 = EMA;
EMA1_1 = EMA1;
vEMA_1 = vEMA;
vEMA1_1 = vEMA1;
}
vEco1 = EMA1 / vEMA1;
vHisto = EMA1 / vEMA1;
if(vEMA1 != 0)
return new Array (vEco1,vHisto);
else
return;
}
Comment