setPriceStudy(true);
setStudyTitle("CBP");
setCursorLabelName("CBP");
setColorPriceBars(true);
setDefaultPriceBarColor(Color.grey);
}
function main() {
var vC = close(0);
var vCH = high(-1);
var vCL = low(-1);
if(vC == null || vCH == null || vCL == null) return;
if (vC > vCH) {
setPriceBarColor(Color.blue);
}
else if (vC < vCL) {
setPriceBarColor(Color.red);
}
return;
}
thanks
Comment