DEMAND SUPPLY ,IDENTIFYING BAR LENGHT BELOW AND ABOVE 50%

// get the range of the bar r1 = HIGH()-LOW(); // get the body value b1 = ABS(close()-OPEN()); // is body > 50% of range? v1 = b1 / r1 > 0.49; //true and close is up v1 and CLOSE() IsUp

// get the range of the bar r1 = HIGH()-LOW(); // get the body value b1 = ABS(close()-OPEN()); // is body > 50% of range? v1 = b1 / r1 > 0.5; //true and close is down v1 and CLOSE() IsDown

Hi Mohd,

I cleaned up the formatting of your 2 scripts and they now show as expected, with the green Show Bar arrows for up days and red for down when the body is > 50% of the range:

Up days:

// get the range of the bar;
r1 = HIGH()-LOW();
// get the body value;
b1 = ABS(close()-OPEN());
// is body > 50% of range?;
v1 = b1 / r1 > 0.5;
//true and close is up;
v1 and CLOSE() IsUp

Down days:

// get the range of the bar;
r1 = HIGH()-LOW();
// get the body value;
b1 = ABS(close()-OPEN());
// is body > 50% of range?;
v1 = b1 / r1 > 0.5;
//true and close is down;
v1 and CLOSE() IsDown

Image