It is the part of project, it has to draw the lines depending on group of trades.
It has to draw lines when there is a particular percentage of drawdown level is reached and those active trades are categorized to a particular group and after drawing the lines further trades will fall into other group.
Thats why I used IF POSITION for group 6 (Trades Before Drawing lines) and NO POSITION for group 13 (Trades to be open after lines)